Skip to content

Instantly share code, notes, and snippets.

@johncblandii
Last active December 26, 2015 06:19
Show Gist options
  • Save johncblandii/7106795 to your computer and use it in GitHub Desktop.
Save johncblandii/7106795 to your computer and use it in GitHub Desktop.
This is a header file with static methods for saving user defaults. It goes with: https://gist.github.com/johncblandii/7106773.
#import <Foundation/Foundation.h>
#define PREFERENCE_NAME_HERE @"someUniquePreferenceNameHere"
@interface Preferences : NSObject
#pragma mark Preferences
+(id)getUserPreference:(NSString*)forKey;
+(void)setUserPreference:(id)value forKey:(NSString*)key;
@end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment