public class FormatKey<T> extends Object implements Serializable, 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(String key,
Class<T> clazz)
Creates a new instance with the specified attribute key, type token class,
default value null, and allowing null values.
|
FormatKey(String key,
String name,
Class<T> clazz)
Creates a new instance with the specified attribute key, type token class,
default value null, and allowing null values.
|
FormatKey(String key,
String name,
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(Object o) |
String |
getKey()
Returns the key string.
|
String |
getName()
Returns the pretty name string.
|
Class |
getValueClass() |
boolean |
isAssignable(Object value)
Returns true if the specified value is assignable with this key.
|
boolean |
isComment() |
String |
toString()
Returns the key string.
|
public static final long serialVersionUID
public FormatKey(String key, Class<T> clazz)
public FormatKey(String key, String name, Class<T> clazz)
public String getKey()
public String getName()
public boolean isAssignable(Object value)
value - public boolean isComment()
public Class getValueClass()
public int compareTo(Object o)
compareTo in interface Comparablepublic int compareTo(FormatKey that)
Copyright © 2014. All Rights Reserved.