ZKComposedTransaction

Objective-C

@interface ZKComposedTransaction : NSObject

Swift

class ZKComposedTransaction : NSObject

Record containing result of one of the transaction compose methods on ZKWallet object.

See

ZKWallet
  • Declaration

    Objective-C

    - (nonnull instancetype)initWithType:(nonnull NSString *)type
                                 account:(nonnull ZKAccount *)account
                             destination:(nullable NSString *)destination
                                  amount:(nullable NSDecimalNumber *)amount
                                     fee:(nonnull NSDecimalNumber *)fee
                                   nonce:(nonnull NSString *)nonce
                       signedTransaction:(nullable NSString *)signedTransaction
                          custodyOrderId:(nullable NSString *)custodyOrderId
                                    data:(nullable NSString *)data;

    Swift

    init(type: String, account: ZKAccount, destination: String?, amount: NSDecimalNumber?, fee: NSDecimalNumber, nonce: String, signedTransaction: String?, custodyOrderId: String?, data: String?)
  • Declaration

    Objective-C

    + (nonnull instancetype)composedTransactionWithType:(nonnull NSString *)type
                                                account:(nonnull ZKAccount *)account
                                            destination:(nullable NSString *)destination
                                                 amount:(nullable NSDecimalNumber *)amount
                                                    fee:(nonnull NSDecimalNumber *)fee
                                                  nonce:(nonnull NSString *)nonce
                                      signedTransaction:(nullable NSString *)signedTransaction
                                         custodyOrderId:(nullable NSString *)custodyOrderId
                                                   data:(nullable NSString *)data;
  • Transaction type, ‘FIAT’, ‘CRYPTO’, ‘NOMINATED’ or ‘CUSTODY-WITHDRAW’.

    Declaration

    Objective-C

    @property (nonatomic, readonly, nonnull) NSString *type;

    Swift

    var type: String { get }
  • Account the composed transaction belongs to.

    Declaration

    Objective-C

    @property (nonatomic, readonly, nonnull) ZKAccount *account;

    Swift

    var account: ZKAccount { get }
  • Transaction destination, i.e. destination address for crypto transactions or user id for fiat transactions.

    Declaration

    Objective-C

    @property (nonatomic, readonly, nullable) NSString *destination;

    Swift

    var destination: String? { get }
  • Transaction amount in account currency.

    Declaration

    Objective-C

    @property (nonatomic, readonly, nullable) NSDecimalNumber *amount;

    Swift

    var amount: NSDecimalNumber? { get }
  • fee

    Maximum transaction fee.

    Declaration

    Objective-C

    @property (nonatomic, readonly, nonnull) NSDecimalNumber *fee;

    Swift

    var fee: NSDecimalNumber { get }
  • Transaction nonce to prevent double spend.

    Declaration

    Objective-C

    @property (nonatomic, readonly, nonnull) NSString *nonce;

    Swift

    var nonce: String { get }
  • Signed transaction for a crypto transaction, null otherwise.

    Declaration

    Objective-C

    @property (nonatomic, readonly, nullable) NSString *signedTransaction;

    Swift

    var signedTransaction: String? { get }
  • Custody order id for custody withdraw transaction, null otherwise.

    Declaration

    Objective-C

    @property (nonatomic, readonly, nullable) NSString *custodyOrderId;

    Swift

    var custodyOrderId: String? { get }
  • Optional transaction data if available.

    Declaration

    Objective-C

    @property (nonatomic, readonly, nullable) NSString *data;

    Swift

    var data: String? { get }