mercredi 25 mars 2015

how to let a sub-class of UIViewController to be singleton

I have a lot of view controllers to interact with each other, so I am thinking to use "Mediator pattern" to manage this interaction. But in my opinion, it's better that all the controllers and coordinator should be singleton in "mediator pattern". it's easy to make coordinator to be singleton, but how to let a view controller to be singleton, anyone show some example here?


Aucun commentaire:

Enregistrer un commentaire