Package com.google.appengine.datanucleus.test.jdo.HasPolymorphicRelationsListJDO

Examples of com.google.appengine.datanucleus.test.jdo.HasPolymorphicRelationsListJDO.HasOneToManyList


    getExecutionContext().setProperty(PROP_DETACH_ON_CLOSE, true);
    testOnlyOneParentPutOnChildDelete(NEW_PM_START_END);
  }
  private void testOnlyOneParentPutOnChildDelete(StartEnd startEnd) throws Throwable {
    testOnlyOneParentPutOnChildDelete(
        new HasOneToManyList(), new BidirTop(), startEnd);
    testOnlyOneParentPutOnChildDelete(
        new HasOneToManyList(), new BidirBottom(), startEnd);
    testOnlyOneParentPutOnChildDelete(
        new HasOneToManyList(), new BidirMiddle(), startEnd);
  }
View Full Code Here


    testOnlyOneParentPutOnChildDelete(
        new HasOneToManyList(), new BidirMiddle(), startEnd);
  }

  public void testNonTxnAddOfChildToParentFailsPartwayThrough() throws Throwable {
    testNonTxnAddOfChildToParentFailsPartwayThrough(new HasOneToManyList());
  }
View Full Code Here

    BidirTop bidirChild1 = new BidirTop();
    BidirTop bidirChild2 = new BidirTop();
    UnidirTop unidir1 = new UnidirTop();
    UnidirTop unidir2 = new UnidirTop();

    HasOneToManyList parent = new HasOneToManyList();
    parent.addBidirChild(bidirChild1);
    bidirChild1.setParent(parent);
    parent.addBidirChild(bidirChild2);
    bidirChild2.setParent(parent);
    parent.addUnidirChild(unidir1);
    parent.addUnidirChild(unidir2);

    startEnd.start();
    pm.makePersistent(parent);
    startEnd.end();

    startEnd.start();
    parent = pm.getObjectById(parent.getClass(), parent.getId());
    parent.getUnidirChildren().remove(0);
    parent.getUnidirChildren().remove(0);
    startEnd.end();

    startEnd.start();
    parent = pm.getObjectById(parent.getClass(), parent.getId());
    assertTrue(parent.getUnidirChildren().isEmpty());
    startEnd.end();
  }
View Full Code Here

TOP

Related Classes of com.google.appengine.datanucleus.test.jdo.HasPolymorphicRelationsListJDO.HasOneToManyList

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.