Package com.buschmais.cdo.impl.instancelistener

Examples of com.buschmais.cdo.impl.instancelistener.InstanceListenerService


        this.sessionContext = sessionContext;
    }

    public void flush() {
        DatastoreSession<?, Entity, ? extends DatastoreEntityMetadata<?>, ?, ?, Relation, ? extends DatastoreRelationMetadata<?>, ?> datastoreSession = sessionContext.getDatastoreSession();
        InstanceListenerService instanceListenerService = sessionContext.getInstanceListenerService();
        for (Object instance : sessionContext.getRelationCache().writtenInstances()) {
            Relation relation = sessionContext.getRelationInstanceManager().getDatastoreType(instance);
            instanceListenerService.preUpdate(instance);
            validateInstance(instance);
            datastoreSession.flushRelation(relation);
            instanceListenerService.postUpdate(instance);
        }
        for (Object instance : sessionContext.getEntityCache().writtenInstances()) {
            Entity entity = sessionContext.getEntityInstanceManager().getDatastoreType(instance);
            instanceListenerService.preUpdate(instance);
            validateInstance(instance);
            datastoreSession.flushEntity(entity);
            instanceListenerService.postUpdate(instance);
        }
    }
View Full Code Here


        this.entityCache = new TransactionalCache<>();
        this.relationCache = new TransactionalCache<>();
        this.cdoTransaction = new CdoTransactionImpl(datastoreSession.getDatastoreTransaction());
        this.interceptorFactory = new InterceptorFactory(cdoTransaction, defaultTransactionAttribute, concurrencyMode);
        this.proxyFactory = new ProxyFactory(interceptorFactory, classLoader);
        this.instanceListenerService = new InstanceListenerService(instanceListenerTypes);
        this.entityPropertyManager = new EntityPropertyManager<>(this);
        this.relationPropertyManager = new RelationPropertyManager<>(this);
        this.relationInstanceManager = new RelationInstanceManager<>(this);
        this.entityInstanceManager = new EntityInstanceManager<>(this);
        this.instanceValidationService = new InstanceValidationService(validatorFactory, relationCache, entityCache);
View Full Code Here

TOP

Related Classes of com.buschmais.cdo.impl.instancelistener.InstanceListenerService

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.