org.apache.logging.log4j.util

Class PropertySource.Util

  • Enclosing interface:
    PropertySource


    public static final class PropertySource.Util
    extends Object
    Utility methods useful for PropertySource implementations.
    Since:
    2.10.0
    • Method Detail

      • tokenize

        public static List<CharSequence> tokenize(CharSequence value)
        Converts a property name string into a list of tokens. This will strip a prefix of log4j, log4j2, Log4j, or org.apache.logging.log4j, along with separators of dash -, dot ., underscore _, and slash /. Tokens can also be separated by camel case conventions without needing a separator character in between.
        Parameters:
        value - property name
        Returns:
        the property broken into lower case tokens
      • joinAsCamelCase

        public static CharSequence joinAsCamelCase(Iterable<? extends CharSequence> tokens)
        Joins a list of strings using camelCaseConventions.
        Parameters:
        tokens - tokens to convert
        Returns:
        tokensAsCamelCase

Copyright © 1999-2023 The Apache Software Foundation. All Rights Reserved.
Apache Logging, Apache Log4j, Log4j, Apache, the Apache feather logo, the Apache Logging project logo, and the Apache Log4j logo are trademarks of The Apache Software Foundation.