Class Options

    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods 
      Modifier and Type Method Description
      static OptionsBuilder builder()  
      java.util.Map<java.lang.String,​java.lang.Object> map()
      Deprecated.
      For internal use only.
      void setAttributes​(java.util.Map<java.lang.String,​java.lang.Object> attributes)  
      void setAttributes​(Attributes attributes)  
      void setBackend​(java.lang.String backend)  
      void setBaseDir​(java.lang.String baseDir)  
      void setCatalogAssets​(boolean catalogAssets)
      If true, tells the parser to capture images and links in the reference table.
      void setCompact​(boolean compact)  
      void setDocType​(java.lang.String docType)  
      void setEruby​(java.lang.String eruby)  
      void setInPlace​(boolean inPlace)  
      void setMkDirs​(boolean mkDirs)  
      void setOption​(java.lang.String optionName, java.lang.Object optionValue)  
      void setParse​(boolean parse)
      If true, the source is parsed eagerly (i.e., as soon as the source is passed to the load or load_file API).
      void setParseHeaderOnly​(boolean parseHeaderOnly)  
      void setSafe​(SafeMode safeMode)
      Safe method calls safeMode.getLevel() to put the required level.
      void setSourcemap​(boolean sourcemap)
      Keeps track of the file and line number for each parsed block.
      void setStandalone​(boolean standalone)
      Toggle including header and footer into the output.
      void setTemplateCache​(boolean templateCache)  
      void setTemplateDirs​(java.lang.String... templateDirs)  
      void setTemplateEngine​(java.lang.String templateEngine)  
      void setToDir​(java.lang.String toDir)  
      void setToFile​(boolean toFile)
      Toggle writing output to a file.
      void setToFile​(java.lang.String toFile)
      Enable writing output to a file.
      void setToStream​(java.io.OutputStream toStream)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Method Detail

      • builder

        public static OptionsBuilder builder()
        Returns:
        Empty OptionsBuilder instance.
      • setInPlace

        public void setInPlace​(boolean inPlace)
      • setAttributes

        public void setAttributes​(Attributes attributes)
      • setAttributes

        public void setAttributes​(java.util.Map<java.lang.String,​java.lang.Object> attributes)
      • setStandalone

        public void setStandalone​(boolean standalone)
        Toggle including header and footer into the output.
        Parameters:
        standalone - true to generate a standalone output document (which includes the shell around the body content, such as the header and footer). Defaults to true when converting a file only, otherwise is false.
      • setTemplateDirs

        public void setTemplateDirs​(java.lang.String... templateDirs)
      • setTemplateEngine

        public void setTemplateEngine​(java.lang.String templateEngine)
      • setToFile

        public void setToFile​(java.lang.String toFile)
        Enable writing output to a file. The file includes header and footer by default.
        Parameters:
        toFile - The path to the output file. If the path is not absolute, it is interpreted relative to what was set via setToDir(String)} or setBaseDir(String)}, in that order.
      • setToStream

        public void setToStream​(java.io.OutputStream toStream)
      • setToFile

        public void setToFile​(boolean toFile)
        Toggle writing output to a file.
        Parameters:
        toFile - If true, write output to a file in the same directory as the input file, including header and footer into the output. If false, return output as a string without any header or footer. The default header and footer visibility can be overridden using setStandalone(boolean).
      • setToDir

        public void setToDir​(java.lang.String toDir)
      • setMkDirs

        public void setMkDirs​(boolean mkDirs)
      • setSafe

        public void setSafe​(SafeMode safeMode)
        Safe method calls safeMode.getLevel() to put the required level.
        Parameters:
        safeMode - enum.
      • setSourcemap

        public void setSourcemap​(boolean sourcemap)
        Keeps track of the file and line number for each parsed block. (Useful for tooling applications where the association between the converted output and the source file is important).
        Parameters:
        sourcemap - value.
      • setEruby

        public void setEruby​(java.lang.String eruby)
      • setCatalogAssets

        public void setCatalogAssets​(boolean catalogAssets)
        If true, tells the parser to capture images and links in the reference table. (Normally only IDs, footnotes and indexterms are included). The reference table is available via the references property on the document AST object. (Experimental).
        Parameters:
        catalogAssets - value.
      • setCompact

        public void setCompact​(boolean compact)
      • setBackend

        public void setBackend​(java.lang.String backend)
      • setDocType

        public void setDocType​(java.lang.String docType)
      • setBaseDir

        public void setBaseDir​(java.lang.String baseDir)
      • setTemplateCache

        public void setTemplateCache​(boolean templateCache)
      • setParse

        public void setParse​(boolean parse)
        If true, the source is parsed eagerly (i.e., as soon as the source is passed to the load or load_file API). If false, parsing is deferred until the parse method is explicitly invoked.
        Parameters:
        parse - value.
      • setParseHeaderOnly

        public void setParseHeaderOnly​(boolean parseHeaderOnly)
      • setOption

        public void setOption​(java.lang.String optionName,
                              java.lang.Object optionValue)
      • map

        @Deprecated
        public java.util.Map<java.lang.String,​java.lang.Object> map()
        Deprecated.
        For internal use only.