OPPCheckoutData
@interface OPPCheckoutData : NSObject
/// @name Properties
/** Checkout Data shopper's shipping address. */
@property (nonatomic, strong) OPPCDShipping *shipping;
/** Checkout Data shopper's billing address. */
@property (nonatomic, strong) OPPCDBilling *billing;
/** Checkout Data shopper's cart object. */
@property (nonatomic, strong) OPPCDCart *cart;
/** Checkout Data shopper's cart total amount. */
@property (nonatomic, copy) NSString *amount;
/** Checkout Data shopper's currency. */
@property (nonatomic, copy) NSString *currency;
/** Checkout Data tax amount. */
@property (nonatomic, copy) NSString *taxAmount;
/** Checkout Data merchnat transaction id. */
@property (nonatomic, copy) NSString *merchantTransactionID;
/** Checkout Data merchnat object. */
@property (nonatomic, strong) OPPCDMerchant *merchant;
/// @name Initialization
/**
Creates checkout info object from the JSON that can be received from the Server by checkout ID.
@param JSON A dictionary with parameters received from the Server.
@param error An error if JSON is invalid.
@return Returns an `OPPCheckoutInfo` object, or `nil` if JSON is invalid.
*/
+ (nullable instancetype)checkoutDataFromJSON:(NSDictionary *)JSON error:(NSError * _Nullable *)error;
@end
Undocumented
-
Checkout Data shopper’s shipping address.
Declaration
Objective-C
@property (nonatomic, strong) OPPCDShipping *_Nonnull shipping;
Swift
var shipping: OPPCDShipping { get set }
-
Checkout Data shopper’s billing address.
Declaration
Objective-C
@property (nonatomic, strong) OPPCDBilling *_Nonnull billing;
Swift
var billing: OPPCDBilling { get set }
-
Checkout Data shopper’s cart total amount.
Declaration
Objective-C
@property (nonatomic, copy) NSString *_Nonnull amount;
Swift
var amount: String { get set }
-
Checkout Data shopper’s currency.
Declaration
Objective-C
@property (nonatomic, copy) NSString *_Nonnull currency;
Swift
var currency: String { get set }
-
Checkout Data tax amount.
Declaration
Objective-C
@property (nonatomic, copy) NSString *_Nonnull taxAmount;
Swift
var taxAmount: String { get set }
-
Checkout Data merchnat transaction id.
Declaration
Objective-C
@property (nonatomic, copy) NSString *_Nonnull merchantTransactionID;
Swift
var merchantTransactionID: String { get set }
-
Checkout Data merchnat object.
Declaration
Objective-C
@property (nonatomic, strong) OPPCDMerchant *_Nonnull merchant;
Swift
var merchant: OPPCDMerchant { get set }
-
Creates checkout info object from the JSON that can be received from the Server by checkout ID.
Declaration
Objective-C
+ (nullable instancetype)checkoutDataFromJSON:(nonnull NSDictionary *)JSON error:(NSError *_Nullable *_Nullable) error;
Swift
convenience init(fromJSON JSON: [AnyHashable : Any]) throws
Parameters
JSON
A dictionary with parameters received from the Server.
error
An error if JSON is invalid.
Return Value
Returns an
OPPCheckoutInfo
object, ornil
if JSON is invalid.