|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectuk.org.ury.backend.database.DatabaseItem<E,T>
public abstract class DatabaseItem<E,T>
An abstract class presenting a template for objects serving as a data structure for collections of properties retrieved from a SQL database.
Constructor Summary | |
---|---|
DatabaseItem(java.util.Map<E,T> properties)
Construct a new item from an existing list of properties. |
Method Summary | |
---|---|
java.util.Map<java.lang.String,java.lang.String> |
asResponse()
Retrieve a map of string representations of the properties. |
T |
get(E property)
Query this item for a property. |
boolean |
has(E property)
Check whether a property has been set in the item. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DatabaseItem(java.util.Map<E,T> properties)
properties
- The map of properties that the new item will inherit.Method Detail |
---|
public boolean has(E property)
public T get(E property) throws MissingPropertyException
property
- The property to query.
MissingPropertyException
- if the property does not exist.public java.util.Map<java.lang.String,java.lang.String> asResponse()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |