Class ContextMapLookup
- java.lang.Object
-
- org.apache.logging.log4j.core.lookup.ContextMapLookup
-
- All Implemented Interfaces:
StrLookup
@Plugin(name="ctx", category="Lookup") public class ContextMapLookup extends Object implements StrLookup
Looks up keys from the context. By default this is theThreadContext
, but users may configure a customContextDataInjector
which obtains context data from some other source.
-
-
Constructor Summary
Constructors Constructor Description ContextMapLookup()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
lookup(String key)
Looks up the value from the ThreadContext Map.String
lookup(LogEvent event, String key)
Looks up the value from the ThreadContext Map.
-