| Constructor and Description |
|---|
Transaction(java.lang.String name,
java.lang.String type,
Product productsReceived,
Product productsSpent)
Creates a new instance.
|
| Modifier and Type | Method and Description |
|---|---|
T |
putParam(java.lang.String key,
JsonParams value)
Puts nested parameters under the key.
|
T |
putParam(java.lang.String key,
java.lang.Object value)
Puts the key/value pair into the event parameters.
|
T |
setId(java.lang.String id)
Sets the transaction id.
|
T |
setProductId(java.lang.String productId)
Sets the product id.
|
T |
setReceipt(java.lang.String receipt)
Sets the transaction receipt.
|
T |
setServer(java.lang.String server)
Sets the transaction server.
|
T |
setTransactorId(java.lang.String transactorId)
Sets the transactor id.
|
public Transaction(java.lang.String name,
java.lang.String type,
Product productsReceived,
Product productsSpent)
name - the transaction's nametype - the transaction's typeproductsReceived - the received productsproductsSpent - the spent productsjava.lang.IllegalArgumentException - if the productsReceived is nulljava.lang.IllegalArgumentException - if the productsSpent is nullpublic T putParam(java.lang.String key, java.lang.Object value)
EventputParam in class Event<T extends Transaction<T>>key - the keyvalue - the valueT instancepublic T putParam(java.lang.String key, JsonParams value)
EventputParam in class Event<T extends Transaction<T>>key - the keyvalue - the valueT instancepublic T setId(java.lang.String id)
id - the transaction idT instancejava.lang.IllegalArgumentException - if the id is null or emptypublic T setProductId(java.lang.String productId)
productId - the product idT instancejava.lang.IllegalArgumentException - if the productId is null or
emptypublic T setReceipt(java.lang.String receipt)
receipt - the receiptT instancejava.lang.IllegalArgumentException - if the receipt is null or emptypublic T setServer(java.lang.String server)
server - the serverT instancejava.lang.IllegalArgumentException - if the receipt is null or emptypublic T setTransactorId(java.lang.String transactorId)
transactorId - the transactor idT instancejava.lang.IllegalArgumentException - if the transactorId is null or
empty