/**
* Copyright 2013-2015 John Ericksen
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
*/
/**
* = Asciidoclet
*
* https://github.com/asciidoctor/asciidoclet[Asciidoclet] is a Javadoc Doclet
* that uses http://asciidoctor.org[Asciidoctor] (via the
* https://github.com/asciidoctor/asciidoctorj[Asciidoctor Java integration])
* to interpret http://asciidoc.org[AsciiDoc] markup within Javadoc comments.
*
* == Usage
*
* Asciidoclet may be used via a custom doclet in the maven-javadoc-plugin:
*
* [source,xml]
* ----
* <plugin>
* <groupId>org.apache.maven.plugins</groupId>
* <artifactId>maven-javadoc-plugin</artifactId>
* <version>2.9</version>
* <configuration>
* <source>1.7</source>
* <doclet>org.asciidoctor.Asciidoclet</doclet>
* <docletArtifact>
* <groupId>org.asciidoclet</groupId>
* <artifactId>asciidoclet</artifactId>
* <version>${asciidoclet.version}</version>
* </docletArtifact>
* </configuration>
* </plugin>
* ----
*
* == Examples
*
* Code block (with syntax highlighting added by CodeRay)::
* +
* [source,java]
* --
* /**
* * = Asciidoclet
* *
* * A Javadoc Doclet that uses http://asciidoctor.org[Asciidoctor]
* * to render http://asciidoc.org[AsciiDoc] markup in Javadoc comments.
* *
* * @author https://github.com/johncarl81[John Ericksen]
* *\/
* public class Asciidoclet extends Doclet {
* private final Asciidoctor asciidoctor = Asciidoctor.Factory.create(); // <1>
*
* @SuppressWarnings("UnusedDeclaration")
* public static boolean start(RootDoc rootDoc) {
* new Asciidoclet().render(rootDoc); // <2>
* return Standard.start(rootDoc);
* }
* }
* --
* <1> Creates an instance of the Asciidoctor Java integration
* <2> Runs Javadoc comment strings through Asciidoctor
*
* Inline code:: `code()` or +code()+
*
* Headings::
* +
* --
* [float]
* = Heading 1
*
* [float]
* == Heading 2
*
* [float]
* === Heading 3
*
* [float]
* ==== Heading 4
*
* [float]
* ===== Heading 5
* --
*
* Links::
* Doc Writer <doc@example.com> +
* http://asciidoc.org[AsciiDoc] is a lightweight markup language. +
* Learn more about it at http://asciidoctor.org. +
*
* Bullets::
* +
* --
* .Unnumbered
* * bullet
* * bullet
* - bullet
* - bullet
* * bullet
* ** bullet
* ** bullet
* *** bullet
* *** bullet
* **** bullet
* **** bullet
* ***** bullet
* ***** bullet
* **** bullet
* *** bullet
* ** bullet
* * bullet
* --
* +
* --
* .Numbered
* . bullet
* . bullet
* .. bullet
* .. bullet
* . bullet
* .. bullet
* ... bullet
* ... bullet
* .... bullet
* .... bullet
* ... bullet
* ... bullet
* .. bullet
* .. bullet
* . bullet
* --
*
* Tables::
* +
* .An example table
* [cols="3", options="header"]
* |===
* |Column 1
* |Column 2
* |Column 3
*
* |1
* |Item 1
* |a
*
* |2
* |Item 2
* |b
*
* |3
* |Item 3
* |c
* |===
*
* Sidebar block::
* +
* .Optional Title
* ****
* Usage: Notes in a sidebar, naturally.
* ****
*
* Admonitions::
* +
* IMPORTANT: Check this out!
*
* @author https://github.com/johncarl81[John Ericksen]
* @version 0.1.0
* @see org.asciidoctor.Asciidoclet
* @since 0.1.0
* @serial (or @serialField or @serialData)
*/
package org.asciidoctor;