All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class semper.payment.mandate.mandateModule

java.lang.Object
   |
   +----semper.payment.mandate.mandateModule

public class mandateModule
extends Object
Mandate Payment Module. This module is the implementation of a e-cheque payment system. It is an "account-based" system. There are two types of entities in the system: the payer, and the payee. So far there are only one type of transactions: The protocol is of the request/response type. All protocol messages have the same structure (of class mandateModuleMessage)

Version:
$Revision: 1.11 $ $Date: 1998/10/06 15:09:35 $
Author:
K. Lüders-Jensen (klj@cryptomathic.dk), Bjarke Dahl Ebert (bde@cryptomathic.dk)

Constructor Index

 o mandateModule()

Method Index

 o get_bank_id(String, String)
 o get_DCid(String)
 o get_owner(String, String)
 o getAccountNo(String, String)
 o getCertificate(String, String)
 o getCurrency(String, String)
 o getNumberOfCheques(String, String)
 o issue_cheque(String, String, String, int, long, long, byte[], String, String)
 o mandateInit(ComPointAddress)
Initialise/re-initialise the system.
 o mandatePay(mandatePurse, PaymentEntity, Amount, String)
Send a payment.
 o mandateReceivePayment(mandatePurse, Amount, String, PaymentEntity)
Receive a payment from anyone
 o passwd_check(String, String, String, String)
 o receive_cheque(String, String, byte[], String, String)
 o retrieveCheques(String, String)
 o set_passwd(String, String, String, String, String, String)

Constructors

 o mandateModule
 public mandateModule()

Methods

 o getNumberOfCheques
 public static native int getNumberOfCheques(String id,
                                             String DCfile) throws mandateModuleException
 o retrieveCheques
 public static native byte[][] retrieveCheques(String id,
                                               String DCfile) throws mandateModuleException
 o getCurrency
 public static native int getCurrency(String id,
                                      String DCfile) throws mandateModuleException
 o getAccountNo
 public static native String getAccountNo(String id,
                                          String DCfile) throws mandateModuleException
 o getCertificate
 public static native byte[] getCertificate(String id,
                                            String DCfile) throws mandateModuleException
 o set_passwd
 public static native void set_passwd(String id,
                                      String DCfile,
                                      String old_passwd1,
                                      String old_passwd2,
                                      String new_passwd1,
                                      String new_passwd2) throws mandateModuleException
 o passwd_check
 public static native boolean passwd_check(String id,
                                           String DCfile,
                                           String passwd1,
                                           String passwd2) throws mandateModuleException
Returns:
true if passwords are correct
 o receive_cheque
 public static native void receive_cheque(String id,
                                          String DCfile,
                                          byte chequeToken[],
                                          String passwd1,
                                          String passwd2) throws mandateModuleException
 o issue_cheque
 public static native byte[] issue_cheque(String id,
                                          String DCfile,
                                          String payee,
                                          int amount,
                                          long valstart,
                                          long valend,
                                          byte certificate[],
                                          String passwd1,
                                          String passwd2) throws mandateModuleException
Returns:
byte[] containing bytes from cheque
 o get_DCid
 public static native String get_DCid(String DCfile) throws mandateModuleException
 o get_owner
 public static native String get_owner(String id,
                                       String DCfile) throws mandateModuleException
 o get_bank_id
 public static native String get_bank_id(String id,
                                         String DCfile) throws mandateModuleException
 o mandateInit
 public static ChannelServicePointThread mandateInit(ComPointAddress addr) throws mandateModuleException
Initialise/re-initialise the system. This method registers a port/protocol with the communication manager so that incoming payment messages can be handled.

Parameters:
addr - ComPointAddress object indicating port and protocol
Returns:
a handle to the service point thread created
Throws: mandateModuleException
if the registration fails.
 o mandatePay
 public static mandateEvidence mandatePay(mandatePurse purse,
                                          PaymentEntity payee,
                                          Amount amount,
                                          String ext_ref) throws mandateModuleException
Send a payment. Sends a payment to the specified party.

Parameters:
payer_name - name by which we are to be known to the payee (this need not be the same name that the bank knows us by)
payer_AC_number - our account number in the bank
payee_name - name of the payee
payee - address of the payee
amount - value of payment
purse - Purse refering to the DC that will issue the cheque
ext_ref - external reference string to be passed on to the other side
Returns:
mandateEvidence object containing results and status
Throws: mandateModuleException
on all sorts of errors
See Also:
mandateReceivePayment
 o mandateReceivePayment
 public static mandateEvidence mandateReceivePayment(mandatePurse purse,
                                                     Amount amount,
                                                     String ext_ref,
                                                     PaymentEntity payer) throws mandateModuleException
Receive a payment from anyone

Parameters:
purse - The purse that will receive the payment
a_amount - value of payment (return value)
ext_ref - external reference string passed on from the other side
Returns:
mandateEvidence object containing results and status
Throws: mandateModuleException
on all sorts of errors
See Also:
mandatePay

All Packages  Class Hierarchy  This Package  Previous  Next  Index