ios - Error in class method when implementing Core Data Stack -


i followed this tutorial implement core data stack , i'm getting error in temporaryworkercontext class method.

+ (nsmanagedobjectcontext *)temporaryworkercontext {      nsmanagedobjectcontext *tempmocontext = [[nsmanagedobjectcontext alloc] initwithconcurrencytype:nsprivatequeueconcurrencytype];     tempmocontext.parentcontext = _mainmanagedobjectcontext;<--error here: instance variable '_mainmanagedobjectcontext' accessed in class method     return tempmocontext; } 

my question is, correct way implement core data stack without errors? class method required, controller calling hold strong reference temporaryworkercontext.


Comments

Popular posts from this blog

Unlimited choices in BASH case statement -

Redirect to a HTTPS version using .htaccess -

javascript - jQuery: Add class depending on URL in the best way -