Class AccountActivityRetrieveTransactionResponse
-
- All Implemented Interfaces:
public final class AccountActivityRetrieveTransactionResponseResponse containing multiple transaction types. The
familyfield determines which transaction type is returned: INTERNAL returns FinancialTransaction, TRANSFER returns BookTransferTransaction, CARD returns CardTransaction, PAYMENT returns PaymentTransaction, EXTERNAL_PAYMENT returns ExternalPaymentResponse, MANAGEMENT_OPERATION returns ManagementOperationTransaction, and HOLD returns HoldTransaction
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description public interfaceAccountActivityRetrieveTransactionResponse.VisitorAn interface that defines how to map each variant of AccountActivityRetrieveTransactionResponse to a value of type T.
public final classAccountActivityRetrieveTransactionResponse.FinancialTransactionFinancial transaction with inheritance from unified base transaction
public final classAccountActivityRetrieveTransactionResponse.CardTransactionCard transaction with ledger base properties
-
Method Summary
-
-
Method Detail
-
internal_
final Optional<AccountActivityRetrieveTransactionResponse.FinancialTransaction> internal_()
Financial transaction with inheritance from unified base transaction
-
transfer
final Optional<BookTransferResponse> transfer()
Book transfer transaction
-
card
final Optional<AccountActivityRetrieveTransactionResponse.CardTransaction> card()
Card transaction with ledger base properties
-
externalPayment
final Optional<ExternalPayment> externalPayment()
-
managementOperation
final Optional<ManagementOperationTransaction> managementOperation()
-
hold
final Optional<Hold> hold()
A hold transaction representing reserved funds on a financial account. Holds move funds from available to pending balance in anticipation of future payments. They can be resolved via settlement (linked to payment), manual release, or expiration.
-
isInternal
final Boolean isInternal()
-
isTransfer
final Boolean isTransfer()
-
isExternalPayment
final Boolean isExternalPayment()
-
isManagementOperation
final Boolean isManagementOperation()
-
asInternal
final AccountActivityRetrieveTransactionResponse.FinancialTransaction asInternal()
Financial transaction with inheritance from unified base transaction
-
asTransfer
final BookTransferResponse asTransfer()
Book transfer transaction
-
asCard
final AccountActivityRetrieveTransactionResponse.CardTransaction asCard()
Card transaction with ledger base properties
-
asExternalPayment
final ExternalPayment asExternalPayment()
-
asManagementOperation
final ManagementOperationTransaction asManagementOperation()
-
asHold
final Hold asHold()
A hold transaction representing reserved funds on a financial account. Holds move funds from available to pending balance in anticipation of future payments. They can be resolved via settlement (linked to payment), manual release, or expiration.
-
accept
final <T extends Any> T accept(AccountActivityRetrieveTransactionResponse.Visitor<T> visitor)
Maps this instance's current variant to a value of type T using the given visitor.
Note that this method is not forwards compatible with new variants from the API, unless visitor overrides Visitor.unknown. To handle variants not known to this version of the SDK gracefully, consider overriding Visitor.unknown:
import com.lithic.api.core.JsonValue; import java.util.Optional; Optional<String> result = accountActivityRetrieveTransactionResponse.accept(new AccountActivityRetrieveTransactionResponse.Visitor<Optional<String>>() { @Override public Optional<String> visitInternal(FinancialTransaction internal_) { return Optional.of(internal_.toString()); } // ... @Override public Optional<String> unknown(JsonValue json) { // Or inspect the `json`. return Optional.empty(); } });
-
validate
final AccountActivityRetrieveTransactionResponse validate()
Validates that the types of all values in this object match their expected types recursively.
This method is not forwards compatible with new types from the API for existing fields.
-
ofInternal
final static AccountActivityRetrieveTransactionResponse ofInternal(AccountActivityRetrieveTransactionResponse.FinancialTransaction internal_)
Financial transaction with inheritance from unified base transaction
-
ofTransfer
final static AccountActivityRetrieveTransactionResponse ofTransfer(BookTransferResponse transfer)
Book transfer transaction
-
ofCard
final static AccountActivityRetrieveTransactionResponse ofCard(AccountActivityRetrieveTransactionResponse.CardTransaction card)
Card transaction with ledger base properties
-
ofPayment
final static AccountActivityRetrieveTransactionResponse ofPayment(Payment payment)
Payment transaction
-
ofExternalPayment
final static AccountActivityRetrieveTransactionResponse ofExternalPayment(ExternalPayment externalPayment)
-
ofManagementOperation
final static AccountActivityRetrieveTransactionResponse ofManagementOperation(ManagementOperationTransaction managementOperation)
-
ofHold
final static AccountActivityRetrieveTransactionResponse ofHold(Hold hold)
A hold transaction representing reserved funds on a financial account. Holds move funds from available to pending balance in anticipation of future payments. They can be resolved via settlement (linked to payment), manual release, or expiration.
-
-
-
-