Class EntityPartServiceImpl<P extends de.digitalcollections.model.api.identifiable.entity.parts.EntityPart,E extends de.digitalcollections.model.api.identifiable.entity.Entity>
- java.lang.Object
-
- de.digitalcollections.cudami.server.business.impl.service.identifiable.IdentifiableServiceImpl<P>
-
- de.digitalcollections.cudami.server.business.impl.service.identifiable.entity.parts.EntityPartServiceImpl<P,E>
-
- All Implemented Interfaces:
EntityPartService<P,E>,IdentifiableService<P>
- Direct Known Subclasses:
SubtopicServiceImpl,WebpageServiceImpl
@Service public class EntityPartServiceImpl<P extends de.digitalcollections.model.api.identifiable.entity.parts.EntityPart,E extends de.digitalcollections.model.api.identifiable.entity.Entity> extends IdentifiableServiceImpl<P> implements EntityPartService<P,E>
-
-
Field Summary
-
Fields inherited from class de.digitalcollections.cudami.server.business.impl.service.identifiable.IdentifiableServiceImpl
repository
-
-
Constructor Summary
Constructors Constructor Description EntityPartServiceImpl(EntityPartRepository<P,E> repository)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddRelatedEntity(UUID entityPartUuid, UUID entityUuid)voidaddRelatedEntity(P entityPart, E entity)voidaddRelatedFileresource(UUID entityPartUuid, UUID fileResourceUuid)voidaddRelatedFileresource(P entityPart, de.digitalcollections.model.api.identifiable.resource.FileResource fileResource)protected de.digitalcollections.model.api.filter.FilteringfilteringForActive()List<E>getRelatedEntities(UUID entityPartUuid)List<E>getRelatedEntities(P entityPart)List<de.digitalcollections.model.api.identifiable.resource.FileResource>getRelatedFileResources(UUID entityPartUuid)List<de.digitalcollections.model.api.identifiable.resource.FileResource>getRelatedFileResources(P entityPart)List<E>saveRelatedEntities(UUID entityPartUuid, List<E> entities)List<E>saveRelatedEntities(P entityPart, List<E> entities)Save list of entities related to an entity part.Prerequisite: entities have been saved before (exist already)List<de.digitalcollections.model.api.identifiable.resource.FileResource>saveRelatedFileResources(UUID entityPartUuid, List<de.digitalcollections.model.api.identifiable.resource.FileResource> fileResources)List<de.digitalcollections.model.api.identifiable.resource.FileResource>saveRelatedFileResources(P entityPart, List<de.digitalcollections.model.api.identifiable.resource.FileResource> fileResources)Save list of file resources related to an entity.-
Methods inherited from class de.digitalcollections.cudami.server.business.impl.service.identifiable.IdentifiableServiceImpl
count, find, find, find, get, get, get, getByIdentifier, reduceMultilanguageFieldsToGivenLocale, save, update
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface de.digitalcollections.cudami.server.business.api.service.identifiable.IdentifiableService
cleanupLabelFromUnwantedLocales
-
-
-
-
Constructor Detail
-
EntityPartServiceImpl
@Autowired public EntityPartServiceImpl(@Qualifier("entityPartRepositoryImpl") EntityPartRepository<P,E> repository)
-
-
Method Detail
-
addRelatedEntity
public void addRelatedEntity(P entityPart, E entity)
- Specified by:
addRelatedEntityin interfaceEntityPartService<P extends de.digitalcollections.model.api.identifiable.entity.parts.EntityPart,E extends de.digitalcollections.model.api.identifiable.entity.Entity>
-
addRelatedEntity
public void addRelatedEntity(UUID entityPartUuid, UUID entityUuid)
- Specified by:
addRelatedEntityin interfaceEntityPartService<P extends de.digitalcollections.model.api.identifiable.entity.parts.EntityPart,E extends de.digitalcollections.model.api.identifiable.entity.Entity>
-
addRelatedFileresource
public void addRelatedFileresource(P entityPart, de.digitalcollections.model.api.identifiable.resource.FileResource fileResource)
- Specified by:
addRelatedFileresourcein interfaceEntityPartService<P extends de.digitalcollections.model.api.identifiable.entity.parts.EntityPart,E extends de.digitalcollections.model.api.identifiable.entity.Entity>
-
addRelatedFileresource
public void addRelatedFileresource(UUID entityPartUuid, UUID fileResourceUuid)
- Specified by:
addRelatedFileresourcein interfaceEntityPartService<P extends de.digitalcollections.model.api.identifiable.entity.parts.EntityPart,E extends de.digitalcollections.model.api.identifiable.entity.Entity>
-
filteringForActive
protected de.digitalcollections.model.api.filter.Filtering filteringForActive()
-
getRelatedEntities
public List<E> getRelatedEntities(P entityPart)
- Specified by:
getRelatedEntitiesin interfaceEntityPartService<P extends de.digitalcollections.model.api.identifiable.entity.parts.EntityPart,E extends de.digitalcollections.model.api.identifiable.entity.Entity>
-
getRelatedEntities
public List<E> getRelatedEntities(UUID entityPartUuid)
- Specified by:
getRelatedEntitiesin interfaceEntityPartService<P extends de.digitalcollections.model.api.identifiable.entity.parts.EntityPart,E extends de.digitalcollections.model.api.identifiable.entity.Entity>
-
getRelatedFileResources
public List<de.digitalcollections.model.api.identifiable.resource.FileResource> getRelatedFileResources(P entityPart)
- Specified by:
getRelatedFileResourcesin interfaceEntityPartService<P extends de.digitalcollections.model.api.identifiable.entity.parts.EntityPart,E extends de.digitalcollections.model.api.identifiable.entity.Entity>
-
getRelatedFileResources
public List<de.digitalcollections.model.api.identifiable.resource.FileResource> getRelatedFileResources(UUID entityPartUuid)
- Specified by:
getRelatedFileResourcesin interfaceEntityPartService<P extends de.digitalcollections.model.api.identifiable.entity.parts.EntityPart,E extends de.digitalcollections.model.api.identifiable.entity.Entity>
-
saveRelatedEntities
public List<E> saveRelatedEntities(P entityPart, List<E> entities)
Description copied from interface:EntityPartServiceSave list of entities related to an entity part.Prerequisite: entities have been saved before (exist already)- Specified by:
saveRelatedEntitiesin interfaceEntityPartService<P extends de.digitalcollections.model.api.identifiable.entity.parts.EntityPart,E extends de.digitalcollections.model.api.identifiable.entity.Entity>- Parameters:
entityPart- entity part the entities are related toentities- the entities that are related to the entity part- Returns:
- the list of the related entities
-
saveRelatedEntities
public List<E> saveRelatedEntities(UUID entityPartUuid, List<E> entities)
- Specified by:
saveRelatedEntitiesin interfaceEntityPartService<P extends de.digitalcollections.model.api.identifiable.entity.parts.EntityPart,E extends de.digitalcollections.model.api.identifiable.entity.Entity>
-
saveRelatedFileResources
public List<de.digitalcollections.model.api.identifiable.resource.FileResource> saveRelatedFileResources(P entityPart, List<de.digitalcollections.model.api.identifiable.resource.FileResource> fileResources)
Description copied from interface:EntityPartServiceSave list of file resources related to an entity. Prerequisite: file resources have been saved before (exist already)- Specified by:
saveRelatedFileResourcesin interfaceEntityPartService<P extends de.digitalcollections.model.api.identifiable.entity.parts.EntityPart,E extends de.digitalcollections.model.api.identifiable.entity.Entity>- Parameters:
entityPart- entity part the file resources are related tofileResources- the file resources that are related to the entity part- Returns:
- the list of the related file resources
-
saveRelatedFileResources
public List<de.digitalcollections.model.api.identifiable.resource.FileResource> saveRelatedFileResources(UUID entityPartUuid, List<de.digitalcollections.model.api.identifiable.resource.FileResource> fileResources)
- Specified by:
saveRelatedFileResourcesin interfaceEntityPartService<P extends de.digitalcollections.model.api.identifiable.entity.parts.EntityPart,E extends de.digitalcollections.model.api.identifiable.entity.Entity>
-
-