|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
public interface GrailsDomainClassProperty
A property of a GrailsDomainClass instance
Field Summary | |
---|---|
static String |
BELONGS_TO
|
static String |
CLASS
|
static String |
CONSTRAINTS
|
static String |
DATE_CREATED
|
static String |
EMBEDDED
|
static String |
EVANESCENT
|
static int |
FETCH_EAGER
|
static int |
FETCH_LAZY
|
static String |
FETCH_MODE
|
static String |
HAS_MANY
|
static String |
HAS_ONE
|
static String |
IDENTITY
|
static String |
LAST_UPDATED
|
static String |
MAPPED_BY
|
static String |
MAPPING
|
static String |
MAPPING_STRATEGY
|
static String |
META_CLASS
|
static String |
NAMED_QUERIES
|
static String |
RELATES_TO_MANY
|
static String |
SORT
|
static String |
TRANSIENT
|
static String |
VERSION
|
Method Summary | |
---|---|
GrailsDomainClass |
getComponent()
If #isEmbedded returns true then this method can be called to obtain a reference to the embedded component, which implements the GrailsDomainClass interface |
GrailsDomainClass |
getDomainClass()
Returns the parent domain class of the property instance |
int |
getFetchMode()
Returns the configured fetch mode for the property |
String |
getFieldName()
Returns the domain field name for this property |
String |
getName()
Returns the name of the property |
String |
getNaturalName()
|
GrailsDomainClassProperty |
getOtherSide()
Returns the other side of a bidirectional association |
GrailsDomainClass |
getReferencedDomainClass()
Returns the GrailsDomainClass of a relationship property or null if the property is not a relationship property |
String |
getReferencedPropertyName()
Retrieves the name of property referenced by this property if it is an association and is known, otherwise null |
Class |
getReferencedPropertyType()
Returns the referenced property type. |
Class |
getType()
Returns the type for the domain class |
String |
getTypePropertyName()
Returns the class type as a property name representation |
boolean |
isAssociation()
Returns true if this property is a relationship property |
boolean |
isBasicCollectionType()
Return whether this is a collection of basic types like String, Integer etc. |
boolean |
isBidirectional()
Returns true if the property is a bi-directional relationship |
boolean |
isCircular()
Whether the relationship is cirucular |
boolean |
isEmbedded()
Returns true if this propert is an embedded component |
boolean |
isEnum()
Returns true if this properties type is an enum |
boolean |
isHasOne()
|
boolean |
isIdentity()
Returns true of the property is an identifier |
boolean |
isInherited()
Whether the property is inherited from a super class |
boolean |
isManyToMany()
Returns true if the property is a many-to-many relationship |
boolean |
isManyToOne()
Returns true if the property is a many-to-one relationship |
boolean |
isOneToMany()
Returns true if the property is a one-to-many relationship |
boolean |
isOneToOne()
Returns true if the property is a one-to-one relationship |
boolean |
isOptional()
Returns true if the property is required |
boolean |
isOwningSide()
Whether this side of the association is the "owning" side |
boolean |
isPersistent()
Returns true if the domain class property is a persistent property |
void |
setOtherSide(GrailsDomainClassProperty referencedProperty)
Sets the other side of an associative property |
void |
setOwningSide(boolean b)
|
void |
setReferencedDomainClass(GrailsDomainClass referencedGrailsDomainClass)
Sets the references domain class on the property |
Field Detail |
---|
static final String IDENTITY
static final String VERSION
static final String TRANSIENT
static final String CONSTRAINTS
static final String EVANESCENT
static final String RELATES_TO_MANY
static final String META_CLASS
static final String CLASS
static final String MAPPING_STRATEGY
static final String MAPPED_BY
static final String BELONGS_TO
static final String HAS_MANY
static final String HAS_ONE
static final String FETCH_MODE
static final String DATE_CREATED
static final String MAPPING
static final String NAMED_QUERIES
static final String LAST_UPDATED
static final String SORT
static final String EMBEDDED
static final int FETCH_EAGER
static final int FETCH_LAZY
Method Detail |
---|
int getFetchMode()
String getName()
Class getType()
Class getReferencedPropertyType()
Returns the referenced property type. This differs from getType() in that in the case of an Association it will return the type of the elements contained within the Collection, otherwise it will delegate to getType();
GrailsDomainClassProperty getOtherSide()
Returns the other side of a bidirectional association
String getTypePropertyName()
GrailsDomainClass getDomainClass()
boolean isPersistent()
boolean isOptional()
boolean isIdentity()
boolean isOneToMany()
boolean isManyToOne()
boolean isManyToMany()
boolean isBidirectional()
String getFieldName()
boolean isOneToOne()
GrailsDomainClass getReferencedDomainClass()
boolean isAssociation()
boolean isEnum()
String getNaturalName()
void setReferencedDomainClass(GrailsDomainClass referencedGrailsDomainClass)
referencedGrailsDomainClass
- void setOtherSide(GrailsDomainClassProperty referencedProperty)
referencedProperty
- boolean isInherited()
boolean isOwningSide()
boolean isCircular()
String getReferencedPropertyName()
boolean isEmbedded()
GrailsDomainClass getComponent()
GrailsDomainClass
,
isEmbedded()
void setOwningSide(boolean b)
boolean isBasicCollectionType()
boolean isHasOne()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |