public interface Entity
| Modifier and Type | Method and Description |
|---|---|
EntityBuilder |
entityBuilder()
Get an
EntityBuilder
pre-filled with the state of
this Entity to create
a mutable clone as Entity
instances must be immutable |
Link |
getLink(java.lang.String rel)
Get the named
Link |
java.util.Map<java.lang.String,Link> |
getLinks()
Return all
Link
in a Map keyed
with the name |
java.util.Map<java.lang.String,java.lang.Object> |
getProperties()
Get all properties in a
Map
keyed with the name of the property |
java.lang.Object |
getProperty(java.lang.String key)
Get the named property
as an
Object |
<T> T |
getProperty(java.lang.String key,
java.lang.Class<T> convertTo)
Get a property with type
|
java.lang.String |
getProperty(java.lang.String key,
java.text.Format format)
Get a property as a formattted
string using the supplied
Format |
<T> T |
getProperty(java.lang.String key,
PropertyConverter<T,java.lang.Object> converter)
Get a property with
the type
Object using
the supplied PropertyConverter |
java.util.Collection<Entity> |
getRelation(java.lang.String rel)
Get the named relation
|
java.util.Map<java.lang.String,java.util.Collection<Entity>> |
getRelations()
Get a
Map containing
all related Entity keyed with
name (rel). |
java.util.Map<java.lang.String,Link> getLinks()
Link
in a Map keyed
with the nameMap of Linkjava.lang.Object getProperty(java.lang.String key)
Objectkey - name of propertyObject form<T> T getProperty(java.lang.String key,
java.lang.Class<T> convertTo)
key - convertTo - <T> T getProperty(java.lang.String key,
PropertyConverter<T,java.lang.Object> converter)
Object using
the supplied PropertyConverterkey - name of property to convert and returnconverter - PropertyConverter to perform conversionsjava.lang.String getProperty(java.lang.String key,
java.text.Format format)
Formatkey - format - java.util.Map<java.lang.String,java.lang.Object> getProperties()
Map
keyed with the name of the propertyMap of propertiesjava.util.Map<java.lang.String,java.util.Collection<Entity>> getRelations()
Map containing
all related Entity keyed with
name (rel).Map with Entityjava.util.Collection<Entity> getRelation(java.lang.String rel)
rel - String name of the relation to fetchCollection of Entity that have this nameEntityBuilder entityBuilder()
EntityBuilder
pre-filled with the state of
this Entity to create
a mutable clone as Entity
instances must be immutableEntityBuilder for this Entity