Interface SecurableBaseImmutableService<C extends Securable>
-
- All Superinterfaces:
BaseImmutableService<C>
,BaseReadOnlyService<C>
,SecurableBaseReadOnlyService<C>
- All Known Subinterfaces:
ArrayDesignService
,ExpressionExperimentService
,SecurableBaseService<C>
- All Known Implementing Classes:
ArrayDesignServiceImpl
,ExpressionExperimentServiceImpl
public interface SecurableBaseImmutableService<C extends Securable> extends BaseImmutableService<C>, SecurableBaseReadOnlyService<C>
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description C
create(C entity)
Creates the given entity in the persistent storage.Collection<C>
create(Collection<C> entities)
Creates all the given entities in a persistent storageC
findOrCreate(C entity)
Does a search for the entity in the persistent storage, and if not found, creates it.void
remove(C entity)
Removes the given entity from the persistent storage.void
remove(Long id)
Removes the entity with given ID from the persistent storage.void
remove(Collection<C> entities)
Removes all the given entities from persistent storage.-
Methods inherited from interface ubic.gemma.persistence.service.BaseReadOnlyService
countAll, getElementClass
-
Methods inherited from interface ubic.gemma.persistence.service.common.auditAndSecurity.SecurableBaseReadOnlyService
find, findOrFail, load, load, loadAll, loadOrFail, loadOrFail, loadOrFail, loadOrFail
-
-
-
-
Method Detail
-
findOrCreate
@Secured({"GROUP_USER","AFTER_ACL_READ"}) C findOrCreate(C entity)
Description copied from interface:BaseImmutableService
Does a search for the entity in the persistent storage, and if not found, creates it.- Specified by:
findOrCreate
in interfaceBaseImmutableService<C extends Securable>
- Parameters:
entity
- the entity to look for, and create if not found.- Returns:
- the entity retrieved from the persistent storage, either found or created.
-
create
@Secured("GROUP_USER") Collection<C> create(Collection<C> entities)
Description copied from interface:BaseImmutableService
Creates all the given entities in a persistent storage- Specified by:
create
in interfaceBaseImmutableService<C extends Securable>
- Parameters:
entities
- the entities to be created.- Returns:
- collection of objects referencing the persistent instances of given entities.
-
create
@Secured("GROUP_USER") C create(C entity)
Description copied from interface:BaseImmutableService
Creates the given entity in the persistent storage.- Specified by:
create
in interfaceBaseImmutableService<C extends Securable>
- Parameters:
entity
- the entity to be created.- Returns:
- object referencing the persistent instance of the given entity.
-
remove
@Secured("GROUP_ADMIN") void remove(Long id)
Removes the entity with given ID from the persistent storage.Only administrator are allowed to remove entity by ID.
- Specified by:
remove
in interfaceBaseImmutableService<C extends Securable>
- Parameters:
id
- the ID of entity to be removed.
-
remove
@Secured({"GROUP_USER","ACL_SECURABLE_EDIT"}) void remove(C entity)
Description copied from interface:BaseImmutableService
Removes the given entity from the persistent storage.- Specified by:
remove
in interfaceBaseImmutableService<C extends Securable>
- Parameters:
entity
- the entity to be removed.
-
remove
@Secured({"GROUP_USER","ACL_SECURABLE_COLLECTION_EDIT"}) void remove(Collection<C> entities)
Description copied from interface:BaseImmutableService
Removes all the given entities from persistent storage.- Specified by:
remove
in interfaceBaseImmutableService<C extends Securable>
- Parameters:
entities
- the entities to be removed.
-
-