ashmi123 ashmi123 - 12 days ago 6
iOS Question

Which iOS Architecture Pattern is better to optimize the code Can anyone explain?

I want to make the APP as I had already used MVC pattern for the development , but if anyone know which one is good architecture with proper explanation so I can go for that.

Appreciate with your help thanks!!

Answer

There are lots of different design pattern which you can use based on your requirement, scope of project. There are couple of articles which will guide you through these patterns, i'd just brief you abt the same.

List of some design pattern:

  • Singleton
  • List item
  • Delegate
  • Model View Controller
  • Observer
  • Facade
  • Command
  • Template Method

No one can say that one pattern is best and other is not, each patterns has its own features. Still IMO Model View Controller design patter is mostly used as lots of Cocoa iOS frameworks are based on this design pattern. So just see the difference between each and use the one which suites you requirement and don't think that you can only use one pattern at a time on in one project, you can use multiple design pattern in single project like MVC and SingleTone.

Ref:

https://www.raywenderlich.com/46988/ios-design-patterns

https://www.cs.colorado.edu/~kena/classes/5448/f12/presentation-materials/myrose.pdf

https://medium.com/ios-os-x-development/ios-architecture-patterns-ecba4c38de52#.wl5ff762q

Hope that helps you.

Comments