Package grails.core
Interface GrailsServiceClass
-
- All Superinterfaces:
org.springframework.beans.factory.Aware,GrailsApplicationAware,GrailsClass,InjectableGrailsClass
- All Known Implementing Classes:
DefaultGrailsServiceClass
public interface GrailsServiceClass extends InjectableGrailsClass
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.StringALL_DATA_SOURCESstatic java.lang.StringDATA_SOURCEstatic java.lang.StringDEFAULT_DATA_SOURCE
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.lang.StringgetDatasource()Get the datasource name that this service class works with.booleanisTransactional()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 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
-
DATA_SOURCE
static final java.lang.String DATA_SOURCE
- See Also:
- Constant Field Values
-
DEFAULT_DATA_SOURCE
static final java.lang.String DEFAULT_DATA_SOURCE
- See Also:
- Constant Field Values
-
ALL_DATA_SOURCES
static final java.lang.String ALL_DATA_SOURCES
- See Also:
- Constant Field Values
-
-
Method Detail
-
isTransactional
boolean isTransactional()
Service should be configured with transaction demarcation.- Returns:
- configure with transaction demarcation
-
getDatasource
java.lang.String getDatasource()
Get the datasource name that this service class works with.- Returns:
- the name
-
usesDatasource
boolean usesDatasource(java.lang.String name)
Check if the service class can use the named DataSource.- Parameters:
name- the name
-
-