Class CreateAppenderTask

  • All Implemented Interfaces:
    SubTask
    Direct Known Subclasses:
    CreateConsoleAppenderTask, CreateGenericAppenderTask, CreateOutputStreamAppenderTask

    public abstract class CreateAppenderTask
    extends CreateGenericComponentTask

    Abstract base class for all sub tasks that create logging appenders.

    Ant Parameters
    Attribute Description Required

    appendername

    Name of the appender to create. This name must be unique.

    Yes.

    ignoreexceptions

    The default is true, causing exceptions encountered while appending events to be internally logged and then ignored. When set to false, exceptions will be propagated to the caller instead.

    No.

    failonerror

    Flag to control failure behaviour. If true, the sub task will throw a BuildException when an error is encountered. If false, the sub task will throw a NonFatalBuildException instead of a BuildException under specific circumstances. See below for conditions (if any) which will cause a NonFatalBuildException.

    No. Default value is taken from the Rhino management parent task.

    NonFatalBuildException throw conditions
    • Implementation dependent.

    • Field Detail

      • appenderName

        protected String appenderName
    • Constructor Detail

      • CreateAppenderTask

        public CreateAppenderTask()
    • Method Detail

      • execute

        protected void execute()
                        throws org.apache.tools.ant.BuildException
        Overrides:
        execute in class CreateGenericComponentTask
        Throws:
        org.apache.tools.ant.BuildException
      • setAppenderName

        public void setAppenderName​(String appenderName)
      • setIgnoreExceptions

        public void setIgnoreExceptions​(Boolean ignoreExceptions)