VoucherPayment

@interface VoucherPayment : NSObject

VoucherPayment contains all payment information including source, destination, and redemption information. Each User requesting a Voucher will receive different VoucherPayment information depending on their association of the Voucher.

  • Whether the VoucherPayment has been processed successfully.

    Declaration

    Objective-C

    @property (readonly, assign, nonatomic) BOOL success;

    Swift

    var success: Bool { get }
  • Source of an error, if one occurred.

    Declaration

    Objective-C

    @property (readonly, assign, nonatomic) PaymentInfoErrorSource errorSource;

    Swift

    var errorSource: PaymentInfoErrorSource { get }
  • State of an error, if one occurred.

    Declaration

    Objective-C

    @property (readonly, assign, nonatomic) PaymentInfoErrorState errorState;

    Swift

    var errorState: PaymentInfoErrorState { get }
  • Status code of an error, if one occurred.

    Declaration

    Objective-C

    @property (readonly, assign, nonatomic) NSInteger paymentErrorDetailsCode;

    Swift

    var paymentErrorDetailsCode: Int { get }
  • Message details of an error, if one occurred.

    Declaration

    Objective-C

    @property (readonly, strong, nonatomic, nullable)
        NSString *paymentErrorDetailsMessage;

    Swift

    var paymentErrorDetailsMessage: String? { get }
  • State of the VoucherPayment.

    Declaration

    Objective-C

    @property (readonly, assign, nonatomic) PaymentInfoState paymentState;

    Swift

    var paymentState: PaymentInfoState { get }
  • The source information (ie. Creator information) of the VoucherPayment.

    Declaration

    Objective-C

    @property (readonly, strong, nonatomic, nullable) PaymentInfo *sourceInfo;

    Swift

    var sourceInfo: PaymentInfo? { get }
  • The destination information (ie. claimer information) of the VoucherPayment.

    Declaration

    Objective-C

    @property (readonly, strong, nonatomic, nullable) PaymentInfo *destInfo;

    Swift

    var destInfo: PaymentInfo? { get }
  • The redemption information of the VoucherPayment.

    Declaration

    Objective-C

    @property (readonly, strong, nonatomic, nullable) PaymentInfo *redeemInfo;

    Swift

    var redeemInfo: PaymentInfo? { get }
  • An array of options related to the source of the payment.

    Declaration

    Objective-C

    @property (readonly, strong, nonatomic, nullable) NSArray *paymentSourceOptions;

    Swift

    var paymentSourceOptions: [Any]? { get }
  • An array of options related to the destination of the payment.

    Declaration

    Objective-C

    @property (readonly, strong, nonatomic, nullable) NSArray *paymentDestOptions;

    Swift

    var paymentDestOptions: [Any]? { get }
  • If an error occurs, indicates that the user must complete something to fix the error.

    Declaration

    Objective-C

    @property (readonly, assign, nonatomic) BOOL requiresIntervention;

    Swift

    var requiresIntervention: Bool { get }
  • Default Initializer for VoucherPayment that parses a dictionary of the VoucherPayment.

    Declaration

    Objective-C

    + (nonnull VoucherPayment *)voucherPaymentFromDictionary:
        (nonnull NSDictionary *)dictionary;

    Swift

    /*not inherited*/ init(from dictionary: [AnyHashable : Any])

    Parameters

    dictionary

    - dictionary form of the VoucherPayment.

    Return Value

    Instance of VoucherPayment.

  • Converts a VoucherPayment to an NSDictionary that can be used for caching or sending to the server.

    Declaration

    Objective-C

    - (nonnull NSDictionary *)dictionaryRepresentation;

    Swift

    func dictionaryRepresentation() -> [AnyHashable : Any]

    Return Value

    dictionary - Dictionary form of a VoucherPayment.