All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class semper.payment.PaymentTransaction

java.lang.Object
   |
   +----semper.payment.PaymentTransaction

public abstract class PaymentTransaction
extends Object
implements PurseServices, Serializable
Class for the primary objects implementing payment services PaymentTransaction is the primary object in the payment service blocks for carrying out transactions. Each active transaction corresponds to a PaymentTransaction object. The payment manager has a list of all active transactions. The constructor of each PaymentTransaction object is responsible for notifying the payment manager of its creation. Each PaymentTransaction object creates a PaymentTransactionRecord object. At the end of the transaction or at the end of a session (even if the transaction is unfinished), the PaymentTransaction object is removed while the PaymentTransactionRecord is not. They stay in the archive for a longer term. The adapter of a new payment system Xyz will define XyzTransaction as a subclass of this class. So for now, we'll leave it as an abstract class. In case we need transaction records for non-purse transactions (e.g. payment manager transactions) in the payment service block, we'll later make it non-abstract.

Version:
$Revision: 1.12 $ $Date: 1997/10/23 16:21:04 $
Author:
N. Asokan (aso@zurich.ibm.com)
See Also:
PaymentManager, PaymentTransactionRecord

Constructor Index

 o PaymentTransaction()

Method Index

 o abort()
Abort the current transaction, if possible.
 o endTransaction()
Mark a transaction as 'completed'.
 o finalize()
 o getState()
Return the state of the Transaction.
 o getTransactionRecord()
Return a reference to the PaymentTransactionRecord associated with this Transaction.
 o pay(PaymentEntity, Amount, Vector, String)
Move specified amount from payer to payee.
 o pay(PaymentEntity, Amount, Vector, String[])
Depracated (will be removed shortly)
 o receivePayment(PaymentEntity, Amount, Vector, String)
Accept incoming payment from a payer.
 o receivePayment(PaymentEntity, Amount, Vector, String[])
Depracated (will be removed shortly)
 o reversePayment(PaymentTransactionRecord)
Request reversal of a previously made payment.
 o reverseReceivedPayment(PaymentTransactionRecord)
Process request for reversing a previously received payment.
 o suspendTransaction()
Suspend a transaction.

Constructors

 o PaymentTransaction
 public PaymentTransaction()

Methods

 o abort
 public abstract void abort() throws CouldNotAbort
Abort the current transaction, if possible.

Throws: CouldNotAbort
if abortion is no longer possible
 o getState
 public abstract PaymentTransactionState getState()
Return the state of the Transaction.

 o getTransactionRecord
 public abstract PaymentTransactionRecord getTransactionRecord()
Return a reference to the PaymentTransactionRecord associated with this Transaction.

Returns:
PaymentTransactionRecord object corresponding to this transaction
See Also:
PaymentTransactionRecord
 o suspendTransaction
 public PaymentTransactionRecord suspendTransaction() throws PaymentServiceException
Suspend a transaction.

Returns:
payment transaction record for this transaction
Throws: PaymentServiceException
if suspension failed
See Also:
resumeTransaction, startTransaction
 o endTransaction
 public PaymentTransactionRecord endTransaction() throws PaymentServiceException
Mark a transaction as 'completed'.

Returns:
a reference to the payment transaction record of this transaction.
Throws: PaymentServiceException
if it was not possible to mark this transaction as ended.
See Also:
endTransaction
 o finalize
 protected void finalize() throws IOException
Overrides:
finalize in class Object
 o pay
 public void pay(PaymentEntity payee,
                 Amount amount,
                 Vector options,
                 String a_ext_ref[]) throws PaymentServiceException
Depracated (will be removed shortly)

Throws: PaymentServiceException
as in above
See Also:
pay
 o receivePayment
 public void receivePayment(PaymentEntity payer,
                            Amount amount,
                            Vector options,
                            String a_ext_ref[]) throws PaymentServiceException
Depracated (will be removed shortly)

Throws: PaymentServiceException
as in above
See Also:
receivePayment

All Packages  Class Hierarchy  This Package  Previous  Next  Index