|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--java.lang.Throwable | +--java.lang.Exception | +--com.ibm.etill.framework.payapi.ETillAbortOperation
The ETillAbortOperation exception should be thrown by cassettes to terminate the processing of the current operation. If that operation is an API command, then the Framework will send the return codes contained in the exception object back to the merchant application in the command response message.
Note that this exception only affects the current operation. Once thrown, the
current Commerce Payments thread as well as the cassette continue servicing new
requests. To terminate the cassette due to a very serious error, cassettes
should throw an ETillCassetteException
.
A note about Commerce Payments return codes:
Cassette writers are strongly encouraged to use the primary and secondary
return code values that are provided in
com.ibm.etill.framework.payapi.PaymentAPIConstants
in order
to provide a consistent programming interface to merchant software that's
written to Commerce Payments' generic payment API. Furthermore, under
no circumstances should a cassette define its own primary return codes.
If you cannot find a suitable primary/secondary return code pair in the
existing set of codes in PaymentAPIConstants
:
com.ibm.etill.framework.payapi.PaymentAPIConstants
. Unless
the error case you want to report through this return code is completely
unique to your payment protocol, then IBM will most likely be willing to
make the addition.
ETillCassetteException
, Serialized FormField Summary | |
---|---|
ReturnCodeStructure |
returnStructure
Deprecated. Cassettes should not access this instance variable. |
Constructor Summary | |
---|---|
ETillAbortOperation()
Default constructor. |
|
ETillAbortOperation(ReturnCodeStructure rc)
Constructs an ETillAbortOperation exception that contains the specified return code. |
|
ETillAbortOperation(short pRC,
short sRC)
Constructs an ETillAbortOperation exception that contains the specified primary and secondary return codes. |
|
ETillAbortOperation(short pRC,
short sRC,
String s)
Constructs an ETillAbortOperation exception that contains the specified return codes and error text. |
Method Summary | |
---|---|
short |
getPrimaryRC()
Returns the primary return code contained within this exception object. |
ReturnCodeStructure |
getReturnCodeStructure()
|
short |
getSecondaryRC()
Returns the secondary return code contained within this exception object. |
String |
toString()
Returns a string representation of this object for tracing purposes. |
Methods inherited from class java.lang.Throwable |
---|
fillInStackTrace, getLocalizedMessage, getMessage, printStackTrace, printStackTrace, printStackTrace |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public ReturnCodeStructure returnStructure
Constructor Detail |
public ETillAbortOperation(short pRC, short sRC)
pRC
- a short containing the primary return code as defined
in com.ibm.etill.framework.payapi.PaymentAPIConstants
.
Note that cassettes should not define their own primary return
codes, as described above.sRC
- a short containing the secondary return code as defined
in either com.ibm.etill.framework.payapi.PaymentAPIConstants
or by the cassette itself, as described above.
Note that all secondary return codes that may be set through this method
must be documented in the appropriate programming guide for reference by
merchant software writers.PaymentAPIConstants
public ETillAbortOperation(short pRC, short sRC, String s)
pRC
- a short containing the primary return code as defined
in com.ibm.etill.framework.payapi.PaymentAPIConstants
.
Note that cassettes should not define their own primary return
codes, as described above.sRC
- a short containing the secondary return code as defined
in either com.ibm.etill.framework.payapi.PaymentAPIConstants
or by the cassette itself, as described above.
Note that all secondary return codes that may be set through this method
must be documented in the appropriate programming guide for reference by
merchant software writers.s
- a String containing text to log in case the exception is written
to the trace log.PaymentAPIConstants
public ETillAbortOperation(ReturnCodeStructure rc)
rc
- a ReturnCodeStructure that contains primary and secondary return
codes. A cassette should not define their own primary, and must
have secondary return codes documented in the appropriate
programming guide for reference by merchant software writers.public ETillAbortOperation()
PaymentAPIConstants.PRC_INTERNAL_ETILL_ERROR
and PaymentAPIConstants.RC_UNEXPECTED
, respectively.PaymentAPIConstants
Method Detail |
public ReturnCodeStructure getReturnCodeStructure()
public short getPrimaryRC()
public short getSecondaryRC()
public String toString()
toString
in class Throwable
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |