Package org.apache.openjpa.enhance

Examples of org.apache.openjpa.enhance.PersistenceCapable.pcGetDetachedState()


                ImplHelper.getManagedInstance(toAttach).getClass(),
                broker.getClassLoader(), true);

        switch (meta.getIdentityType()) {
            case ClassMetaData.ID_DATASTORE:
                Object[] state = (Object[]) pc.pcGetDetachedState();
                if (state == null)
                    return null;
                return broker
                    .newObjectId(toAttach.getClass(), state[0]);
            case ClassMetaData.ID_APPLICATION:
View Full Code Here


        ValueMetaData ownerMeta, boolean explicit) {
        BrokerImpl broker = manager.getBroker();
        PersistenceCapable pc = ImplHelper.toPersistenceCapable(toAttach,
            manager.getBroker().getConfiguration());

        Object[] state = (Object[]) pc.pcGetDetachedState();
        boolean embedded = ownerMeta != null && ownerMeta.isEmbeddedPC();
        int offset;
        StateManagerImpl sm;

        // state == null means this is a new instance; also, if the
View Full Code Here

        PersistenceCapable pc = ImplHelper.toPersistenceCapable(toAttach,
            getBroker().getConfiguration());
        if (pc.pcGetStateManager() instanceof AttachStrategy)
            return (AttachStrategy) pc.pcGetStateManager();

        Object obj = pc.pcGetDetachedState();
        if (obj instanceof AttachStrategy)
            return (AttachStrategy) obj;
        if (obj == null || obj == PersistenceCapable.DESERIALIZED) {
            // new or detached without state
            if (_version == null)
View Full Code Here

        PersistenceCapable pc = ImplHelper.toPersistenceCapable(toAttach,
            getBroker().getConfiguration());
        if (pc.pcGetStateManager() instanceof AttachStrategy)
            return (AttachStrategy) pc.pcGetStateManager();

        Object obj = pc.pcGetDetachedState();
        if (obj instanceof AttachStrategy)
            return (AttachStrategy) obj;
        if (obj == null || obj == PersistenceCapable.DESERIALIZED) {
            // new or detached without state
            if (_version == null)
View Full Code Here

        PersistenceCapable pc = ImplHelper.toPersistenceCapable(toAttach,
            getBroker().getConfiguration());
        if (pc.pcGetStateManager() instanceof AttachStrategy)
            return (AttachStrategy) pc.pcGetStateManager();

        Object obj = pc.pcGetDetachedState();
        if (obj instanceof AttachStrategy)
            return (AttachStrategy) obj;
        if (obj == null || obj == PersistenceCapable.DESERIALIZED) {
            // new or detached without state
            if (_version == null)
View Full Code Here

        PersistenceCapable pc = ImplHelper.toPersistenceCapable(toAttach,
            getBroker().getConfiguration());
        if (pc.pcGetStateManager() instanceof AttachStrategy)
            return (AttachStrategy) pc.pcGetStateManager();

        Object obj = pc.pcGetDetachedState();
        if (obj instanceof AttachStrategy)
            return (AttachStrategy) obj;
        if (obj == null || obj == PersistenceCapable.DESERIALIZED) {
            // new or detached without state
            if (_version == null)
View Full Code Here

        PersistenceCapable pc = ImplHelper.toPersistenceCapable(toAttach,
            getBroker().getConfiguration());
        if (pc.pcGetStateManager() instanceof AttachStrategy)
            return (AttachStrategy) pc.pcGetStateManager();

        Object obj = pc.pcGetDetachedState();
        if (obj instanceof AttachStrategy)
            return (AttachStrategy) obj;
        if (obj == null || obj == PersistenceCapable.DESERIALIZED) {
            // new or detached without state
            if (_version == null)
View Full Code Here

                ImplHelper.getManagedInstance(toAttach).getClass(),
                broker.getClassLoader(), true);

        switch (meta.getIdentityType()) {
            case ClassMetaData.ID_DATASTORE:
                Object[] state = (Object[]) pc.pcGetDetachedState();
                if (state == null)
                    return null;
                return broker
                    .newObjectId(toAttach.getClass(), state[0]);
            case ClassMetaData.ID_APPLICATION:
View Full Code Here

        ValueMetaData ownerMeta, boolean explicit) {
        BrokerImpl broker = manager.getBroker();
        PersistenceCapable pc = ImplHelper.toPersistenceCapable(toAttach,
            manager.getBroker().getConfiguration());

        Object[] state = (Object[]) pc.pcGetDetachedState();
        boolean embedded = ownerMeta != null && ownerMeta.isEmbeddedPC();
        int offset;
        StateManagerImpl sm;

        // state == null means this is a new instance; also, if the
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. 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.