// // photosBackupsTaskModel.h // 隐私保护 // // Created by xd h on 2024/1/3. // #import "JSONModel.h" #import "BGFMDB.h" //添加该头文件,本类就具有了存储功能. #import #import "uploadFileDataModel.h" NS_ASSUME_NONNULL_BEGIN typedef enum{ backupsStateUploading = 0, backupsStateSuspend, backupsStateFail, backupsStateDone,// }backupsStateType; typedef enum{ backupsSuspendNone = 0, backupsSuspendByOther, backupsSuspendByUser,// }backupsSuspendType; @interface photosBackupsTaskModel : JSONModel @property (nonatomic, assign) NSInteger count; ///< Count of photos the album contain //@property (nonatomic, strong) PHFetchResult *result; //@property (nonatomic, strong) PHAssetCollection *collection; //@property (nonatomic, strong) PHFetchOptions *options; //@property (nonatomic, strong) NSArray *models; @property (nonatomic, copy) NSString *totalLocalIdentifier;//相册全部的 @property (nonatomic, copy) NSString *curTaskLocalIdentifier;//对比上一次相册的 的到新加入相册的内容 @property (nonatomic, strong) NSArray *LocalIdentifierArr; @property (nonatomic, copy) NSString *filename; @property (nonatomic, assign) BOOL didBackupsOneFileType;//某个文件已经存在 @property (nonatomic, assign) NSUInteger failCount; @property (nonatomic, assign) NSUInteger didBackupsCount; @property (nonatomic, assign) NSUInteger PreDidBackupsCount;//上传备份成功的 //@property (nonatomic, assign) NSUInteger curTaskBackupsCount;//本次任务备份的数量 @property (nonatomic, assign) backupsSuspendType isBackupsSuspendType; @property (nonatomic, assign) backupsStateType curBackupsState; @property (nonatomic, copy) NSString *backupsTipMsg;//备份失败消息等 @property (nonatomic, retain) NSData *_Nullable imageData;//image //@property (nonatomic, assign) uploadStateType curUploadStateType; @property (nonatomic, assign) uploadFileType curUploadFileType; @property (nonatomic, assign) long didUploadBytes;//已经上传的字节数 @property (nonatomic, assign) long preDidUploadBytes;//上次传到了多少 @property (nonatomic, assign) long totalBytes;//总字节数 @property (nonatomic, assign) NSTimeInterval preTimeInterval;//计算速度用 @property (nonatomic, assign) NSTimeInterval curTimeInterval;//计算速度用 @property (nonatomic, copy) NSString *backupsPath;//备份路径 //1.4.2 @property (nonatomic, copy) NSString *failTaskLocalIdentifier;//失败的 @property (nonatomic, assign) NSInteger oneFileFailCount;//单个文件尝试上次失败 次数 @property (nonatomic, copy) NSString *curFileLocalIdentifier;//当前要上传的文件 @end NS_ASSUME_NONNULL_END