Package io.servicetalk.log4j2.mdc.utils
Class ServiceTalkThreadContextMap
- java.lang.Object
-
- io.servicetalk.log4j2.mdc.utils.ServiceTalkThreadContextMap
-
- All Implemented Interfaces:
org.apache.logging.log4j.spi.CleanableThreadContextMap
,org.apache.logging.log4j.spi.ReadOnlyThreadContextMap
,org.apache.logging.log4j.spi.ThreadContextMap
,org.apache.logging.log4j.spi.ThreadContextMap2
- Direct Known Subclasses:
ServiceTalkTracingThreadContextMap
public class ServiceTalkThreadContextMap extends java.lang.Object implements org.apache.logging.log4j.spi.ReadOnlyThreadContextMap, org.apache.logging.log4j.spi.CleanableThreadContextMap
AThreadContext
that provides storage for MDC based uponAsyncContext
.
-
-
Constructor Summary
Constructors Constructor Description ServiceTalkThreadContextMap()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
clear()
boolean
containsKey(java.lang.String key)
java.lang.String
get(java.lang.String key)
java.util.Map<java.lang.String,java.lang.String>
getCopy()
protected java.util.Map<java.lang.String,java.lang.String>
getCopyOrNull()
java.util.Map<java.lang.String,java.lang.String>
getImmutableMapOrNull()
org.apache.logging.log4j.util.StringMap
getReadOnlyContextData()
boolean
isEmpty()
void
put(java.lang.String key, java.lang.String value)
void
putAll(java.util.Map<java.lang.String,java.lang.String> map)
void
remove(java.lang.String key)
void
removeAll(java.lang.Iterable<java.lang.String> keys)
-
-
-
Method Detail
-
put
public final void put(java.lang.String key, java.lang.String value)
- Specified by:
put
in interfaceorg.apache.logging.log4j.spi.ThreadContextMap
-
get
@Nullable public java.lang.String get(java.lang.String key)
- Specified by:
get
in interfaceorg.apache.logging.log4j.spi.ReadOnlyThreadContextMap
- Specified by:
get
in interfaceorg.apache.logging.log4j.spi.ThreadContextMap
-
remove
public final void remove(java.lang.String key)
- Specified by:
remove
in interfaceorg.apache.logging.log4j.spi.ThreadContextMap
-
clear
public final void clear()
- Specified by:
clear
in interfaceorg.apache.logging.log4j.spi.ReadOnlyThreadContextMap
- Specified by:
clear
in interfaceorg.apache.logging.log4j.spi.ThreadContextMap
-
containsKey
public boolean containsKey(java.lang.String key)
- Specified by:
containsKey
in interfaceorg.apache.logging.log4j.spi.ReadOnlyThreadContextMap
- Specified by:
containsKey
in interfaceorg.apache.logging.log4j.spi.ThreadContextMap
-
getCopy
public java.util.Map<java.lang.String,java.lang.String> getCopy()
- Specified by:
getCopy
in interfaceorg.apache.logging.log4j.spi.ReadOnlyThreadContextMap
- Specified by:
getCopy
in interfaceorg.apache.logging.log4j.spi.ThreadContextMap
-
getImmutableMapOrNull
@Nullable public java.util.Map<java.lang.String,java.lang.String> getImmutableMapOrNull()
- Specified by:
getImmutableMapOrNull
in interfaceorg.apache.logging.log4j.spi.ReadOnlyThreadContextMap
- Specified by:
getImmutableMapOrNull
in interfaceorg.apache.logging.log4j.spi.ThreadContextMap
-
isEmpty
public boolean isEmpty()
- Specified by:
isEmpty
in interfaceorg.apache.logging.log4j.spi.ReadOnlyThreadContextMap
- Specified by:
isEmpty
in interfaceorg.apache.logging.log4j.spi.ThreadContextMap
-
removeAll
public final void removeAll(java.lang.Iterable<java.lang.String> keys)
- Specified by:
removeAll
in interfaceorg.apache.logging.log4j.spi.CleanableThreadContextMap
-
putAll
public final void putAll(java.util.Map<java.lang.String,java.lang.String> map)
- Specified by:
putAll
in interfaceorg.apache.logging.log4j.spi.ThreadContextMap2
-
getReadOnlyContextData
public org.apache.logging.log4j.util.StringMap getReadOnlyContextData()
- Specified by:
getReadOnlyContextData
in interfaceorg.apache.logging.log4j.spi.ReadOnlyThreadContextMap
- Specified by:
getReadOnlyContextData
in interfaceorg.apache.logging.log4j.spi.ThreadContextMap2
-
getCopyOrNull
@Nullable protected java.util.Map<java.lang.String,java.lang.String> getCopyOrNull()
-
-