Skip to content

Commit

Permalink
Fixes asciidoctor#492. Deprecate Processor.CONTENT_MODEL_* and moved @…
Browse files Browse the repository at this point in the history
…ContentModel to org.asciidoctor.ast.
  • Loading branch information
robertpanzer committed Jul 25, 2016
1 parent 63a2823 commit d759bcd
Show file tree
Hide file tree
Showing 7 changed files with 23 additions and 5 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
package org.asciidoctor.extension;
package org.asciidoctor.ast;

import java.lang.annotation.Documented;
import java.lang.annotation.ElementType;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,42 +40,59 @@ public class Processor {
* </verbatim>
* </pre>
* </p>
*
* @deprecated Use the annotation {@link ContentModel} instead to describe this Processor
*/
@Deprecated
public static final String CONTENT_MODEL = "content_model";

/**
* Predefined constant to let Asciidoctor know that this BlockProcessor creates zero or more child blocks.
* @deprecated Use {@link ContentModel#COMPOUND} instead.
*/
@Deprecated
public static final String CONTENT_MODEL_COMPOUND = ":compound";

/**
* Predefined constant to let Asciidoctor know that this BlockProcessor creates simple paragraph content.
* @deprecated Use {@link ContentModel#SIMPLE} instead.
*/
@Deprecated
public static final String CONTENT_MODEL_SIMPLE =":simple";

/**
* Predefined constant to let Asciidoctor know that this BlockProcessor creates literal content.
* @deprecated Use {@link ContentModel#VERBATIM} instead.
*/
@Deprecated
public static final String CONTENT_MODEL_VERBATIM =":verbatim";

/**
* Predefined constant to make Asciidoctor pass through the content unprocessed.
* @deprecated Use {@link ContentModel#RAW} instead.
*/
@Deprecated
public static final String CONTENT_MODEL_RAW =":raw";

/**
* Predefined constant to make Asciidoctor drop the content.
* @deprecated Use {@link ContentModel#SKIP} instead.
*/
@Deprecated
public static final String CONTENT_MODEL_SKIP =":skip";

/**
* Predefined constant to make Asciidoctor not expect any content.
* @deprecated Use {@link ContentModel#EMPTY} instead.
*/
@Deprecated
public static final String CONTENT_MODEL_EMPTY =":empty";

/**
* Predefined constant to make Asciidoctor parse content as attributes.
* @deprecated Use {@link ContentModel#ATTRIBUTES} instead.
*/
@Deprecated
public static final String CONTENT_MODEL_ATTRIBUTES =":attributes";


Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
package org.asciidoctor.extension.processorproxies;

import org.asciidoctor.ast.impl.ContentNodeImpl;
import org.asciidoctor.extension.ContentModel;
import org.asciidoctor.ast.ContentModel;
import org.asciidoctor.extension.Contexts;
import org.asciidoctor.extension.DefaultAttribute;
import org.asciidoctor.extension.DefaultAttributes;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
package org.asciidoctor.extension

import groovy.transform.CompileStatic
import org.asciidoctor.ast.ContentModel
import org.asciidoctor.ast.StructuralNode

@CompileStatic
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -563,7 +563,7 @@ The AST is built from the following types:
.. `literal`
.. `open`
.. `example`
.. `pass``
.. `pass`

`org.asciidoctor.ast.List`::
The list node is the container for ordered and unordered lists.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

import org.asciidoctor.ast.StructuralNode;
import org.asciidoctor.extension.BlockProcessor;
import org.asciidoctor.extension.ContentModel;
import org.asciidoctor.ast.ContentModel;
import org.asciidoctor.extension.Contexts;
import org.asciidoctor.extension.Name;
import org.asciidoctor.extension.Reader;
Expand Down
2 changes: 1 addition & 1 deletion docs/integrator-guide.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -682,7 +682,7 @@ The AST is built from the following types:
.. `literal`
.. `open`
.. `example`
.. `pass``
.. `pass`

`org.asciidoctor.ast.List`::
The list node is the container for ordered and unordered lists.
Expand Down

0 comments on commit d759bcd

Please sign in to comment.