public interface GrailsClass extends GrailsApplicationAware
Modifier and Type | Method and Description |
---|---|
java.lang.Class |
getClazz()
Returns the actual clazz represented by the GrailsClass.
|
java.lang.String |
getFullName()
Returns the full name of the class in the application with the the trailing convention part and with
the package name.
|
GrailsApplication |
getGrailsApplication()
The GrailsApplication that this class belongs to
|
java.lang.String |
getLogicalPropertyName()
Returns the logical name of the class as a property name.
|
MetaClass |
getMetaClass() |
java.lang.String |
getName()
Returns the logical name of the class in the application without the trailing convention part if applicable
and without the package name.
|
java.lang.String |
getNaturalName()
Returns the name of the property in natural terms (eg.
|
java.lang.String |
getPackageName()
Returns the package name of the class.
|
java.lang.String |
getPropertyName()
Returns the name of the class as a property name.
|
java.lang.Object |
getPropertyValue(java.lang.String name)
Gets the initial value of the given property on the class.
|
<T> T |
getPropertyValue(java.lang.String name,
java.lang.Class<T> type)
Obtains a property value for the given name and type
|
BeanWrapper |
getReference()
Deprecated.
|
java.lang.Object |
getReferenceInstance() |
java.lang.String |
getShortName()
Returns the short name of the class without package prefix.
|
boolean |
hasProperty(java.lang.String name)
Returns true if the class has the specified property.
|
boolean |
isAbstract()
Whether the class is abstract or not
|
java.lang.Object |
newInstance()
Creates a new instance of this class.
|
setGrailsApplication
boolean isAbstract()
GrailsApplication getGrailsApplication()
java.lang.Object getPropertyValue(java.lang.String name)
name
- The name of the propertyboolean hasProperty(java.lang.String name)
name
- The name of the propertyjava.lang.Object newInstance()
java.lang.String getName()
java.lang.String getShortName()
java.lang.String getFullName()
java.lang.String getPropertyName()
java.lang.String getLogicalPropertyName()
java.lang.String getNaturalName()
java.lang.String getPackageName()
java.lang.Class getClazz()
MetaClass getMetaClass()
@Deprecated BeanWrapper getReference()
java.lang.Object getReferenceInstance()
<T> T getPropertyValue(java.lang.String name, java.lang.Class<T> type)
name
- The nametype
- The type