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

android - net_scheduler holding wakelock -

sql - MySQL : Getting Entries from a many-to-many table -

java - Retrieving data from database using jsp (Hibernate + Spring + Maven) -