Package org.grails.core
Class DefaultGrailsServiceClass
- java.lang.Object
-
- org.grails.core.AbstractGrailsClass
-
- org.grails.core.AbstractInjectableGrailsClass
-
- org.grails.core.DefaultGrailsServiceClass
-
- All Implemented Interfaces:
GrailsClass,GrailsServiceClass,InjectableGrailsClass,GrailsApplicationAware,org.springframework.beans.factory.Aware
public class DefaultGrailsServiceClass extends AbstractInjectableGrailsClass implements GrailsServiceClass
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringSERVICE-
Fields inherited from class org.grails.core.AbstractGrailsClass
grailsApplication
-
Fields inherited from interface grails.core.GrailsServiceClass
ALL_DATA_SOURCES, DATA_SOURCE, DEFAULT_DATA_SOURCE
-
-
Constructor Summary
Constructors Constructor Description DefaultGrailsServiceClass(java.lang.Class<?> clazz)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetDatasource()If service is transactional then get data source will always applybooleanisTransactional()Service should be configured with transaction demarcation.booleanusesDatasource(java.lang.String name)Check if the service class can use the named DataSource.-
Methods inherited from class org.grails.core.AbstractInjectableGrailsClass
byName, byType, getAvailable
-
Methods inherited from class org.grails.core.AbstractGrailsClass
getApplication, getClazz, getFullName, getLogicalPropertyName, getMetaClass, getMetaProperties, getName, getNaturalName, getPackageName, getPluginName, getPropertyDescriptors, getPropertyName, getPropertyOrStaticPropertyOrFieldValue, getPropertyType, getPropertyValue, getPropertyValue, getPropertyValueObject, getReferenceInstance, getShortName, getStaticPropertyValue, hasMetaMethod, hasMetaMethod, hasMetaProperty, hasProperty, isAbstract, isActionMethod, isReadableProperty, newInstance, setGrailsApplication, toString
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface grails.core.support.GrailsApplicationAware
setGrailsApplication
-
Methods inherited from interface grails.core.GrailsClass
getApplication, getClazz, getFullName, getLogicalPropertyName, getMetaClass, getName, getNaturalName, getPackageName, getPluginName, getPropertyName, getPropertyValue, getPropertyValue, getReferenceInstance, getShortName, hasProperty, isAbstract, newInstance
-
Methods inherited from interface grails.core.InjectableGrailsClass
byName, byType, getAvailable
-
-
-
-
Field Detail
-
SERVICE
public static final java.lang.String SERVICE
- See Also:
- Constant Field Values
-
-
Method Detail
-
isTransactional
public boolean isTransactional()
Description copied from interface:GrailsServiceClassService should be configured with transaction demarcation.- Specified by:
isTransactionalin interfaceGrailsServiceClass- Returns:
- configure with transaction demarcation
-
getDatasource
public java.lang.String getDatasource()
If service is transactional then get data source will always apply- Specified by:
getDatasourcein interfaceGrailsServiceClass- Returns:
- name of data source
-
usesDatasource
public boolean usesDatasource(java.lang.String name)
Description copied from interface:GrailsServiceClassCheck if the service class can use the named DataSource.- Specified by:
usesDatasourcein interfaceGrailsServiceClass- Parameters:
name- the name
-
-