OPPAffirmProcessor
@interface OPPAffirmProcessor : NSObject
Class to process affirm transaction.
-
Creates an object representing an affirm processor.
Declaration
Objective-C
- (nullable instancetype) initWithTransaction:(nonnull OPPTransaction *)transaction mode:(OPPProviderMode)mode error:(NSError *_Nullable *_Nullable)error;Swift
init(transaction: OPPTransaction, mode: OPPProviderMode) throwsParameters
transactionTransaction object to process, and it should not be nil.
modeProvider mode to set environment.
errorError occured while initializing the processor.
Return Value
Returns an object representing an affirm processor.
-
Method to process affirm transaction
Declaration
Objective-C
- (void)process:(nonnull UIViewController *)presentingViewController with:(nonnull CompletionBlock)completionBlock;Swift
func process(_ presentingViewController: UIViewController) async throws -> OPPTransactionParameters
presentingViewControllerViewcontroller to present affirm transaction processing view.
completionBlockCompletion block to handle transaction or error.
OPPAffirmProcessor Class Reference