SDWebImage/DMImageCache.h

29 lines
813 B
C
Raw Normal View History

2009-09-20 04:24:03 +08:00
/*
* This file is part of the DMWebImage package.
* (c) Dailymotion - Olivier Poitrey <rs@dailymotion.com>
*
* For the full copyright and license information, please view the LICENSE
* file that was distributed with this source code.
*/
2009-09-20 02:45:42 +08:00
#import <Foundation/Foundation.h>
@interface DMImageCache : NSObject
{
NSMutableDictionary *memCache;
2009-09-20 02:45:42 +08:00
NSString *diskCachePath;
NSOperationQueue *cacheInQueue;
2009-09-20 02:45:42 +08:00
}
+ (DMImageCache *)sharedImageCache;
- (void)storeImage:(UIImage *)image forKey:(NSString *)key;
- (void)storeImage:(UIImage *)image forKey:(NSString *)key toDisk:(BOOL)toDisk;
- (UIImage *)imageFromKey:(NSString *)key;
- (UIImage *)imageFromKey:(NSString *)key fromDisk:(BOOL)fromDisk;
- (void)removeImageForKey:(NSString *)key;
- (void)clearMemory;
- (void)clearDisk;
- (void)cleanDisk;
@end