|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.codehaus.groovy.grails.commons.GrailsDomainConfigurationUtil
public class GrailsDomainConfigurationUtil
Utility methods used in configuring the Grails Hibernate integration
| Constructor Summary | |
|---|---|
GrailsDomainConfigurationUtil()
|
|
| Method Summary | |
|---|---|
static void |
configureDomainClassRelationships(GrailsClass[] domainClasses,
Map domainMap)
Configures the relationships between domain classes after they have been all loaded. |
static Map |
evaluateConstraints(Object instance,
GrailsDomainClassProperty[] properties)
Evaluates the constraints closure to build the list of constraints |
static Map |
getAssociationMap(Class domainClass)
Returns the association map for the specified domain class |
static Map |
getMappedByMap(Class domainClass)
Retrieves the mappedBy map for the specified class |
static String |
getMappingFileName(String className)
Returns the ORM frameworks mapping file name for the specified class name |
static boolean |
isBasicType(Class propType)
|
static boolean |
isBasicType(GrailsDomainClassProperty prop)
Establish whether its a basic type |
static boolean |
isNotConfigurational(PropertyDescriptor descriptor)
Checks whether is property is configurational |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public GrailsDomainConfigurationUtil()
| Method Detail |
|---|
public static void configureDomainClassRelationships(GrailsClass[] domainClasses,
Map domainMap)
domainClasses - The domain classes to configure relationships fordomainMap - The domain class mappublic static String getMappingFileName(String className)
className - The class name of the mapped file
public static Map getAssociationMap(Class domainClass)
domainClass - the domain class
public static Map getMappedByMap(Class domainClass)
domainClass - The domain class
public static boolean isBasicType(GrailsDomainClassProperty prop)
prop - The domain class property
public static boolean isBasicType(Class propType)
public static boolean isNotConfigurational(PropertyDescriptor descriptor)
descriptor - The descriptor
public static Map evaluateConstraints(Object instance,
GrailsDomainClassProperty[] properties)
throws IntrospectionException
instance - The instance to evaluate constraints forproperties - The properties of the instance
IntrospectionException - When the bean cannot be introspected
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||