Class PrivilegedCollectionInitializer

java.lang.Object
ch.tocco.nice2.persist.core.api.hibernate.interceptor.AbstractCollectionInitializer
ch.tocco.nice2.persist.security.impl.hibernate.interceptor.PrivilegedCollectionInitializer
All Implemented Interfaces:
CollectionInitializer

@Component public class PrivilegedCollectionInitializer extends AbstractCollectionInitializer
CollectionInitializer that optimizes the query for the contributed entities (e.g. Email_archive).

Entities are loaded privileged and are then checked using a ListGuard. Even though this executes more queries it is a lot faster, because the single query would create many large joins due to the ACL rules for the contributed entities.