ios - Accessing an object created by one view controller from another view controller -
this question has reply here:
passing info between view controllers 33 answersis there way create nsobject
, set values in 1 view controller, , them in view controller looking existing instance of nsobject
?
much appdelegate has sharedinstance
can access anywhere , set values anywhere?
i created view controller instantiates model object , fills properties. how access instance of model object view controller?
i'm not asking how pass info in view controller calls view controller. know how that. i'm asking how set values model object different, unrelated , hierarchically independent view controllers.
if understand question correctly, looking key value observation. commonly used decouple controller layer model layer (as in mvc, model view controller).
ios cocoa-touch uiviewcontroller
No comments:
Post a Comment