The void appender simply forgets about messages as soon as they arrive.

Version

1

Hierarchy (view full)

Constructors

Properties

_buffer: LogMessage[]

A buffer that will be filled with log messages until the Appender is writable.

_filterRelation: FilterRelation

The relation, to which all the appenders results must adhere. See FilterRelation.

_filters: Filter[]

The filter that will be evaluated in order to determine whether a message shall be handled by this appender.

Accessors

Methods

  • This function does the actual appending, e.g. to the console or a file, and thus, must be overriden by subclasses. The default implementation does nothing.

    Parameters

    • str: string

    Returns void

  • This function forwards the message to the _appendMessage method. The function should be overridden by subclasses for the pre-processing of a log message, e.g. transforming it into a formatted string.

    Parameters

    • msg: LogMessage

      The message that shall be handled.

    Returns void

  • Clears the temporary message cache. If the appender is writable, the messages in the cache will be forwarded to the _handleMessage method.

    Returns void

  • Evaluates the message with respect to the message filters set.

    Parameters

    Returns boolean

    True, if the message matches the filters, false otherwise.

  • The input function of an Appender for any log message. This function calls the filter evaluation, and hands the message over to the _handleMessage method, if the appender is currently writable. If the appender is not writable, the message is stored to the internal buffer.

    Parameters

    • msg: LogMessage

      The message that shall be received and appended.

    Returns boolean

    True, if the message was handled, false otherwise.