public class PaymentEvent extends JSONParsable
| Modifier and Type | Field and Description |
|---|---|
protected Payment |
payment |
protected PaymentEventType |
type |
| Constructor and Description |
|---|
PaymentEvent()
Empty constructor
|
PaymentEvent(javax.json.JsonObject jsonObject)
JSON Parseable constructor
|
PaymentEvent(PaymentEventType type,
Payment payment)
Default constructor
|
| Modifier and Type | Method and Description |
|---|---|
void |
convertToJson(javax.json.JsonObjectBuilder jsonObjectBuilder)
Method that should set the objects property to Json representation.
|
Payment |
getPayment() |
PaymentEventType |
getType() |
void |
parseJson(javax.json.JsonObject jsonObject)
Method to read all properties from a JsonObject into this value object.
|
void |
setPayment(Payment payment) |
void |
setType(PaymentEventType type) |
add, addB58, addNotRequired, addNotRequiredB58, getBoolean, getBooleanIfSet, getByteArrayFromB58, getByteArrayFromB58IfSet, getByteArrayFromB64, getByteArrayFromB64IfSet, getByteArrayFromHex, getByteArrayFromHexIfSet, getDate, getDateIfSet, getDouble, getDoubleIfSet, getInt, getIntIfSet, getJsonArray, getJsonArrayIfSet, getJsonObject, getJsonObjectIfSet, getLong, getLongIfSet, getString, getStringIfSet, toJson, toJsonAsString, toStringprotected PaymentEventType type
protected Payment payment
public PaymentEvent()
public PaymentEvent(PaymentEventType type, Payment payment)
type - the type of payment event.payment - the related payment, either Order, Invoice or
Settlement depending on state of payment.public PaymentEvent(javax.json.JsonObject jsonObject)
throws javax.json.JsonException
jsonObject - the json object to parse.javax.json.JsonExceptionpublic PaymentEventType getType()
public void setType(PaymentEventType type)
type - the type of payment event.public Payment getPayment()
public void setPayment(Payment payment)
payment - the related payment, either Order, Invoice or
Settlement depending on state of payment.public void convertToJson(javax.json.JsonObjectBuilder jsonObjectBuilder)
throws javax.json.JsonException
convertToJson in class JSONParsablejsonObjectBuilder - the json object build to use to set key/values in jsonjavax.json.JsonException - if problems occurred converting object to JSON.public void parseJson(javax.json.JsonObject jsonObject)
throws javax.json.JsonException
parseJson in class JSONParsablejsonObject - the json object to read key and values from and set object properties.javax.json.JsonException - if problems occurred converting object from JSON.