I am new to Objective-C, not a full-time programmer. I'm starting to understand the Model-View-Controller design pattern to differentiate the user interface from the model. Thus, the user takes the action, and the view controller sends a message to the delegate (model). But I'm not sure what the best way to send actions from the delegate back to the view controller.
For example, a user clicks a button, a VC message is a delegate. I understand this part. Then the delegate takes action, and after that the delegate wants to update the VC (for example, update the label).
So I skipped (or forgot) how to do this while maintaining the separation between the user interface and the model. I guess I can use the notification center. Or I think that I can just pass the callback to the delegate to the view manager. Or maybe there is another choice that I do not know about. Can someone give me a recommendation, please?
source
share