123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105 |
- //
- // BuryPoint.h
- // BuryPoint
- //
- // Created by Felix on 2018/8/10.
- // Copyright © 2018年 Felix. All rights reserved.
- //
- #import <Foundation/Foundation.h>
- #import "VclLog.h"
- #import "HWBuryPointModel.h"
- #ifdef Debug
- #define VclWrite(content) [[BuryPoint sharedInstance] writeContent:content]
- #else
- #define VclWrite(...)
- #endif
- /**
- 1.当应用程序崩溃时,BuryPoint会保存本次奔溃的信息到~/Library/Caches/BuryPoint/JoyLite/Reports/...目录下;
-
- 2.应用程序每次的启动,都会新创建一个文件,用于记录用户本次的操作、或者崩溃信息,命名如:log_2018.08.14.18_46_19.0190_ios.txt;
-
- 3.规定单个文件不能超过1024KB,当超过1024KB时应需要新建文件;
-
- 4.应用程序每次启动,都会检查除本次启动新建的文件外的所有日志文件名称,而且需要上传这些文件,根据上传返回的结果,上传成功的需要在本地删除掉
- 未上传成功的,暂不删除,待下次启动时再做上传处理。
- */
- // 定义一个BuriedPointType的字符串类型作为枚举类型
- typedef NSString *BuriedPointType NS_STRING_ENUM;
- // 声明以下埋点类型BuriedPointType枚举值
- // 云手机
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypeCloudPhone;
- // 云盘
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypeCloudStore;
- // 福利社区
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypeWelfare;
- // 云游戏
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypeCloudGame;
- // 我的
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypeMime;
- // 裂变活动-免费领机
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypeReceivePhone;
- // 支付结果页面进入周年庆活动
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypePaySuccessEnter;
- // 周年庆活动-分配确认
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypeClickDistribute;
- // 周年庆活动-分配确认 弹窗确认
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypeSureDistribute;
- // 周年庆活动-分配确认 弹窗取消
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypeCancelDistribute;
- // 周年庆活动-未分配返回
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypeDistributeBack;
- // 快捷方式创建埋点
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypeShortcutCreat;
- // 快捷方式打开埋点
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypeShortcutOpen;
- // 云手机试用续费弹窗
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypePlayActCodeForceCloseBuy;//@"激活码-强制关闭-去购买";
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypePlayActCodeForceCloseCancel;// @"激活码-强制关闭-取消";
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypePlayActCodeForceCloseGiveUp;// @"激活码-强制关闭-放弃";
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypePlayActCodeForceCloseContinue;// @"激活码-强制关闭-继续观看";
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypePlayActCodeCloseBuy;// @"激活码-关闭-去购买";
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypePlayActCodeCloseCancel;// @"激活码-关闭-取消";
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypePlayActCodeBreakBuy;// @"激活码-断线-去购买";
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypePlayActCodeBreakCancel;// @"激活码-断线-取消";
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypePlayFreeForceCloseBuy;// @"免费试用-强制关闭-去购买";
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypePlayFreeForceCloseCancel;// @"免费试用-强制关闭-取消";
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypePlayFreeForceCloseGiveUp;// @"免费试用-强制关闭-放弃";
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypePlayFreeForceCloseContinue;// @"免费试用-强制关闭-继续观看";
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypePlayFreeCloseBuy;// @"免费试用-关闭-去购买";
- FOUNDATION_EXPORT BuriedPointType const BuriedPointTypePlayFreeCloseCancel;// @"免费试用-关闭-取消";
- @interface BuryPoint : NSObject <NSCopying>
- + (instancetype)sharedInstance;
- /// 向buryPoint.txt文件写入content信息,会自动换行
- - (void)writeContent:(NSString *)content;
- + (void)reportBuriedPointWithType:(NSString *)type;
- /**试用广告埋点*/
- + (void)reportTrialADPointWithPhoneID:(NSString *)phoneID;
- #pragma mark - 全新埋点 7.1
- /** 保存或更新埋点数组缓存数据 */
- + (void)saveHWBuryPointModelListWithModel:(HWBuryPointModel *)model;
- /** 读取埋点数组缓存数据 */
- + (NSMutableArray *)readHWBuryPointModelList;
- /** 清空埋点数组缓存数据 */
- + (void)clearHWBuryPointModelList;
- /** 实时上报埋点数据 */
- + (void)updateBuryPointModelListWithModel:(HWBuryPointModel *)model;
- @end
|