Class EntityDocsRootFolderCollectionInitializer
java.lang.Object
ch.tocco.nice2.persist.core.api.hibernate.interceptor.AbstractCollectionInitializer
ch.tocco.nice2.dms.impl.entitydocs.interceptor.EntityDocsRootFolderCollectionInitializer
- All Implemented Interfaces:
CollectionInitializer
@Component
public class EntityDocsRootFolderCollectionInitializer
extends AbstractCollectionInitializer
-
Field Summary
Fields inherited from class ch.tocco.nice2.persist.core.api.hibernate.interceptor.AbstractCollectionInitializer
dataModel, persistService
-
Constructor Summary
ConstructorDescriptionEntityDocsRootFolderCollectionInitializer
(PersistenceService persistService, DataModel dataModel, TypeManager typeManager, SecurityManager securityManager) -
Method Summary
Modifier and TypeMethodDescriptionlong
countCollectionElements
(jakarta.persistence.metamodel.EntityType<?> entityType, jakarta.persistence.metamodel.Attribute<?, ?> collection, Serializable id) List
<?> getCollectionElements
(jakarta.persistence.metamodel.EntityType<?> entityType, jakarta.persistence.metamodel.Attribute<?, ?> collection, Serializable id, Pagination pagination, @Nullable Ordering ordering) priority()
boolean
Methods inherited from class ch.tocco.nice2.persist.core.api.hibernate.interceptor.AbstractCollectionInitializer
createQueryBuilder, doCountCollectionElements, doGetCollectionElements, modifyDefaultQuery
-
Constructor Details
-
EntityDocsRootFolderCollectionInitializer
public EntityDocsRootFolderCollectionInitializer(PersistenceService persistService, DataModel dataModel, TypeManager typeManager, SecurityManager securityManager)
-
-
Method Details
-
getCollectionElements
public List<?> getCollectionElements(jakarta.persistence.metamodel.EntityType<?> entityType, jakarta.persistence.metamodel.Attribute<?, ?> collection, Serializable id, Pagination pagination, @Nullable @Nullable Ordering ordering) - Specified by:
getCollectionElements
in interfaceCollectionInitializer
- Overrides:
getCollectionElements
in classAbstractCollectionInitializer
- Returns:
- the collection elements of a specific relation
-
countCollectionElements
public long countCollectionElements(jakarta.persistence.metamodel.EntityType<?> entityType, jakarta.persistence.metamodel.Attribute<?, ?> collection, Serializable id) - Specified by:
countCollectionElements
in interfaceCollectionInitializer
- Overrides:
countCollectionElements
in classAbstractCollectionInitializer
- Returns:
- the number of persisted collection elements
-
supports
public boolean supports(Object collectionOwner, jakarta.persistence.metamodel.Attribute<?, ?> collection) - Returns:
- true if this
CollectionInitializer
supports resolving this relation
-
priority
- Returns:
- the priority in case multiple
CollectionInitializer
can resolve a relation
-