Class PBCapsule

  extended by org.apache.ojb.odmg.PBCapsule

public final class PBCapsule
extends java.lang.Object

ONLY VALID FOR READ OPERATIONS! Capsulates the way to obtain PersistenceBroker instances when a odmg-tx is running or not - Do not forget to call the destroy() method after use. When a transaction was found we use the PersistenceBroker instance shipped with the Transaction (via HasBroker), else we try to obtain a broker using the given PBKey directly from the PersistenceBrokerFactory.

$Id: 365262 2005-12-31 18:29:11Z arminw $

Constructor Summary
PBCapsule(PBKey pbKey, Transaction tx)
Method Summary
 void destroy()
 PersistenceBroker getBroker()
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail


public PBCapsule(PBKey pbKey,
                 Transaction tx)
Method Detail


public PersistenceBroker getBroker()


public void destroy()

(C) 2002 - 2006 Apache Software Foundation
All rights reserved. Published under the Apache License 2.0.
Version: 1.0.4, 2005-12-30