国内WASDK Apple实现层
hank
2018-09-20 a562a4ec2a4adb187c538fa16a4441de4ea8d12b
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
//
//  GHWSDKPaymentTransactionHandler.h
//  GHWSdkUI
//
//  Created by wuyx on 15/8/19.
//  Copyright (c) 2015年 GHW-T-01. All rights reserved.
//
 
#import <Foundation/Foundation.h>
#import <StoreKit/StoreKit.h>
 
extern NSString *CACHE_KEY_PAYMENT_TRANSACTION;
 
@interface WAAPPaymentTransactionHandler : NSObject
@property(strong,nonatomic)NSMutableDictionary* unConsumeOrderList;
/**
 *  将上报失败的订单保存到缓存中
 *
 *  @param skPaymentTransaction
 *  @param status
 */
+(void)saveCacheWithPaymentTransaction:(SKPaymentTransaction*)skPaymentTransaction andStatus:(int)status;
 
 
/**
 *  通过skProduct 获取未消耗订单列表
 *
 *  @param skProduct
 *
 *  @return NSMutableArray
 */
+(NSMutableArray*)getUnconsumeOrderListWithProduct:(SKProduct*)skProduct;
 
/**
 *  处理未消耗订单
 *
 *  @param unComsumeList 未消耗订单列表
 */
+(void)handleWithUnComsumeList:(NSArray*)unComsumeList;
 
/**
 *  重试成功,移除未消耗订单
 *
 *  @param skPaymentTransaction
 */
+(void)removeUncomsumeListWithPaymentTransaction:(SKPaymentTransaction *)skPaymentTransaction;
 
+(BOOL)isInit;
@end