Top Description Fields Constructors Methods
io.netty.util

public final Class AttributeKey<T>

extends AbstractConstant<AttributeKey<T>>
Class Inheritance
Annotations
@SuppressWarnings:UnusedDeclaration
Type Parameters
<T>
the type of the Attribute which can be accessed via this AttributeKey.

Key which can be used to access Attribute out of the AttributeMap. Be aware that it is not be possible to have multiple keys with the same name.

Field Summary

Modifier and TypeField and Description
private static final ConstantPool<AttributeKey<Object>>

Constructor Summary

AccessConstructor and Description
private
AttributeKey(int id, String name)

Method Summary

Modifier and TypeMethod and Description
public static boolean
exists(String name)

Returns true if a AttributeKey exists for the given name.

public static <T> AttributeKey<T>
newInstance(String name)

Creates a new AttributeKey for the given name or fail with an IllegalArgumentException if a AttributeKey for the given name exists.

public static <T> AttributeKey<T>
valueOf(String name)

Returns the singleton instance of the AttributeKey which has the specified name.

public static <T> AttributeKey<T>
valueOf(Class<?> firstNameComponent, String secondNameComponent)

Inherited from io.netty.util.AbstractConstant:
compareToequalshashCodeidnametoString

Field Detail

poolback to summary
private static final ConstantPool<AttributeKey<Object>> pool

Constructor Detail

AttributeKeyback to summary
private AttributeKey(int id, String name)

Method Detail

existsback to summary
public static boolean exists(String name)

Returns true if a AttributeKey exists for the given name.

newInstanceback to summary
public static <T> AttributeKey<T> newInstance(String name)

Creates a new AttributeKey for the given name or fail with an IllegalArgumentException if a AttributeKey for the given name exists.

Annotations
@SuppressWarnings:unchecked
valueOfback to summary
public static <T> AttributeKey<T> valueOf(String name)

Returns the singleton instance of the AttributeKey which has the specified name.

Annotations
@SuppressWarnings:unchecked
valueOfback to summary
public static <T> AttributeKey<T> valueOf(Class<?> firstNameComponent, String secondNameComponent)
Annotations
@SuppressWarnings:unchecked