public class ThreadLocal2<T> extends ThreadLocal<T>
Constructor and Description |
---|
ThreadLocal2() |
Modifier and Type | Method and Description |
---|---|
T |
get()
Returns the value in the calling thread's copy of this ThreadLocal
variable.
|
Map<Thread,T> |
getThreads()
Returns the HashMap, keys are the threads
|
protected T |
initialValue()
Returns the calling thread's initial value for this ThreadLocal
variable.
|
void |
remove() |
void |
set(T value)
Sets the calling thread's instance of this ThreadLocal variable
to the given value.
|
withInitial
protected T initialValue()
initialValue
in class ThreadLocal<T>
public T get()
get
in class ThreadLocal<T>
public void set(T value)
set
in class ThreadLocal<T>
value
- the value to be stored in the calling threads' copy of
this ThreadLocal.public Map<Thread,T> getThreads()
public void remove()
remove
in class ThreadLocal<T>
@enterprise 10.0.39049 Copyright © 2024 FREQUENTIS AG. All Rights Reserved.