Package org.apache.logging.log4j.util
Internal utility classes for the Log4j 2 API. Note that the use of any classes in this package is not supported.
There are no guarantees for binary or logical compatibility in this package.
-
Interface Summary Interface Description BiConsumer<K,V> An operation that accepts two input arguments and returns no result.IndexedReadOnlyStringMap An extension ofReadOnlyStringMap
that imposes a total ordering on its keys.IndexedStringMap An extension ofStringMap
that imposes a total ordering on its keys.MessageSupplier Classes implementing this interface know how to supplyMessage
s.MultiFormatStringBuilderFormattable A Message that can render itself in more than one way.PropertySource A source for global configuration properties.ReadOnlyStringMap A read-only collection of String keys mapped to values of arbitrary type.StringBuilderFormattable Objects that implement this interface can be converted to text, ideally without allocating temporary objects.StringMap Exposes methods to add and remove key-value pairs to and fromReadOnlyStringMap
.Supplier<T> Consider this class private. Classes implementing this interface know how to supply a value.TriConsumer<K,V,S> An operation that accepts three input arguments and returns no result. -
Class Summary Class Description Base64Util Base64 encodes Strings.Chars Consider this class private.Constants Log4j API Constants.EnglishEnums Consider this class private.EnvironmentPropertySource PropertySource implementation that uses environment variables as a source.FilteredObjectInputStream ExtendsObjectInputStream
to only allow some built-in Log4j classes and caller-specified classes to be deserialized.LambdaUtil Utility class for lambda support.LoaderUtil Consider this class private. Utility class for ClassLoaders.LoaderUtil.ThreadContextClassLoaderGetter LoaderUtil.UrlResource URL
andClassLoader
pair.LowLevelLogUtil PrintWriter-based logging utility for classes too low level to useStatusLogger
.OsgiServiceLocator PrivateSecurityManagerStackTraceUtil Internal utility to share a fast implementation of#getCurrentStackTrace()
with the java 9 implementation ofStackLocator
.PrivateSecurityManagerStackTraceUtil.PrivateSecurityManager ProcessIdUtil PropertiesPropertySource PropertySource backed by aProperties
instance.PropertiesUtil Consider this class private.PropertiesUtil.Environment Provides support for looking up global configuration properties via environment variables, property files, and system properties, in three variations:PropertyFilePropertySource PropertySource backed by a properties file.PropertySource.Comparator Comparator for ordering PropertySource instances by priority.PropertySource.Util Utility methods useful for PropertySource implementations.ProviderActivator Utility class to register Log4j2 providers in an OSGI environment.ProviderUtil Consider this class private. Utility class for Log4jProvider
s.ServiceLoaderUtil This class should be considered internal.ServiceLoaderUtil.ServiceLoaderSpliterator<S> SortedArrayStringMap Consider this class private. Array-based implementation of theReadOnlyStringMap
interface.StackLocator Consider this class private. Provides various methods to determine the caller class.StackLocatorUtil Consider this class private. Provides various methods to determine the caller class.StringBuilders Consider this class private.Strings Consider this class private.SystemPropertiesPropertySource PropertySource backed by the current system properties.Timer Primarily used in unit tests, but can be used to track elapsed time for a request or portion of any other operation so long as all the timer methods are called on the same thread in which it was started.Unbox Utility for preventing primitive parameter values from being auto-boxed.Unbox.State Unbox.WebSafeState State implementation that only puts JDK classes in ThreadLocals, so this is safe to be used from web applications. -
Enum Summary Enum Description PropertiesUtil.TimeUnit Timer.Status -
Annotation Types Summary Annotation Type Description PerformanceSensitive Indicates that a particular annotated construct was written with certain performance constraints in mind that should be considered when modifying or testing.