Re: [OJB-developers] Refresh/update an object
Brought to you by:
thma
From: Thomas M. <tho...@ho...> - 2002-05-26 08:46:57
|
Hi Travis, Say you have a persistent object instance. To perform a refreh of this object use PersistenceBroker broker = PersistenceBroker.createPersistenceBroker(); Identity oid = new Identity(instance); broker.invalidate(oid); instance = broker.getObjectByIdentity(oid) HTH, Thomas tr...@th... wrote: > Is there any method in place for doing this? Just wondering for jdo, below is what should happen. > > /** Refresh the state of the instance from the data store. > * > * <P>In an optimistic transaction, the state of instances in the cache > * might not match the state in the data store. This method is used to > * reload the state of the instance from the data store so that a subsequent > * commit is more likely to succeed. > * <P>Outside a transaction, this method will refresh nontransactional state. > * @param pc the instance to refresh. > */ > > > Travis > > _______________________________________________________________ > > Don't miss the 2002 Sprint PCS Application Developer's Conference > August 25-28 in Las Vegas -- http://devcon.sprintpcs.com/adp/index.cfm > > _______________________________________________ > Objectbridge-developers mailing list > Obj...@li... > https://lists.sourceforge.net/lists/listinfo/objectbridge-developers > > > > |