RQCacheManager.h 726 B

123456789101112131415161718192021
  1. //
  2. // RQCacheManager.h
  3. // JSJP
  4. //
  5. // Created by 张嵘 on 2021/8/17.
  6. //
  7. #import <Foundation/Foundation.h>
  8. #define RQ_CACHE_MANAGER [RQCacheManager sharedInstance]
  9. NS_ASSUME_NONNULL_BEGIN
  10. @interface RQCacheManager : NSObject
  11. @singleton(RQCacheManager);
  12. - (void)removeAllCache;
  13. - (void)removeCacheWithPath:(NSString *)path parameters:(NSDictionary * __nullable)parameters;
  14. - (BOOL)isNeedCacheWithPath:(NSString *)path;
  15. - (void)saveCacheWithPath:(NSString *)path parameters:(NSDictionary * __nullable)parameters response:(NSURLResponse *)response responseObject:(NSDictionary *)responseObject;
  16. - (NSDictionary *)getCacheWithPath:(NSString *)path parameters:(NSDictionary * __nullable)parameters;
  17. @end
  18. NS_ASSUME_NONNULL_END