org.wildfly.swarm.config.logging

## Class CustomHandler<T extends CustomHandler<T>>

- java.lang.Object
- - java.util.AbstractMap<K,V>
  - - java.util.HashMap
    - - org.wildfly.swarm.config.logging.CustomHandler<T>

- All Implemented Interfaces:
    Serializable, Cloneable, Map

      public class CustomHandler<T extends CustomHandler<T>>
      extends HashMap

  Defines a custom logging handler. The custom handler must extend java.util.logging.Handler.
  See Also:
    Serialized Form

- - ### Nested Class Summary

    - ### Nested classes/interfaces inherited from class java.util.AbstractMap

      `AbstractMap.SimpleEntry<K,V>, AbstractMap.SimpleImmutableEntry<K,V>`

    - ### Nested classes/interfaces inherited from interface java.util.Map

      `Map.Entry<K,V>`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `CustomHandler(String key)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `addPropertyChangeListener(PropertyChangeListener listener)` Adds a property change listener
    `String` | `attributeClass()` The logging handler class to be used.
    `T` | `attributeClass(String value)` The logging handler class to be used.
    `Boolean` | `enabled()` If set to true the handler is enabled and functioning as normal, if set to false the handler is ignored when processing log messages.
    `T` | `enabled(Boolean value)` If set to true the handler is enabled and functioning as normal, if set to false the handler is ignored when processing log messages.
    `String` | `encoding()` The character encoding used by this Handler.
    `T` | `encoding(String value)` The character encoding used by this Handler.
    `String` | `filterSpec()` A filter expression value to define a filter.
    `T` | `filterSpec(String value)` A filter expression value to define a filter.
    `String` | `formatter()` Defines a pattern for the formatter.
    `T` | `formatter(String value)` Defines a pattern for the formatter.
    `String` | `getKey()`
    `Level` | `level()` The log level specifying which message levels will be logged by this logger.
    `T` | `level(Level value)` The log level specifying which message levels will be logged by this logger.
    `String` | `module()` The module that the logging handler depends on.
    `T` | `module(String value)` The module that the logging handler depends on.
    `String` | `namedFormatter()` The name of the defined formatter to be used on the handler.
    `T` | `namedFormatter(String value)` The name of the defined formatter to be used on the handler.
    `Map` | `properties()` Defines the properties used for the logging handler.
    `T` | `properties(Map value)` Defines the properties used for the logging handler.
    `T` | `property(String key, Object value)` Defines the properties used for the logging handler.
    `void` | `removePropertyChangeListener(PropertyChangeListener listener)` Removes a property change listener

    - ### Methods inherited from class java.util.HashMap

      `clear, clone, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, entrySet, forEach, get, getOrDefault, isEmpty, keySet, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, replaceAll, size, values`

    - ### Methods inherited from class java.util.AbstractMap

      `equals, hashCode, toString`

    - ### Methods inherited from class java.lang.Object

      `getClass, notify, notifyAll, wait, wait, wait`

    - ### Methods inherited from interface java.util.Map

      `equals, hashCode`

- - ### Constructor Detail

    - #### CustomHandler

          public CustomHandler(String key)

  - ### Method Detail

    - #### getKey

          public String getKey()

    - #### addPropertyChangeListener

          public void addPropertyChangeListener(PropertyChangeListener listener)

      Adds a property change listener

    - #### removePropertyChangeListener

          public void removePropertyChangeListener(PropertyChangeListener listener)

      Removes a property change listener

    - #### attributeClass

          public String attributeClass()

      The logging handler class to be used.

    - #### attributeClass

          public T attributeClass(String value)

      The logging handler class to be used.

    - #### enabled

          public Boolean enabled()

      If set to true the handler is enabled and functioning as normal, if set to false the handler is ignored when processing log messages.

    - #### enabled

          public T enabled(Boolean value)

      If set to true the handler is enabled and functioning as normal, if set to false the handler is ignored when processing log messages.

    - #### encoding

          public String encoding()

      The character encoding used by this Handler.

    - #### encoding

          public T encoding(String value)

      The character encoding used by this Handler.

    - #### filterSpec

          public String filterSpec()

      A filter expression value to define a filter. Example for a filter that does not match a pattern: not(match("JBAS.*"))

    - #### filterSpec

          public T filterSpec(String value)

      A filter expression value to define a filter. Example for a filter that does not match a pattern: not(match("JBAS.*"))

    - #### formatter

          public String formatter()

      Defines a pattern for the formatter.

    - #### formatter

          public T formatter(String value)

      Defines a pattern for the formatter.

    - #### level

          public Level level()

      The log level specifying which message levels will be logged by this logger. Message levels lower than this value will be discarded.

    - #### level

          public T level(Level value)

      The log level specifying which message levels will be logged by this logger. Message levels lower than this value will be discarded.

    - #### module

          public String module()

      The module that the logging handler depends on.

    - #### module

          public T module(String value)

      The module that the logging handler depends on.

    - #### namedFormatter

          public String namedFormatter()

      The name of the defined formatter to be used on the handler.

    - #### namedFormatter

          public T namedFormatter(String value)

      The name of the defined formatter to be used on the handler.

    - #### properties

          public Map properties()

      Defines the properties used for the logging handler. All properties must be accessible via a setter method.

    - #### properties

          public T properties(Map value)

      Defines the properties used for the logging handler. All properties must be accessible via a setter method.

    - #### property

          public T property(String key,
                            Object value)

      Defines the properties used for the logging handler. All properties must be accessible via a setter method.

Copyright © 2017 JBoss by Red Hat. All rights reserved.