Examples of writePropertyDirectly()


Examples of org.apache.art.ROArtist.writePropertyDirectly()

                objects.get(0) instanceof Map);
    }

    public void testCommitChangesRO1() throws Exception {
        ROArtist a1 = (ROArtist) context.newObject("ROArtist");
        a1.writePropertyDirectly("artistName", "abc");
        a1.setPersistenceState(PersistenceState.MODIFIED);

        try {
            context.commitChanges();
            fail("Inserting a 'read-only' object must fail.");
View Full Code Here

Examples of org.apache.cayenne.DataObject.writePropertyDirectly()

                    if (relationship.isSourceIndependentFromTargetChange()) {
                        Object fault = relationship.isToMany()
                                ? Fault.getToManyFault()
                                : Fault.getToOneFault();
                        object.writePropertyDirectly(relationship.getName(), fault);
                    }
                }

                delegate.finishedProcessDelete(object);
            }
View Full Code Here

Examples of org.apache.cayenne.property.ArcProperty.writePropertyDirectly()

            target = context.createFault((ObjectId) targetNodeId);
        }

        // (see "TODO" in 'arcCreated')
        ArcProperty p = (ArcProperty) propertyForId(nodeId, arcId.toString());
        p.writePropertyDirectly(source, target, null);

        try {
            context.internalGraphAction().handleArcPropertyChange(
                    (Persistent) source,
                    p,
View Full Code Here

Examples of org.apache.cayenne.property.ArcProperty.writePropertyDirectly()

            Persistent sourceObject,
            Persistent targetObject) {

        ArcProperty reverseArc = property.getComplimentaryReverseArc();
        if (reverseArc != null) {
            reverseArc.writePropertyDirectly(targetObject, sourceObject, null);

            context.getGraphManager().arcDeleted(
                    targetObject.getObjectId(),
                    sourceObject.getObjectId(),
                    reverseArc.getName());
View Full Code Here

Examples of org.apache.cayenne.property.Property.writePropertyDirectly()

        if (object != null && object.getPersistenceState() != PersistenceState.HOLLOW) {

            // do not override local changes....
            Property p = propertyForId(nodeId, property);
            if (Util.nullSafeEquals(p.readPropertyDirectly(object), oldValue)) {
                p.writePropertyDirectly(object, oldValue, newValue);
            }
        }
    }

    public void arcCreated(Object nodeId, Object targetNodeId, Object arcId) {
View Full Code Here

Examples of org.apache.cayenne.property.Property.writePropertyDirectly()

            // do not override local changes....
            Property p = propertyForId(nodeId, property);
            if (Util.nullSafeEquals(p.readPropertyDirectly(object), oldValue)) {

                p.writePropertyDirectly(object, oldValue, newValue);
                context.internalGraphAction().handleSimplePropertyChange(
                        (Persistent) object,
                        property,
                        oldValue,
                        newValue);
View Full Code Here

Examples of org.apache.cayenne.property.Property.writePropertyDirectly()

                    .getClassDescriptor(reverse.getSourceEntity().getName())
                    .getProperty(reverse.getName());

            Iterator it = resolved.iterator();
            while (it.hasNext()) {
                property.writePropertyDirectly(it.next(), null, relationshipOwner);
            }
        }

        return resolved;
    }
View Full Code Here

Examples of org.apache.cayenne.property.Property.writePropertyDirectly()

        if (object != null && object.getPersistenceState() != PersistenceState.HOLLOW) {

            // do not override local changes....
            Property p = propertyForId(nodeId, property);
            if (Util.nullSafeEquals(p.readPropertyDirectly(object), oldValue)) {
                p.writePropertyDirectly(object, oldValue, newValue);
            }
        }
    }

    public void arcCreated(Object nodeId, Object targetNodeId, Object arcId) {
View Full Code Here

Examples of org.apache.cayenne.reflect.ArcProperty.writePropertyDirectly()

            Persistent sourceObject,
            Persistent targetObject) {

        ArcProperty reverseArc = property.getComplimentaryReverseArc();
        if (reverseArc != null) {
            reverseArc.writePropertyDirectly(targetObject, sourceObject, null);

            context.getGraphManager().arcDeleted(
                    targetObject.getObjectId(),
                    sourceObject.getObjectId(),
                    reverseArc.getName());
View Full Code Here

Examples of org.apache.cayenne.reflect.ArcProperty.writePropertyDirectly()

        try {
            if (p instanceof ToManyProperty) {
                ((ToManyProperty) p).addTarget(source, target, false);
            }
            else {
                p.writePropertyDirectly(source, null, target);
            }
        }
        finally {
            context.internalGraphAction().setArcChangeInProcess(false);
        }
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.