TDFileStorage.h 900 B

12345678910111213141516171819202122232425262728293031323334
  1. //
  2. // TDFileStorage.h
  3. // TheoryNetwork
  4. //
  5. // Created by tederen on 2019/10/10.
  6. // Copyright © 2019 tederen. All rights reserved.
  7. //
  8. #import <Foundation/Foundation.h>
  9. NS_ASSUME_NONNULL_BEGIN
  10. @interface TDFileStorage : NSObject
  11. TDShareInstance_interface(TDFileStorage)
  12. #define _TDFileStorage [TDFileStorage sharedTDFileStorage]
  13. - (void)saveStringDefault:(NSString *)string forKey:(NSString *)key;
  14. - (NSString *)loadStringDefaultFromKey:(NSString *)key;
  15. - (void)saveArrayDefault:(NSArray *)array forKey:(NSString *)key;
  16. - (NSArray *)loadArrayDefaultFromKey:(NSString *)key;
  17. /* 首页搜索历史 */
  18. - (void)saveMainSearchArray:(NSArray *)array;
  19. - (NSArray *)loadMainSearchArray;
  20. - (void)saveHistorySearchBySearchType:(HistorySearchType)historySearchType WithArr:(NSArray *)array;
  21. - (NSArray *)loadHistorySearchBySearchType:(HistorySearchType)historySearchType;
  22. @end
  23. NS_ASSUME_NONNULL_END