//
//  CloudStorageDownloadCenter.h
//  zhuxun
//
//  Created by winsoft on 17/6/26.
//
//

#import <Foundation/Foundation.h>
#import "CloudDownloadSession.h"
#import "CloudStorageDB.h"
typedef void (^FileDownStatusChangeBlock)(CSFileDownUpModel *csfileDownUpModel);
@interface CloudStorageDownloadCenter : NSObject
+ (instancetype)sharedInstance;

- (void)userServerOut;
/**
 *  添加当个下载(如果为文件夹,则需要递归)
 *
 *  @param fileModel filemodel
 */
@property (nonatomic , strong) FileDownStatusChangeBlock fileDownStatusChangeBlock;

- (void)addOneDownloadWithFileDownUpModel:(CSFileDownUpModel *)fileDownUpModel;
- (void)addOneDownloadWithFileDownUpModels:(NSArray *)fileDownUpModels;


- (void)registeDownloadBlockForUIWithcsFileDownUpModel:(CSFileDownUpModel *)csFileDownUpModel ProcessBlock:(DownloadProgressUIBlock)processBlock successBlock:(DownloadSuccessUIBlock)successBlock failBlock:(DownloadFailedUIBlock)failBlock;

- (void)updateOneDownloadStatusWithcsfileDownUpModel:(CSFileDownUpModel *)fileDownUpModel downUpStatus:(DownUpStatus)downUpStatus;
- (void)updateDownloadStatusWithcsfileDownUpModels:(NSArray<CSFileDownUpModel *> *)csfileDownUpModels downUpStatus:(DownUpStatus)downUpStatus;
@end
