Interface DomainProperty
-
- All Superinterfaces:
java.lang.Comparable<DomainProperty>,org.grails.datastore.mapping.model.PersistentProperty
public interface DomainProperty extends org.grails.datastore.mapping.model.PersistentProperty, java.lang.Comparable<DomainProperty>
An API to join thePersistentPropertyto theValidatorto assist with scaffolding
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description org.grails.datastore.mapping.model.PersistentEntitygetAssociatedEntity()java.lang.ClassgetAssociatedType()java.lang.ClassgetBeanType()org.grails.scaffolding.model.property.ConstrainedgetConstrained()java.lang.StringgetDefaultLabel()org.grails.datastore.mapping.model.PersistentEntitygetDomainClass()java.util.List<java.lang.String>getLabelKeys()java.lang.StringgetPathFromRoot()org.grails.datastore.mapping.model.PersistentPropertygetPersistentProperty()java.lang.ClassgetRootBeanType()org.grails.datastore.mapping.model.PersistentPropertygetRootProperty()booleanisRequired()voidsetRootProperty(org.grails.datastore.mapping.model.PersistentProperty rootProperty)Sets the root property
-
-
-
Method Detail
-
getPathFromRoot
java.lang.String getPathFromRoot()
- Returns:
- The path of the property from the root domain class
-
getPersistentProperty
org.grails.datastore.mapping.model.PersistentProperty getPersistentProperty()
- Returns:
- The
PersistentPropertythat represents this property
-
getDomainClass
org.grails.datastore.mapping.model.PersistentEntity getDomainClass()
- Returns:
- The
PersistentEntitythe property belongs to
-
getConstrained
org.grails.scaffolding.model.property.Constrained getConstrained()
- Returns:
- The constraints of the property
-
getRootProperty
org.grails.datastore.mapping.model.PersistentProperty getRootProperty()
- Returns:
- The root property
-
setRootProperty
void setRootProperty(org.grails.datastore.mapping.model.PersistentProperty rootProperty)
Sets the root property- Parameters:
rootProperty- The root property
-
getRootBeanType
java.lang.Class getRootBeanType()
- Returns:
- The class the root property belongs to
-
getBeanType
java.lang.Class getBeanType()
- Returns:
- The class the property belongs to
-
getAssociatedType
java.lang.Class getAssociatedType()
- Returns:
- The type of the association
-
getAssociatedEntity
org.grails.datastore.mapping.model.PersistentEntity getAssociatedEntity()
- Returns:
- The associated entity if the property is an assocation
-
isRequired
boolean isRequired()
- Returns:
- Whether the property is required
-
getLabelKeys
java.util.List<java.lang.String> getLabelKeys()
- Returns:
- i18n message keys to resolve the label of the property
-
getDefaultLabel
java.lang.String getDefaultLabel()
- Returns:
- The default label for the property (natural name)
-
-