Package org.seed.core.data.datasource
Class DataSourceServiceImpl
java.lang.Object
org.seed.core.data.AbstractSystemEntityService<T>
org.seed.core.application.AbstractApplicationEntityService<IDataSource>
org.seed.core.data.datasource.DataSourceServiceImpl
- All Implemented Interfaces:
ApplicationEntityService<IDataSource>
,ModuleDependent<IDataSource>
,DataSourceService
,SystemEntityService<IDataSource>
,EntityDependent<IDataSource>
,org.springframework.beans.factory.Aware
,org.springframework.context.ApplicationContextAware
@Service
public class DataSourceServiceImpl
extends AbstractApplicationEntityService<IDataSource>
implements DataSourceService, EntityDependent<IDataSource>
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptioncreateInstance
(Options options) createParameter
(IDataSource dataSource) void
deleteObject
(IDataSource dataSource) findUsage
(EntityFunction entityFunction, org.hibernate.Session session) findUsage
(Entity entity, EntityFieldGroup fieldGroup) findUsage
(Entity entity, EntityField entityField, org.hibernate.Session session) findUsage
(Entity entity, EntityRelation entityRelation, org.hibernate.Session session) findUsage
(EntityStatus entityStatus, org.hibernate.Session session) findUsage
(NestedEntity nestedEntity, org.hibernate.Session session) Class<? extends ApplicationEntityService<ApplicationEntity>>[]
void
handleSchemaUpdate
(TransferContext context, SchemaVersion schemaVersion) void
importObjects
(TransferContext context, org.hibernate.Session session) query
(IDataSource dataSource, Map<String, Object> parameters, org.hibernate.Session session) void
removeObjects
(Module module, Module currentVersionModule, org.hibernate.Session session) void
saveObject
(IDataSource dataSource) void
setApplicationContext
(org.springframework.context.ApplicationContext applicationContext) Methods inherited from class org.seed.core.application.AbstractApplicationEntityService
analyzeObjects, createChangeLogs, findByUid, findObjectsWithoutModule, findUsage, saveObject
Methods inherited from class org.seed.core.data.AbstractSystemEntityService
existObjects, findByName, findByName, getObject, getObject, getObjects, getObjects, initObject, isEntityType, reloadObject
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.seed.core.application.ApplicationEntityService
analyzeObjects, createChangeLogs, findByUid, findObjectsWithoutModule, saveObject
Methods inherited from interface org.seed.core.data.SystemEntityService
existObjects, findByName, findByName, getObject, getObject, getObjects, getObjects, initObject, isEntityType, reloadObject
-
Constructor Details
-
DataSourceServiceImpl
public DataSourceServiceImpl()
-
-
Method Details
-
createInstance
- Specified by:
createInstance
in interfaceSystemEntityService<IDataSource>
- Overrides:
createInstance
in classAbstractSystemEntityService<IDataSource>
-
createParameter
@Secured("ROLE_ADMIN_DATASOURCE") public DataSourceParameter createParameter(IDataSource dataSource) - Specified by:
createParameter
in interfaceDataSourceService
-
findUsage
- Specified by:
findUsage
in interfaceEntityDependent<IDataSource>
-
findUsage
public List<IDataSource> findUsage(Entity entity, EntityField entityField, org.hibernate.Session session) - Specified by:
findUsage
in interfaceEntityDependent<IDataSource>
-
findUsage
- Specified by:
findUsage
in interfaceEntityDependent<IDataSource>
-
findUsage
- Specified by:
findUsage
in interfaceEntityDependent<IDataSource>
-
findUsage
- Specified by:
findUsage
in interfaceEntityDependent<IDataSource>
-
findUsage
- Specified by:
findUsage
in interfaceEntityDependent<IDataSource>
-
findUsage
public List<IDataSource> findUsage(Entity entity, EntityRelation entityRelation, org.hibernate.Session session) - Specified by:
findUsage
in interfaceEntityDependent<IDataSource>
-
query
public DataSourceResult query(IDataSource dataSource, Map<String, Object> parameters, org.hibernate.Session session) throws ValidationException- Specified by:
query
in interfaceDataSourceService
- Throws:
ValidationException
-
getImportDependencies
- Specified by:
getImportDependencies
in interfaceApplicationEntityService<IDataSource>
-
handleSchemaUpdate
- Specified by:
handleSchemaUpdate
in interfaceApplicationEntityService<IDataSource>
- Overrides:
handleSchemaUpdate
in classAbstractApplicationEntityService<IDataSource>
-
importObjects
public void importObjects(TransferContext context, org.hibernate.Session session) throws ValidationException - Specified by:
importObjects
in interfaceApplicationEntityService<IDataSource>
- Throws:
ValidationException
-
removeObjects
public void removeObjects(Module module, Module currentVersionModule, org.hibernate.Session session) - Specified by:
removeObjects
in interfaceApplicationEntityService<IDataSource>
-
saveObject
@Secured("ROLE_ADMIN_DATASOURCE") public void saveObject(IDataSource dataSource) throws ValidationException - Specified by:
saveObject
in interfaceSystemEntityService<IDataSource>
- Overrides:
saveObject
in classAbstractSystemEntityService<IDataSource>
- Throws:
ValidationException
-
deleteObject
@Secured("ROLE_ADMIN_DATASOURCE") public void deleteObject(IDataSource dataSource) throws ValidationException - Specified by:
deleteObject
in interfaceSystemEntityService<IDataSource>
- Overrides:
deleteObject
in classAbstractSystemEntityService<IDataSource>
- Throws:
ValidationException
-
setApplicationContext
public void setApplicationContext(org.springframework.context.ApplicationContext applicationContext) - Specified by:
setApplicationContext
in interfaceorg.springframework.context.ApplicationContextAware
-