org.asciidoctor
public interface Asciidoctor
Modifier and Type | Interface and Description |
---|---|
static class |
Asciidoctor.Factory
Factory for creating a new instance of Asciidoctor interface.
|
Modifier and Type | Field and Description |
---|---|
static String |
STRUCTURE_MAX_LEVEL |
Modifier and Type | Method and Description |
---|---|
String |
asciidoctorVersion()
Method that gets the asciidoctor version which is being used..
|
void |
convert(Reader contentReader,
Writer rendererWriter,
Map<String,Object> options)
Parse the document read from reader, and rendered result is sent to
writer.
|
void |
convert(Reader contentReader,
Writer rendererWriter,
Options options)
Parse the document read from reader, and rendered result is sent to
writer.
|
void |
convert(Reader contentReader,
Writer rendererWriter,
OptionsBuilder options)
Parse the document read from reader, and rendered result is sent to
writer.
|
String |
convert(String content,
Map<String,Object> options)
Parse the AsciiDoc source input into an Document
DocumentRuby and
render it to the specified backend format. |
String |
convert(String content,
Options options)
Parse the AsciiDoc source input into an Document
DocumentRuby and
render it to the specified backend format. |
String |
convert(String content,
OptionsBuilder options)
Parse the AsciiDoc source input into an Document
DocumentRuby and
render it to the specified backend format. |
String[] |
convertDirectory(DirectoryWalker directoryWalker,
Map<String,Object> options)
Parse all AsciiDoc files found using DirectoryWalker instance.
|
String[] |
convertDirectory(DirectoryWalker directoryWalker,
Options options)
Parse all AsciiDoc files found using DirectoryWalker instance.
|
String[] |
convertDirectory(DirectoryWalker directoryWalker,
OptionsBuilder options)
Parse all AsciiDoc files found using DirectoryWalker instance.
|
String |
convertFile(File filename,
Map<String,Object> options)
Parse the AsciiDoc source input into an Document
DocumentRuby and
render it to the specified backend format. |
String |
convertFile(File filename,
Options options)
Parse the AsciiDoc source input into an Document
DocumentRuby and
render it to the specified backend format. |
String |
convertFile(File filename,
OptionsBuilder options)
Parse the AsciiDoc source input into an Document
DocumentRuby and
render it to the specified backend format. |
String[] |
convertFiles(Collection<File> asciidoctorFiles,
Map<String,Object> options)
Parses all files added inside a collection.
|
String[] |
convertFiles(Collection<File> asciidoctorFiles,
Options options)
Parses all files added inside a collection.
|
String[] |
convertFiles(Collection<File> asciidoctorFiles,
OptionsBuilder options)
Parses all files added inside a collection.
|
JavaExtensionRegistry |
javaExtensionRegistry()
Creates an extension registry ready to be used for registering all processors
|
Document |
load(String content,
Map<String,Object> options)
Loads AsciiDoc content and returns the Document object.
|
Document |
loadFile(File file,
Map<String,Object> options)
Loads AsciiDoc content from file and returns the Document object.
|
DocumentHeader |
readDocumentHeader(File filename)
Reads only header parameters instead of all document.
|
DocumentHeader |
readDocumentHeader(Reader contentReader)
Reads only header parameters instead of all document.
|
DocumentHeader |
readDocumentHeader(String content)
Reads only header parameters instead of all document.
|
StructuredDocument |
readDocumentStructure(File filename,
Map<String,Object> options)
Reads and creates structured document containing header and content chunks.
|
StructuredDocument |
readDocumentStructure(Reader contentReader,
Map<String,Object> options)
Reads and creates structured document containing header and content chunks.
|
StructuredDocument |
readDocumentStructure(String content,
Map<String,Object> options)
Reads and creates structured document containing header and content chunks.
|
void |
render(Reader contentReader,
Writer rendererWriter,
Map<String,Object> options)
Parse the document read from reader, and rendered result is sent to
writer.
|
void |
render(Reader contentReader,
Writer rendererWriter,
Options options)
Parse the document read from reader, and rendered result is sent to
writer.
|
void |
render(Reader contentReader,
Writer rendererWriter,
OptionsBuilder options)
Parse the document read from reader, and rendered result is sent to
writer.
|
String |
render(String content,
Map<String,Object> options)
Parse the AsciiDoc source input into an Document
DocumentRuby and
render it to the specified backend format. |
String |
render(String content,
Options options)
Parse the AsciiDoc source input into an Document
DocumentRuby and
render it to the specified backend format. |
String |
render(String content,
OptionsBuilder options)
Parse the AsciiDoc source input into an Document
DocumentRuby and
render it to the specified backend format. |
String[] |
renderDirectory(DirectoryWalker directoryWalker,
Map<String,Object> options)
Parse all AsciiDoc files found using DirectoryWalker instance.
|
String[] |
renderDirectory(DirectoryWalker directoryWalker,
Options options)
Parse all AsciiDoc files found using DirectoryWalker instance.
|
String[] |
renderDirectory(DirectoryWalker directoryWalker,
OptionsBuilder options)
Parse all AsciiDoc files found using DirectoryWalker instance.
|
String |
renderFile(File filename,
Map<String,Object> options)
Parse the AsciiDoc source input into an Document
DocumentRuby and
render it to the specified backend format. |
String |
renderFile(File filename,
Options options)
Parse the AsciiDoc source input into an Document
DocumentRuby and
render it to the specified backend format. |
String |
renderFile(File filename,
OptionsBuilder options)
Parse the AsciiDoc source input into an Document
DocumentRuby and
render it to the specified backend format. |
String[] |
renderFiles(Collection<File> asciidoctorFiles,
Map<String,Object> options)
Parses all files added inside a collection.
|
String[] |
renderFiles(Collection<File> asciidoctorFiles,
Options options)
Parses all files added inside a collection.
|
String[] |
renderFiles(Collection<File> asciidoctorFiles,
OptionsBuilder options)
Parses all files added inside a collection.
|
RubyExtensionRegistry |
rubyExtensionRegistry()
Creates an Ruby extension registry ready to be used for registering all processors
|
void |
shutdown()
This method frees all resources consumed by asciidoctorJ module.
|
void |
unregisterAllExtensions()
Unregister all registered extensions.
|
static final String STRUCTURE_MAX_LEVEL
String render(String content, Map<String,Object> options)
DocumentRuby
and
render it to the specified backend format.
Accepts input as String object.content
- the AsciiDoc source as String.options
- a Hash of options to control processing (default: {}).String render(String content, Options options)
DocumentRuby
and
render it to the specified backend format.
Accepts input as String object.content
- the AsciiDoc source as String.options
- a Hash of options to control processing (default: {}).String render(String content, OptionsBuilder options)
DocumentRuby
and
render it to the specified backend format.
Accepts input as String object.content
- the AsciiDoc source as String.options
- a Hash of options to control processing (default: {}).void render(Reader contentReader, Writer rendererWriter, Map<String,Object> options) throws IOException
contentReader
- where asciidoc content is read.rendererWriter
- where rendered content is written. Writer is flushed, but not
closed.options
- a Hash of options to control processing (default: {}).IOException
- if an error occurs while writing rendered content, this
exception is thrown.void render(Reader contentReader, Writer rendererWriter, Options options) throws IOException
contentReader
- where asciidoc content is read.rendererWriter
- where rendered content is written. Writer is flushed, but not
closed.options
- a Hash of options to control processing (default: {}).IOException
- if an error occurs while writing rendered content, this
exception is thrown.void render(Reader contentReader, Writer rendererWriter, OptionsBuilder options) throws IOException
contentReader
- where asciidoc content is read.rendererWriter
- where rendered content is written. Writer is flushed, but not
closed.options
- a Hash of options to control processing (default: {}).IOException
- if an error occurs while writing rendered content, this
exception is thrown.String renderFile(File filename, Map<String,Object> options)
DocumentRuby
and
render it to the specified backend format.
Accepts input as File path.
If the :in_place option is true, and the input is a File, the output is
written to a file adjacent to the input file, having an extension that
corresponds to the backend format. Otherwise, if the :to_file option is
specified, the file is written to that file. If :to_file is not an
absolute path, it is resolved relative to :to_dir, if given, otherwise
the Document#base_dir. If the target directory does not exist, it will
not be created unless the :mkdirs option is set to true. If the file
cannot be written because the target directory does not exist, or because
it falls outside of the Document#base_dir in safe mode, an IOError is
raised.filename
- an input Asciidoctor file.options
- a Hash of options to control processing (default: {}).String renderFile(File filename, Options options)
DocumentRuby
and
render it to the specified backend format.
Accepts input as File path.
If the :in_place option is true, and the input is a File, the output is
written to a file adjacent to the input file, having an extension that
corresponds to the backend format. Otherwise, if the :to_file option is
specified, the file is written to that file. If :to_file is not an
absolute path, it is resolved relative to :to_dir, if given, otherwise
the Document#base_dir. If the target directory does not exist, it will
not be created unless the :mkdirs option is set to true. If the file
cannot be written because the target directory does not exist, or because
it falls outside of the Document#base_dir in safe mode, an IOError is
raised.filename
- an input Asciidoctor file.options
- a Hash of options to control processing (default: {}).String renderFile(File filename, OptionsBuilder options)
DocumentRuby
and
render it to the specified backend format.
Accepts input as File path.
If the :in_place option is true, and the input is a File, the output is
written to a file adjacent to the input file, having an extension that
corresponds to the backend format. Otherwise, if the :to_file option is
specified, the file is written to that file. If :to_file is not an
absolute path, it is resolved relative to :to_dir, if given, otherwise
the Document#base_dir. If the target directory does not exist, it will
not be created unless the :mkdirs option is set to true. If the file
cannot be written because the target directory does not exist, or because
it falls outside of the Document#base_dir in safe mode, an IOError is
raised.filename
- an input Asciidoctor file.options
- a Hash of options to control processing (default: {}).String[] renderDirectory(DirectoryWalker directoryWalker, Map<String,Object> options)
directoryWalker
- strategy used to retrieve all files to be rendered.options
- a Hash of options to control processing (default: {}).String[] renderDirectory(DirectoryWalker directoryWalker, Options options)
directoryWalker
- strategy used to retrieve all files to be rendered.options
- a Hash of options to control processing (default: {}).String[] renderDirectory(DirectoryWalker directoryWalker, OptionsBuilder options)
directoryWalker
- strategy used to retrieve all files to be rendered.options
- a Hash of options to control processing (default: {}).String[] renderFiles(Collection<File> asciidoctorFiles, Map<String,Object> options)
asciidoctorFiles
- to be rendered.options
- a Hash of options to control processing (default: {}).String[] renderFiles(Collection<File> asciidoctorFiles, Options options)
asciidoctorFiles
- to be rendered.options
- a Hash of options to control processing (default: {}).String[] renderFiles(Collection<File> asciidoctorFiles, OptionsBuilder options)
asciidoctorFiles
- to be rendered.options
- a Hash of options to control processing (default: {}).String convert(String content, Map<String,Object> options)
DocumentRuby
and
render it to the specified backend format.
Accepts input as String object.content
- the AsciiDoc source as String.options
- a Hash of options to control processing (default: {}).String convert(String content, Options options)
DocumentRuby
and
render it to the specified backend format.
Accepts input as String object.content
- the AsciiDoc source as String.options
- a Hash of options to control processing (default: {}).String convert(String content, OptionsBuilder options)
DocumentRuby
and
render it to the specified backend format.
Accepts input as String object.content
- the AsciiDoc source as String.options
- a Hash of options to control processing (default: {}).void convert(Reader contentReader, Writer rendererWriter, Map<String,Object> options) throws IOException
contentReader
- where asciidoc content is read.rendererWriter
- where rendered content is written. Writer is flushed, but not
closed.options
- a Hash of options to control processing (default: {}).IOException
- if an error occurs while writing rendered content, this
exception is thrown.void convert(Reader contentReader, Writer rendererWriter, Options options) throws IOException
contentReader
- where asciidoc content is read.rendererWriter
- where rendered content is written. Writer is flushed, but not
closed.options
- a Hash of options to control processing (default: {}).IOException
- if an error occurs while writing rendered content, this
exception is thrown.void convert(Reader contentReader, Writer rendererWriter, OptionsBuilder options) throws IOException
contentReader
- where asciidoc content is read.rendererWriter
- where rendered content is written. Writer is flushed, but not
closed.options
- a Hash of options to control processing (default: {}).IOException
- if an error occurs while writing rendered content, this
exception is thrown.String convertFile(File filename, Map<String,Object> options)
DocumentRuby
and
render it to the specified backend format.
Accepts input as File path.
If the :in_place option is true, and the input is a File, the output is
written to a file adjacent to the input file, having an extension that
corresponds to the backend format. Otherwise, if the :to_file option is
specified, the file is written to that file. If :to_file is not an
absolute path, it is resolved relative to :to_dir, if given, otherwise
the Document#base_dir. If the target directory does not exist, it will
not be created unless the :mkdirs option is set to true. If the file
cannot be written because the target directory does not exist, or because
it falls outside of the Document#base_dir in safe mode, an IOError is
raised.filename
- an input Asciidoctor file.options
- a Hash of options to control processing (default: {}).String convertFile(File filename, Options options)
DocumentRuby
and
render it to the specified backend format.
Accepts input as File path.
If the :in_place option is true, and the input is a File, the output is
written to a file adjacent to the input file, having an extension that
corresponds to the backend format. Otherwise, if the :to_file option is
specified, the file is written to that file. If :to_file is not an
absolute path, it is resolved relative to :to_dir, if given, otherwise
the Document#base_dir. If the target directory does not exist, it will
not be created unless the :mkdirs option is set to true. If the file
cannot be written because the target directory does not exist, or because
it falls outside of the Document#base_dir in safe mode, an IOError is
raised.filename
- an input Asciidoctor file.options
- a Hash of options to control processing (default: {}).String convertFile(File filename, OptionsBuilder options)
DocumentRuby
and
render it to the specified backend format.
Accepts input as File path.
If the :in_place option is true, and the input is a File, the output is
written to a file adjacent to the input file, having an extension that
corresponds to the backend format. Otherwise, if the :to_file option is
specified, the file is written to that file. If :to_file is not an
absolute path, it is resolved relative to :to_dir, if given, otherwise
the Document#base_dir. If the target directory does not exist, it will
not be created unless the :mkdirs option is set to true. If the file
cannot be written because the target directory does not exist, or because
it falls outside of the Document#base_dir in safe mode, an IOError is
raised.filename
- an input Asciidoctor file.options
- a Hash of options to control processing (default: {}).String[] convertDirectory(DirectoryWalker directoryWalker, Map<String,Object> options)
directoryWalker
- strategy used to retrieve all files to be rendered.options
- a Hash of options to control processing (default: {}).String[] convertDirectory(DirectoryWalker directoryWalker, Options options)
directoryWalker
- strategy used to retrieve all files to be rendered.options
- a Hash of options to control processing (default: {}).String[] convertDirectory(DirectoryWalker directoryWalker, OptionsBuilder options)
directoryWalker
- strategy used to retrieve all files to be rendered.options
- a Hash of options to control processing (default: {}).String[] convertFiles(Collection<File> asciidoctorFiles, Map<String,Object> options)
asciidoctorFiles
- to be rendered.options
- a Hash of options to control processing (default: {}).String[] convertFiles(Collection<File> asciidoctorFiles, Options options)
asciidoctorFiles
- to be rendered.options
- a Hash of options to control processing (default: {}).String[] convertFiles(Collection<File> asciidoctorFiles, OptionsBuilder options)
asciidoctorFiles
- to be rendered.options
- a Hash of options to control processing (default: {}).StructuredDocument readDocumentStructure(File filename, Map<String,Object> options)
filename
- to read the attributes.options
- a Hash of options to control processing (default: {}).StructuredDocument readDocumentStructure(String content, Map<String,Object> options)
content
- where rendered content is written. Writer is flushed, but not
closed.options
- a Hash of options to control processing (default: {}).StructuredDocument readDocumentStructure(Reader contentReader, Map<String,Object> options)
contentReader
- where asciidoc content is read.options
- a Hash of options to control processing (default: {}).DocumentHeader readDocumentHeader(File filename)
filename
- to read the attributes.DocumentHeader readDocumentHeader(String content)
content
- where rendered content is written. Writer is flushed, but not
closed.DocumentHeader readDocumentHeader(Reader contentReader)
contentReader
- where asciidoc content is read.JavaExtensionRegistry javaExtensionRegistry()
RubyExtensionRegistry rubyExtensionRegistry()
void unregisterAllExtensions()
void shutdown()
String asciidoctorVersion()
Document load(String content, Map<String,Object> options)
content
- to be parsed.options
- Copyright © 2014. All Rights Reserved.