Package io.servicetalk.concurrent.api
Class AsyncContextMap.Key<T>
- java.lang.Object
-
- io.servicetalk.concurrent.api.AsyncContextMap.Key<T>
-
- Type Parameters:
T- The type of value associated with aAsyncContextMap.Key.
- Enclosing interface:
- AsyncContextMap
public static final class AsyncContextMap.Key<T> extends java.lang.ObjectA key identifies a specific object in aAsyncContextMap.
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static <T> AsyncContextMap.Key<T>newKey()Create a new instance.static <T> AsyncContextMap.Key<T>newKey(java.lang.String toString)Create a newAsyncContextMap.Keywhich has aStringused only in thetoString()method for debugging visibility.java.lang.StringtoString()
-
-
-
Method Detail
-
newKey
public static <T> AsyncContextMap.Key<T> newKey(java.lang.String toString)
Create a newAsyncContextMap.Keywhich has aStringused only in thetoString()method for debugging visibility.Comparison between
AsyncContextMap.Keyobjects should be assumed to be on an instance basis. In generalnewKey(str) != newKey(str).- Type Parameters:
T- The value type associated with theAsyncContextMap.Key.- Parameters:
toString- The value to use intoString(). This WILL NOT be used in comparisons betweenAsyncContextMap.Keyobjects.- Returns:
- a new
AsyncContextMap.Keywhich has aStringused only in thetoString()method for debugging visibility.
-
newKey
public static <T> AsyncContextMap.Key<T> newKey()
Create a new instance.Comparison between
AsyncContextMap.Keyobjects should be assumed to be on an instance basis. In generalnewKey() != newKey().- Type Parameters:
T- The value type associated with theAsyncContextMap.Key.- Returns:
- a new instance.
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-