5 // Created by Andy Matuschak on 12/21/07.
6 // Copyright 2007 Andy Matuschak. All rights reserved.
9 #ifndef SUUSERDEFAULTS_H
10 #define SUUSERDEFAULTS_H
14 @abstract A substitute for NSUserDefaults that will work with arbitrary bundle identifiers.
15 @discussion Make sure you call -setIdentifier: before using SUUserDefaults. The other methods in this class work just like those in NSUserDefaults.
18 @interface SUUserDefaults
: NSObject
{
24 @abstract Returns a singleton instance of the user defaults class.
26 + (SUUserDefaults
*)standardUserDefaults
;
30 @abstract Sets which bundle identifier to use when setting and retrieving defaults.
31 @discussion It is imperative that you set the identifier through this method before trying to set or retrieve defaults.
33 - (void)setIdentifier
:(NSString
*)identifier
;
35 - (id
)objectForKey
:(NSString
*)defaultName
;
36 - (void)setObject
:(id
)value forKey
:(NSString
*)defaultName
;
37 - (BOOL
)boolForKey
:(NSString
*)defaultName
;
38 - (void)setBool
:(BOOL
)value forKey
:(NSString
*)defaultName
;