Top Description Constructors Methods
io.undertow.util

public abstract Class AttachmentKey<T>

Additional top-level class in compilation unit: ListAttachmentKey.

extends Object
Class Inheritance
Known Direct Subclasses
io.undertow.util.ListAttachmentKey, io.undertow.util.SimpleAttachmentKey
Type Parameters
<T>
the attachment type

An immutable, type-safe object attachment key. Such a key has no value outside of its object identity.

Constructor Summary

AccessConstructor and Description
pack-priv

Method Summary

Modifier and TypeMethod and Description
public abstract T

Returns:

the cast value
cast
(Object
the value
value
)

Cast the value to the type of this attachment key.

public static <
the attachment type
T
>
AttachmentKey<T>

Returns:

the new instance
create
(final Class<? super T>
the value class
valueClass
)

Construct a new simple attachment key.

public static <
the list value type
T
>
AttachmentKey<AttachmentList<T>>

Returns:

the new instance
createList
(final Class<? super T>
the list value class
valueClass
)

Construct a new list attachment key.

Inherited from java.lang.Object:
cloneequalsfinalizegetClasshashCodenotifynotifyAlltoStringwaitwaitwait

Constructor Detail

AttachmentKeyback to summary
pack-priv AttachmentKey()

Method Detail

castback to summary
public abstract T cast(Object value)

Cast the value to the type of this attachment key.

Parameters
value:Object

the value

Returns:T

the cast value

createback to summary
public static <T> AttachmentKey<T> create(final Class<? super T> valueClass)

Construct a new simple attachment key.

Parameters
<T>
the attachment type
valueClass:Class<? super T>

the value class

Returns:AttachmentKey<T>

the new instance

createListback to summary
public static <T> AttachmentKey<AttachmentList<T>> createList(final Class<? super T> valueClass)

Construct a new list attachment key.

Parameters
<T>
the list value type
valueClass:Class<? super T>

the list value class

Returns:AttachmentKey<AttachmentList<T>>

the new instance

Annotations
@SuppressWarnings:unchecked