|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectit.dtt.ca.request.CARequest
it.dtt.ca.request.RcRechargeRequest
public class RcRechargeRequest
This class is used to manage a recharge via return channel; the user (application) will enter the scratch card number or the credit card data and wait till connection and recharge process to be fulfilled. The connection parameters could be set by application or also set by defaults (or set top box menu).
Field Summary | |
---|---|
static int |
CREDIT_CARD_MODE
Using a credit card for the transaction In this case the transaction data array contains these fields: - String : surname of user - String : name of user - String : credit card number - GregorianCalendar : start date of credit card - GregorianCalendar : expiry date of credit card - double : recharge value requested |
static int |
IP_ADDRESS
IP address for TCP/UDP connection. |
static int |
PASSWORD
User password for login if needed. |
static int |
PHONE_NUMBER
Phone number of the server to call. |
static int |
PORT_NUMBER
Port number for TCP/IP connection. |
static int |
SCRATCH_CARD_MODE
Using a scratch card for the transaction. |
static int |
USER
User name for login if needed. |
Constructor Summary | |
---|---|
RcRechargeRequest()
Basic constructor with no parameters definition. |
|
RcRechargeRequest(java.lang.String phone,
java.lang.String user,
java.lang.String password,
java.lang.String ip_address,
java.lang.String port)
Constructor with parameters' setting capabilities |
Method Summary | |
---|---|
java.lang.String |
getRcParameter(int what)
Used to retrieve a parameter of the connection. |
int |
getRechargeMode()
Returns the mode to be used for transaction. |
java.lang.String[] |
getTransactionData()
Retrieves data set to be used for the transaction |
void |
setRechargeMode(int mode)
This sets method to be used to recharge the card (scratch card, credit card, ...) |
Methods inherited from class it.dtt.ca.request.CARequest |
---|
cancel, getPrivateData, isCancelled, setPrivateData |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final int IP_ADDRESS
getRcParameter(int)
,
Constant Field Valuespublic static final int PASSWORD
getRcParameter(int)
,
Constant Field Valuespublic static final int PHONE_NUMBER
getRcParameter(int)
,
Constant Field Valuespublic static final int PORT_NUMBER
getRcParameter(int)
,
Constant Field Valuespublic static final int USER
getRcParameter(int)
,
Constant Field Valuespublic static final int SCRATCH_CARD_MODE
setRechargeMode(int)
,
Constant Field Valuespublic static final int CREDIT_CARD_MODE
setRechargeMode(int)
,
Constant Field ValuesConstructor Detail |
---|
public RcRechargeRequest()
getRcParameter(int)
public RcRechargeRequest(java.lang.String phone, java.lang.String user, java.lang.String password, java.lang.String ip_address, java.lang.String port) throws InvalidRcParametersException
phone
- phone number to be calleduser
- name of the user for loginpassword
- password used by given user for loginip_address
- address of the serverport
- port number of the server
InvalidRcParametersException
Method Detail |
---|
public java.lang.String getRcParameter(int what) throws InvalidRcParametersException
what
- the parameter that should be retrieved
InvalidRcParametersException
- it.dtt.ca.exception.InvalidRcParametersException
if there are errors in parameters definition or if the types are not required onespublic java.lang.String[] getTransactionData()
public void setRechargeMode(int mode)
mode
- the mode to use for this transaction
java.lang.IllegalArgumentException
- if the recharge
mode is not a supported modeand #CREDIT_CARD_MODE
public int getRechargeMode()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |