Package org.apache.ojb.broker

Examples of org.apache.ojb.broker.PersistenceBroker.commitTransaction()


        PersistenceBroker broker = PersistenceBrokerFactory.defaultPersistenceBroker();
        try
        {
            broker.beginTransaction();
            broker.store(obj);
            broker.commitTransaction();

            Identity oid = new Identity(obj, broker);
            obj = (TestObjectDefaultCache) broker.serviceObjectCache().lookup(oid);
            assertNotNull(obj);
View Full Code Here


        PersistenceBroker broker = PersistenceBrokerFactory.defaultPersistenceBroker();
        try
        {
            broker.beginTransaction();
            broker.store(obj);
            broker.commitTransaction();

            Identity oid = new Identity(obj, broker);
            obj = (TestObjectDefaultCache) broker.serviceObjectCache().lookup(oid);
            assertNotNull(obj);
            assertEquals(name, obj.getName());
View Full Code Here

        try
        {
            broker.beginTransaction();
            broker.store(obj);
            broker.store(dummy);
            broker.commitTransaction();

            Identity obj_oid = new Identity(obj, broker);
            Identity dummy_oid = new Identity(dummy, broker);
            ObjectCache cache = broker.serviceObjectCache();
            Object ret_obj = cache.lookup(obj_oid);
View Full Code Here


        broker1.commitTransaction();
        broker1.close();

        broker2.commitTransaction();
        broker2.close();
    }


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.