3 ms·
I use these in objective C, I usually create a data object and stick the networking function in it as well. Some use core data, but I haven't found a need for i
by eluos 14y ago
I use these in objective C, I usually create a data object and stick the networking function in it as well. Some use core data, but I haven't found a need for it yet.
static MySingleton *sharedSingleton;
+ (void)initialize
{
static BOOL initialized = NO;
if(!initialized)
{
initialized = YES;
sharedSingleton = [[MySingleton alloc] init];
}
}
- klibertp 14y ago+1 Informative. Thanks! :)