|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.ecebs.rtd.enabler.types.request.ModifyRequest
com.ecebs.rtd.enabler.types.request.DeductSTRRequest
public class DeductSTRRequest
Represents a request to deduct value from an STR on a CM
Nested Class Summary | |
---|---|
static class |
DeductSTRRequest.DeductSTRReason
Used for stating the reason for the STR debit taking place |
Constructor Summary | |
---|---|
DeductSTRRequest()
Create a request with no intialised parameters. |
|
DeductSTRRequest(String cardId,
CardType cardType,
String productName,
int value)
Sets all the required parameters with the provided values. |
Method Summary | |
---|---|
DeductSTRRequest |
addParam(String key,
Object value)
Add a parameter to the request. |
DeductSTRRequest |
setCardId(String cardId)
Set the ID of the card to load the product on to |
DeductSTRRequest |
setCardType(CardType cardType)
Set the type of the card to load the product on to |
DeductSTRRequest |
setProductName(String productName)
Set the name of the product to deduct value from |
DeductSTRRequest |
setReason(DeductSTRRequest.DeductSTRReason reason)
Set the reason for the debit taking place |
DeductSTRRequest |
setValue(int value)
Set the value to be deducted from the STR |
Outcome |
validate()
Validate that the required fields have been set |
Methods inherited from class com.ecebs.rtd.enabler.types.request.ModifyRequest |
---|
getCardId, getCardType, getRequestId, setRequestId |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public DeductSTRRequest()
setCardId(String)
,
setCardType(CardType)
,
setProductName(String)
,
setValue(int)
public DeductSTRRequest(String cardId, CardType cardType, String productName, int value)
cardId
- ID of the card with the product that value should be deducted fromcardType
- The type of the cardproductName
- The name of the productvalue
- Value to be deductedMethod Detail |
---|
public DeductSTRRequest setCardId(String cardId)
cardId
- ID of the card to load the product on to
public DeductSTRRequest setCardType(CardType cardType)
cardType
- Type of the card to load the product on to
public DeductSTRRequest setProductName(String productName)
productName
- Name of the product to deduct value from
public DeductSTRRequest setReason(DeductSTRRequest.DeductSTRReason reason)
reason
- Reason for the debit taking place
public DeductSTRRequest setValue(int value)
value
- The value to be deducted
public DeductSTRRequest addParam(String key, Object value)
ModifyRequest
value
will be converted by
calling Object.toString()
addParam
in class ModifyRequest
key
- The key for the parametervalue
- The value of the parameter
public Outcome validate()
Request
validate
in interface Request
validate
in class ModifyRequest
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |