I\'ve just read all of objective-c global constants variables Q&A but I found them inappropriate to my problem.
I need a list of variable like t
I don't have access to a MAC now ... can you just try this..
in .h
NSString *baseURLString;
extern NSString *const baseURL;
in .m
baseURLString= @"http://example.org";
NSString *const baseURL= [NSString stringWithFormat:"%@", baseURL];
I am not sure of this will work..
And also have you seen this answer at SO ... it has all the approaches I know of... Constants in Objective-C
I know it's old-fashioned but I'd just use preprocessor macros and let constant string concatenation handle it.
#define baseURL @"http://example.org"
#define mediaURL baseURL@"/media/"
#define API_ROOT_URL @"https://www.example.org/api"
NSString *const OAuthUrl = API_ROOT_URL @"/oauthToken";
See also.