public class FormatKey<T>
extends java.lang.Object
implements java.io.Serializable, java.lang.Comparable
Format
.
A format key has a name, a type and a value.
Modifier and Type | Field and Description |
---|---|
static long |
serialVersionUID |
Constructor and Description |
---|
FormatKey(java.lang.String key,
java.lang.Class<T> clazz)
Creates a new instance with the specified attribute key, type token class,
default value null, and allowing null values.
|
FormatKey(java.lang.String key,
java.lang.String name,
java.lang.Class<T> clazz)
Creates a new instance with the specified attribute key, type token class,
default value null, and allowing null values.
|
FormatKey(java.lang.String key,
java.lang.String name,
java.lang.Class<T> clazz,
boolean comment)
Creates a new instance with the specified attribute key, type token class,
default value null, and allowing null values.
|
Modifier and Type | Method and Description |
---|---|
int |
compareTo(FormatKey that) |
int |
compareTo(java.lang.Object o) |
java.lang.String |
getKey()
Returns the key string.
|
java.lang.String |
getName()
Returns the pretty name string.
|
java.lang.Class |
getValueClass() |
boolean |
isAssignable(java.lang.Object value)
Returns true if the specified value is assignable with this key.
|
boolean |
isComment() |
java.lang.String |
toString()
Returns the key string.
|
public static final long serialVersionUID
public FormatKey(java.lang.String key, java.lang.Class<T> clazz)
public FormatKey(java.lang.String key, java.lang.String name, java.lang.Class<T> clazz)
public FormatKey(java.lang.String key, java.lang.String name, java.lang.Class<T> clazz, boolean comment)
public java.lang.String getKey()
public java.lang.String getName()
public java.lang.String toString()
toString
in class java.lang.Object
public boolean isAssignable(java.lang.Object value)
value
- public boolean isComment()
public java.lang.Class getValueClass()
public int compareTo(java.lang.Object o)
compareTo
in interface java.lang.Comparable
public int compareTo(FormatKey that)