OPPSTCPayPaymentParams
@objc
public final class OPPSTCPayPaymentParams : OPPPaymentParams, NSCopying
Class to encapsulate all necessary transaction parameters for performing an STC Pay transaction.
-
Shopper’s mobile phone number.
Declaration
Swift
@objc public var phoneNumber: String?
-
Creates an object representing a STC Pay transaction.
Throws
The error that occurred while validating payment parameters. See code attribute (OPPErrorCode
) andNSLocalizedDescription
to identify the reason of failure.Declaration
Swift
@objc public static func stcPayPaymentParams(checkoutID: String, verificationOption: OPPSTCPayVerificationOption) throws -> Self
Parameters
checkoutID
The checkout ID of the transaction. Must be not
nil
or empty.verificationOption
The verification option to proceed STC Pay transaction.
Return Value
Returns an object representing an STC Pay transaction.
-
Creates an object representing a STC Pay transaction.
Throws
The error that occurred while validating payment parameters. See code attribute (OPPErrorCode
) andNSLocalizedDescription
to identify the reason of failure.Declaration
Swift
@objc public init(checkoutID: String, verificationOption: OPPSTCPayVerificationOption) throws
Parameters
checkoutID
The checkout ID of the transaction. Must be not
nil
or empty.verificationOption
The verification option to proceed STC Pay transaction.
Return Value
Returns an object representing an STC Pay transaction.
-
Checks if the mobile phone is filled with sufficient data to perform a transaction.
Declaration
Swift
@objc public static func isMobilePhoneValid(_ mobilePhone: String) -> Bool
Parameters
mobilePhone
The mobile phone number.
Return Value
Returns
true
if the mobile phone number contains digits only.