Skip to content

Instantly share code, notes, and snippets.

@jfricker
Created August 18, 2009 00:26
Show Gist options
  • Select an option

  • Save jfricker/169460 to your computer and use it in GitHub Desktop.

Select an option

Save jfricker/169460 to your computer and use it in GitHub Desktop.
//
// JFDataCache.h
//
#import <Foundation/Foundation.h>
@interface JFDataCache : NSObject {
NSMutableDictionary *cache;
}
-(BOOL)dataInCache:(NSString *)key;
-(id)getCachedItem:(NSString *)key;
-(NSData *)getCachedData:(NSString *)key;
-(void)saveItemToCache:(NSObject *)item forKey:(NSString *)key;
-(void)saveDataToCache:(NSData *)item forKey:(NSString *)key;
+(JFDataCache *)dataCacheInstance;
@end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment