Class StructuredDataLookup
- java.lang.Object
-
- org.apache.logging.log4j.core.lookup.AbstractLookup
-
- org.apache.logging.log4j.core.lookup.StructuredDataLookup
-
- All Implemented Interfaces:
StrLookup
@Plugin(name="sd", category="Lookup") public class StructuredDataLookup extends AbstractLookup
Looks up keys fromStructuredDataMessagelog messages.
-
-
Constructor Summary
Constructors Constructor Description StructuredDataLookup()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Stringlookup(LogEvent event, java.lang.String key)Looks up the value for the key using the data in the LogEvent.-
Methods inherited from class org.apache.logging.log4j.core.lookup.AbstractLookup
evaluate, lookup
-
-
-
-
Field Detail
-
ID_KEY
public static final java.lang.String ID_KEY
Key to obtain the id of a structured message.- See Also:
- Constant Field Values
-
TYPE_KEY
public static final java.lang.String TYPE_KEY
Key to obtain the type of a structured message.- See Also:
- Constant Field Values
-
-
Method Detail
-
lookup
public java.lang.String lookup(LogEvent event, java.lang.String key)
Looks up the value for the key using the data in the LogEvent.- Parameters:
event- The current LogEvent.key- The key to be looked up, may be null.- Returns:
- The value associated with the key.
-
-