T
- The type of value that can be set with the key.@Immutable public interface AttributeKey<T> extends java.lang.Comparable<AttributeKey>
Attributes
. The type of value
that can be set with an implementation of this key is denoted by the type parameter.
Implementations MUST be immutable, as these are used as the keys to Maps.
Modifier and Type | Method and Description |
---|---|
static AttributeKey<java.util.List<java.lang.Boolean>> |
booleanArrayKey(java.lang.String key)
Returns a new AttributeKey for List<Boolean> valued attributes.
|
static AttributeKey<java.lang.Boolean> |
booleanKey(java.lang.String key)
Returns a new AttributeKey for Boolean valued attributes.
|
static AttributeKey<java.util.List<java.lang.Double>> |
doubleArrayKey(java.lang.String key)
Returns a new AttributeKey for List<Double> valued attributes.
|
static AttributeKey<java.lang.Double> |
doubleKey(java.lang.String key)
Returns a new AttributeKey for Double valued attributes.
|
java.lang.String |
getKey()
Returns the underlying String representation of the key.
|
AttributeType |
getType()
Returns the type of attribute for this key.
|
static AttributeKey<java.util.List<java.lang.Long>> |
longArrayKey(java.lang.String key)
Returns a new AttributeKey for List<Long> valued attributes.
|
static AttributeKey<java.lang.Long> |
longKey(java.lang.String key)
Returns a new AttributeKey for Long valued attributes.
|
static AttributeKey<java.util.List<java.lang.String>> |
stringArrayKey(java.lang.String key)
Returns a new AttributeKey for List<String> valued attributes.
|
static AttributeKey<java.lang.String> |
stringKey(java.lang.String key)
Returns a new AttributeKey for String valued attributes.
|
java.lang.String getKey()
@Nonnull AttributeType getType()
static AttributeKey<java.lang.String> stringKey(java.lang.String key)
static AttributeKey<java.lang.Boolean> booleanKey(java.lang.String key)
static AttributeKey<java.lang.Long> longKey(java.lang.String key)
static AttributeKey<java.lang.Double> doubleKey(java.lang.String key)
static AttributeKey<java.util.List<java.lang.String>> stringArrayKey(java.lang.String key)
static AttributeKey<java.util.List<java.lang.Boolean>> booleanArrayKey(java.lang.String key)
static AttributeKey<java.util.List<java.lang.Long>> longArrayKey(java.lang.String key)
static AttributeKey<java.util.List<java.lang.Double>> doubleArrayKey(java.lang.String key)