Examples of HasOneToManyListJDO


Examples of com.google.appengine.datanucleus.test.jdo.HasOneToManyListJDO

    switchDatasource(PersistenceManagerFactoryName.nontransactional);
    getExecutionContext().setProperty(PROP_DETACH_ON_CLOSE, true);
    testSwapAtPosition(NEW_PM_START_END);
  }
  private void testSwapAtPosition(StartEnd startEnd) throws EntityNotFoundException {
    HasOneToManyListJDO parent = new HasOneToManyListJDO();
    BidirectionalChildListJDO bidirChild = new BidirectionalChildListJDO();
    BidirectionalChildListJDO bidirChild2 = new BidirectionalChildListJDO();
    testSwapAtPosition(parent, bidirChild, bidirChild2, startEnd);
  }
View Full Code Here

Examples of com.google.appengine.datanucleus.test.jdo.HasOneToManyListJDO

    switchDatasource(PersistenceManagerFactoryName.nontransactional);
    getExecutionContext().setProperty(PROP_DETACH_ON_CLOSE, true);
    testRemoveAtPosition(NEW_PM_START_END);
  }
  private void testRemoveAtPosition(StartEnd startEnd) throws EntityNotFoundException {
    HasOneToManyListJDO parent = new HasOneToManyListJDO();
    BidirectionalChildListJDO bidirChild = new BidirectionalChildListJDO();
    BidirectionalChildListJDO bidirChild2 = new BidirectionalChildListJDO();
    BidirectionalChildListJDO bidirChild3 = new BidirectionalChildListJDO();
    testRemoveAtPosition(parent, bidirChild, bidirChild2, bidirChild3, startEnd);
  }
View Full Code Here

Examples of com.google.appengine.datanucleus.test.jdo.HasOneToManyListJDO

    switchDatasource(PersistenceManagerFactoryName.nontransactional);
    getExecutionContext().setProperty(PROP_DETACH_ON_CLOSE, true);
    testAddAtPosition(NEW_PM_START_END);
  }
  private void testAddAtPosition(StartEnd startEnd) throws EntityNotFoundException {
    HasOneToManyListJDO parent = new HasOneToManyListJDO();
    BidirectionalChildListJDO bidirChild = new BidirectionalChildListJDO();
    BidirectionalChildListJDO bidirChild2 = new BidirectionalChildListJDO();
    testAddAtPosition(parent, bidirChild, bidirChild2, startEnd);
  }
View Full Code Here

Examples of com.google.appengine.datanucleus.test.jdo.HasOneToManyListJDO

    switchDatasource(PersistenceManagerFactoryName.nontransactional);
    getExecutionContext().setProperty(PROP_DETACH_ON_CLOSE, true);
    testUpdateUpdateChildWithMerge(NEW_PM_START_END);
  }
  private void testUpdateUpdateChildWithMerge(StartEnd startEnd) throws EntityNotFoundException {
    HasOneToManyListJDO pojo = new HasOneToManyListJDO();
    BidirectionalChildListJDO bidir = new BidirectionalChildListJDO();
    testUpdate_UpdateChildWithMerge(pojo, bidir, startEnd);
  }
View Full Code Here

Examples of com.google.appengine.datanucleus.test.jdo.HasOneToManyListJDO

    switchDatasource(PersistenceManagerFactoryName.nontransactional);
    getExecutionContext().setProperty(PROP_DETACH_ON_CLOSE, true);
    testUpdateUpdateChild(NEW_PM_START_END);
  }
  private void testUpdateUpdateChild(StartEnd startEnd) throws EntityNotFoundException {
    HasOneToManyListJDO pojo = new HasOneToManyListJDO();
    BidirectionalChildListJDO bidir = new BidirectionalChildListJDO();
    testUpdate_UpdateChild(pojo, bidir, startEnd);
  }
View Full Code Here

Examples of com.google.appengine.datanucleus.test.jdo.HasOneToManyListJDO

    switchDatasource(PersistenceManagerFactoryName.nontransactional);
    getExecutionContext().setProperty(PROP_DETACH_ON_CLOSE, true);
    testUpdateNullOutChildren(NEW_PM_START_END);
  }
  private void testUpdateNullOutChildren(StartEnd startEnd) throws EntityNotFoundException {
    HasOneToManyListJDO pojo = new HasOneToManyListJDO();
    BidirectionalChildListJDO bidir = new BidirectionalChildListJDO();
    testUpdate_NullOutChildren(pojo, bidir, startEnd);
  }
View Full Code Here

Examples of com.google.appengine.datanucleus.test.jdo.HasOneToManyListJDO

    switchDatasource(PersistenceManagerFactoryName.nontransactional);
    getExecutionContext().setProperty(PROP_DETACH_ON_CLOSE, true);
    testUpdateClearOutChildren(NEW_PM_START_END);
  }
  private void testUpdateClearOutChildren(StartEnd startEnd) throws EntityNotFoundException {
    HasOneToManyListJDO pojo = new HasOneToManyListJDO();
    BidirectionalChildListJDO bidir = new BidirectionalChildListJDO();
    testUpdate_ClearOutChildren(pojo, bidir, startEnd);
  }
View Full Code Here

Examples of com.google.appengine.datanucleus.test.jdo.HasOneToManyListJDO

    switchDatasource(PersistenceManagerFactoryName.nontransactional);
    getExecutionContext().setProperty(PROP_DETACH_ON_CLOSE, true);
    testIndexOf(NEW_PM_START_END);
  }
  public void testIndexOf(StartEnd startEnd) throws Exception {
    HasOneToManyListJDO pojo = new HasOneToManyListJDO();
    BidirectionalChildListJDO bidir1 = new BidirectionalChildListJDO();
    BidirectionalChildListJDO bidir2 = new BidirectionalChildListJDO();

    Flight f1 = newFlight();
    Flight f2 = newFlight();

    HasKeyPkJDO hasKeyPk1 = new HasKeyPkJDO();
    HasKeyPkJDO hasKeyPk2 = new HasKeyPkJDO();

    pojo.addBidirChild(bidir1);
    pojo.addBidirChild(bidir2);
    pojo.addFlight(f1);
    pojo.addFlight(f2);
    pojo.addHasKeyPk(hasKeyPk1);
    pojo.addHasKeyPk(hasKeyPk2);

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

    startEnd.start();
    pojo = pm.getObjectById(HasOneToManyListJDO.class, pojo.getId());
    bidir1 = pm.getObjectById(bidir1.getClass(), bidir1.getId());
    bidir2 = pm.getObjectById(bidir2.getClass(), bidir2.getId());
    f1 = pm.getObjectById(f1.getClass(), f1.getId());
    f2 = pm.getObjectById(f2.getClass(), f2.getId());
    hasKeyPk1 = pm.getObjectById(hasKeyPk1.getClass(), hasKeyPk1.getKey());
    hasKeyPk2 = pm.getObjectById(hasKeyPk2.getClass(), hasKeyPk2.getKey());
    assertEquals(0, pojo.getBidirChildren().indexOf(bidir1));
    assertEquals(1, pojo.getBidirChildren().indexOf(bidir2));
    assertEquals(0, pojo.getFlights().indexOf(f1));
    assertEquals(1, pojo.getFlights().indexOf(f2));
    assertEquals(0, pojo.getHasKeyPks().indexOf(hasKeyPk1));
    assertEquals(1, pojo.getHasKeyPks().indexOf(hasKeyPk2));
    startEnd.end();
  }
View Full Code Here

Examples of com.google.appengine.datanucleus.test.jdo.HasOneToManyListJDO

    switchDatasource(PersistenceManagerFactoryName.nontransactional);
    getExecutionContext().setProperty(PROP_DETACH_ON_CLOSE, true);
    testRemoveAll(NEW_PM_START_END);
  }
  private void testRemoveAll(StartEnd startEnd) throws EntityNotFoundException {
    testRemoveAll(new HasOneToManyListJDO(), new BidirectionalChildListJDO(),
                  new BidirectionalChildListJDO(), new BidirectionalChildListJDO(), startEnd);
  }
View Full Code Here

Examples of com.google.appengine.datanucleus.test.jdo.HasOneToManyListJDO

    switchDatasource(PersistenceManagerFactoryName.nontransactional);
    getExecutionContext().setProperty(PROP_DETACH_ON_CLOSE, true);
    testChangeParent(NEW_PM_START_END);
  }
  private void testChangeParent(StartEnd startEnd) {
    testChangeParent(new HasOneToManyListJDO(), new HasOneToManyListJDO(), startEnd);
  }
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.