Skip to main content

All Questions

0 votes
1 answer
242 views

Overriding a NSMutableUrlRequest static initializer?

Heres my scenario. Most of my network calls now need to have an api key inserted into the header field when making a request. So what i was thinking i could do was make a category of ...
Esko918's user avatar
  • 1,459
0 votes
2 answers
412 views

Weird singleton initialization in static function initialize during unit tests

I have a following code in my singleton class static MySingleton *gManager; +(void)initialize { if(self == [MySingleton class]) { gManager = [[MySingleton alloc] initWithServices:[[...
Nitin Singh's user avatar
0 votes
1 answer
457 views

Using constant objects in objective-c

I have a piece of code similar to this: //Foo.h OBJC_EXPORT MyObject *const myObj; // Foo.m MyObject *const myObj; @implementation Foo +(void) initialize { if (self = [Graph class]) { ...
Richard J. Ross III's user avatar