Package org.apache.isis.core.metamodel.adapter.oid

Examples of org.apache.isis.core.metamodel.adapter.oid.AggregatedOid


        final Oid oid = adapter.getOid();
        if (oid instanceof AggregatedOid) {
            if (LOG.isDebugEnabled()) {
                LOG.debug("; aggregated - resolving parent");
            }
            final AggregatedOid aggregatedOid = (AggregatedOid) oid;
            final TypedOid parentOid = aggregatedOid.getParentOid();
            final ObjectAdapter parentAdapter = loadInstanceAndAdapt(parentOid);
            resolveImmediately(parentAdapter);
            return;
        }
View Full Code Here


       
        final ObjectSpecification objSpec = getSpecificationLoader().loadSpecification(pojo.getClass());
       
        final ObjectAdapter newAdapter;
        if(isAggregated(objSpec)) {
            final AggregatedOid aggregatedOid = getOidGenerator().createAggregateOid(pojo, parentAdapter);
            newAdapter = createAggregatedAdapter(pojo, aggregatedOid);
        } else {
            newAdapter = createTransientOrViewModelRootAdapter(pojo);
        }
       
View Full Code Here

            createdAdapter = createRootAdapterAndInferResolveState(pojo, rootOid);
        } else if (oid instanceof CollectionOid){
            final CollectionOid collectionOid = (CollectionOid) oid;
            createdAdapter = createCollectionAdapterAndInferResolveState(pojo, collectionOid);
        } else {
            final AggregatedOid aggregatedOid = (AggregatedOid) oid;
            createdAdapter = createAggregatedAdapter(pojo, aggregatedOid);
        }
        return createdAdapter;
    }
View Full Code Here

    private void remapAggregatedObject(final ObjectAdapter adapter, final RootOid persistedRootOid) {
        final Oid oid = adapter.getOid();
        if (!(oid instanceof AggregatedOid) || !oid.isTransient()) {
                return;
        }
        AggregatedOid aoid = (AggregatedOid) oid;
        AggregatedOid childOid = new AggregatedOid(aoid.getObjectSpecId(), persistedRootOid, aoid.getLocalId());
        adapter.replaceOid(childOid);
       
        remapContainedAggregatedObject(adapter, persistedRootOid);
    }
View Full Code Here

        final Oid oid = adapter.getOid();
        if (oid instanceof AggregatedOid) {
            if (LOG.isDebugEnabled()) {
                LOG.debug("; aggregated - resolving parent");
            }
            final AggregatedOid aggregatedOid = (AggregatedOid) oid;
            final TypedOid parentOid = aggregatedOid.getParentOid();
            final ObjectAdapter parentAdapter = loadInstanceAndAdapt(parentOid);
            resolveImmediately(parentAdapter);
            return;
        }
View Full Code Here

TOP

Related Classes of org.apache.isis.core.metamodel.adapter.oid.AggregatedOid

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.