260 VisualAge for Java Version 3: Persistence Builder with GUIs, Servlets, and JSPs
Transaction Binding Policies
In order to enable other flavors of transaction-to-thread binding, the current
transaction mechanism was redesigned in VisualAge for Java Version 3.0 to
delegate the get- and set-current behavior through a transaction binding
policy. Transaction binding policies have to implement three methods:
❑ public Transaction getCurrentTransaction(), which returns the
transaction bound to the current thread
❑ public void setCurrentTransaction(Transaction aTransaction), which
binds a transaction to the current thread
❑ public void terminateTransaction(Transaction aTransaction), which
disconnects a terminated transaction from a thread
If the transac ...