Annotation Interface Configurable


@Retention(RUNTIME) @Target({TYPE,TYPE_USE,FIELD,METHOD,PARAMETER}) @Documented @Namespace("Core") public @interface Configurable
Annotates a plugin as being a configurable plugin. A configurable plugin corresponds to a Node element of a configuration tree. Each configuration element may have zero or more attributes where attribute values are converted from strings into other types via TypeConverter, an optional value (another type of plugin attribute which may have dedicated syntax in some configuration formats such as XML), and zero or more child elements. Configurable plugins are not the only type of plugin that may be referenced in a configuration file; other plugin namespaces may define their own rules for interpreting configuration data if the node tree representation is inadequate.
  • Optional Element Summary

    Optional Elements
    Modifier and Type
    Optional Element
    Description
    boolean
    Indicates if construction and injection of child configuration nodes should be deferred until first use.
    Name of the corresponding category of elements this plugin belongs under.
    boolean
    Indicates if the plugin class implements a useful Object.toString() method for use in debug log messages.
  • Element Details

    • elementType

      String elementType
      Name of the corresponding category of elements this plugin belongs under. For example, appender would indicate an Appender plugin which would be in the <Appenders/> element of a Configuration and is injected into a PluginElement injection point of the containing plugin. When using a strict XML configuration format, the XML element name must match this value rather than the name of the plugin.
      Returns:
      the element's type.
      Default:
      ""
    • printObject

      boolean printObject
      Indicates if the plugin class implements a useful Object.toString() method for use in debug log messages.
      Returns:
      true if the object should print nicely.
      Default:
      false
    • deferChildren

      boolean deferChildren
      Indicates if construction and injection of child configuration nodes should be deferred until first use. When enabled, children plugins may only be injected as Node instances and handled manually.
      Returns:
      true if child elements should defer instantiation until they are accessed.
      Default:
      false