Annotation Type ConverterFor


@Retention(RUNTIME) @Target(TYPE) public @interface ConverterFor
Assigns a default backend name to a converter so that it is not required to define the backend name at registration time.

Example:

 @ConverterFor("myFormat")
 public class MyConverter extends AbstractConverter {
     ...
 }

 asciidoctor.javaConverterRegistry().register(MyConverter.class);
 
 
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    This parameter defines the backend name for this converter.
     
     
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final String
     
  • Field Details

  • Element Details

    • value

      String value
      Default:
      ""
    • format

      String format
      This parameter defines the backend name for this converter. Is can be set if also another parameter like suffix() is defined to avoid the parameter named value().

      Example:

       @ConverterFor(format = "myFormat", suffix = "mine")
       public class MyConverter extends AbstractConverter {
           ...
       }
       
       
      Returns:
      The backend name for this converter.
      Default:
      ""
    • suffix

      String suffix
      Returns:
      The file extension of files generated by this converter, e.g. .txt. If not defined generated files will have the extension .html.
      Default:
      ""