Class DefaultPropertiesLoader

    • Constructor Detail

      • DefaultPropertiesLoader

        public DefaultPropertiesLoader()
      • DefaultPropertiesLoader

        public DefaultPropertiesLoader​(Properties properties)
    • Method Detail

      • getConsolePackages

        public List<String> getConsolePackages()
        Description copied from interface: PropertiesLoader
        Get a List of Packages to configure the Log Hierarchy.

        By default The logger engine will consider the same pattern from log4j. For example, the LoggerConfig named "com.foo" is a parent of the LoggerConfig named "com.foo.Bar". Similarly,"java" is a parent of "java.util" and an ancestor of "java.util.Vector". This naming scheme should be familiar to most developers.

        Specified by:
        getConsolePackages in interface PropertiesLoader
        Returns:
        a List of String representing packages Namespaces
        See Also:
        log4j/2.x/manual/architecture.html
      • getConsolePatternLayout

        public String getConsolePatternLayout()
        Description copied from interface: PropertiesLoader
        Gets Console Pattern Layout.

        More often than not, users wish to customize not only the output destination but also the output format. This is accomplished by associating a Layout with an Appender. The Layout is responsible for formatting the LogEvent according to the user's wishes, whereas an appender takes care of sending the formatted output to its destination.

        Specified by:
        getConsolePatternLayout in interface PropertiesLoader
        Returns:
        a Pattern Layout String
        See Also:
        log4j/2.x/manual/layouts.html
      • getConsoleIgnoreExceptions

        public String getConsoleIgnoreExceptions()
        Description copied from interface: PropertiesLoader
        Should Console Logging Ignore Exceptions?

        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. You must set this to false when wrapping this Appender in a FailoverAppender.

        Specified by:
        getConsoleIgnoreExceptions in interface PropertiesLoader
        Returns:
        Return a String "true" or "false" values, if you return something different from "true" or "false" the DefaultConfigurationFactory will consider as "true".
      • getConsoleTarget

        public String getConsoleTarget()
        Description copied from interface: PropertiesLoader
        Output Stream for Console Logger.
        Can be Either "SYSTEM_OUT" or "SYSTEM_ERR". The default is "SYSTEM_OUT".
        Specified by:
        getConsoleTarget in interface PropertiesLoader
        Returns:
        a String
      • getFilePackages

        public List<String> getFilePackages()
        Description copied from interface: PropertiesLoader
        Get a List of Packages to configure the Log Hierarchy.

        By default The logger engine will consider the same pattern from log4j. For example, the LoggerConfig named "com.foo" is a parent of the LoggerConfig named "com.foo.Bar". Similarly,"java" is a parent of "java.util" and an ancestor of "java.util.Vector". This naming scheme should be familiar to most developers.

        Specified by:
        getFilePackages in interface PropertiesLoader
        Returns:
        a List of String representing packages Namespaces
        See Also:
        log4j/2.x/manual/architecture.html
      • getFilePatternLayout

        public String getFilePatternLayout()
        Description copied from interface: PropertiesLoader
        Gets File Pattern Layout.

        More often than not, users wish to customize not only the output destination but also the output format. This is accomplished by associating a Layout with an Appender. The Layout is responsible for formatting the LogEvent according to the user's wishes, whereas an appender takes care of sending the formatted output to its destination.

        Specified by:
        getFilePatternLayout in interface PropertiesLoader
        Returns:
        a Pattern Layout String
        See Also:
        log4j/2.x/manual/layouts.html
      • getFileAppend

        public Boolean getFileAppend()
        Description copied from interface: PropertiesLoader
        Get the file append property.

        When true - the default, records will be appended to the end of the file. When set to false, the file will be cleared before new records are written.

        Specified by:
        getFileAppend in interface PropertiesLoader
        Returns:
        true or false
      • getCreateFileOnDemand

        public Boolean getCreateFileOnDemand()
        Description copied from interface: PropertiesLoader
        Get the Create File On Demand property.

        The appender creates the file on-demand. The appender only creates the file when a log event passes all filters and is routed to this appender. Defaults to false.

        Specified by:
        getCreateFileOnDemand in interface PropertiesLoader
        Returns:
        true or false
      • getFilePattern

        public String getFilePattern()
        Description copied from interface: PropertiesLoader
        Get the file archiving pattern.

        The pattern of the file name of the archived log file Example: .yyyy-MM-dd This pattern will depends on file systems grow policies.

        Specified by:
        getFilePattern in interface PropertiesLoader
        Returns:
        a String representing the pattern
      • getRemotePackages

        public List<String> getRemotePackages()
        Description copied from interface: PropertiesLoader
        Get a List of Packages to configure the Log Hierarchy. By default The logger engine will consider the same pattern from log4j. For example, the LoggerConfig named "com.foo" is a parent of the LoggerConfig named "com.foo.Bar". Similarly,"java" is a parent of "java.util" and an ancestor of "java.util.Vector". This naming scheme should be familiar to most developers.
        Specified by:
        getRemotePackages in interface PropertiesLoader
        Returns:
        a List of String representing packages Namespaces
        See Also:
        log4j/2.x/manual/architecture.html
      • getRemotePatternLayout

        public String getRemotePatternLayout()
        Description copied from interface: PropertiesLoader
        Gets Remote Pattern Layout.

        More often than not, users wish to customize not only the output destination but also the output format. This is accomplished by associating a Layout with an Appender. The Layout is responsible for formatting the LogEvent according to the user's wishes, whereas an appender takes care of sending the formatted output to its destination.

        Specified by:
        getRemotePatternLayout in interface PropertiesLoader
        Returns:
        a Pattern Layout String
        See Also:
        log4j/2.x/manual/layouts.html