public final class TransactionDraftDsl extends Base
| Modifier and Type | Method and Description |
|---|---|
javax.money.MonetaryAmount |
getAmount() |
CustomFields |
getCustom() |
String |
getInteractionId() |
TransactionState |
getState()
The state of this transaction.
|
ZonedDateTime |
getTimestamp() |
TransactionType |
getType() |
TransactionDraftBuilder |
newBuilder()
Creates a new builder with the values of this object.
|
static TransactionDraftDsl |
of(TransactionDraft template)
Creates a new object initialized with the fields of the template parameter.
|
static TransactionDraftDsl |
of(TransactionType type,
javax.money.MonetaryAmount amount)
Creates a new object initialized with the given values.
|
static TransactionDraftDsl |
of(TransactionType type,
javax.money.MonetaryAmount amount,
ZonedDateTime timestamp)
Creates a new object initialized with the given values.
|
T |
withAmount(javax.money.MonetaryAmount amount) |
T |
withCustom(CustomFields custom) |
T |
withInteractionId(String interactionId) |
T |
withState(TransactionState state) |
T |
withTimestamp(ZonedDateTime timestamp) |
T |
withType(TransactionType type) |
public javax.money.MonetaryAmount getAmount()
getAmount in interface TransactionDraft@Nullable public CustomFields getCustom()
getCustom in interface TransactionDraft@Nullable public String getInteractionId()
getInteractionId in interface TransactionDraft@Nullable public TransactionState getState()
TransactionDraftgetState in interface TransactionDraft@Nullable public ZonedDateTime getTimestamp()
getTimestamp in interface TransactionDraftpublic TransactionType getType()
getType in interface TransactionDraftpublic TransactionDraftBuilder newBuilder()
public T withAmount(javax.money.MonetaryAmount amount)
public T withCustom(@Nullable CustomFields custom)
public T withState(@Nullable TransactionState state)
public T withTimestamp(@Nullable ZonedDateTime timestamp)
public T withType(TransactionType type)
public static TransactionDraftDsl of(TransactionType type, javax.money.MonetaryAmount amount)
type - initial value for the TransactionDraft.getType() propertyamount - initial value for the TransactionDraft.getAmount() propertypublic static TransactionDraftDsl of(TransactionType type, javax.money.MonetaryAmount amount, @Nullable ZonedDateTime timestamp)
type - initial value for the TransactionDraft.getType() propertyamount - initial value for the TransactionDraft.getAmount() propertytimestamp - initial value for the TransactionDraft.getTimestamp() propertypublic static TransactionDraftDsl of(TransactionDraft template)
template - the template