Package net.java.ao.schema.info
Interface EntityInfo<T extends RawEntity<K>,K>
- Type Parameters:
T
- theentity
interfaceK
- the primary key for the entity
public interface EntityInfo<T extends RawEntity<K>,K>
A description of the table generated by the
RawEntity
Note this is different to TypeInfo
which describes what type a column is in the database.
EntityInfo
describes the table.- Since:
- 0.21
-
Method Summary
Modifier and TypeMethodDescriptiongetName()
boolean
hasAccessor
(Method method) boolean
boolean
hasMutator
(Method method)
-
Method Details
-
getEntityType
- Returns:
- the inteface for the entity
<T>
-
getName
String getName()- Returns:
- the name of the table
-
getPrimaryKey
- Returns:
- the primary key for the table
-
getFields
- Returns:
- all the fields for the table
-
getFieldNames
- Returns:
- all the field names for the table
- See Also:
-
getField
-
getField
- Parameters:
fieldName
- the name of the database column- Returns:
- the
FieldInfo
associated with the fieldName
-
hasAccessor
- Parameters:
method
- the method to test whether it is an accessor- Returns:
true
if the method is an accessor for theentity
,false
otherwise
-
hasMutator
- Parameters:
method
- the method to test whether it is an mutator- Returns:
true
if the method is an mutator for theentity
,false
otherwise
-
hasField
- Parameters:
fieldName
- the name of the database column- Returns:
true
if the fieldName is associated with theentity
,false
otherwise
-