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

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

caching - How to check if a url path exists in the service worker cache -

Redirect to a HTTPS version using .htaccess -