Model View Controller (MVC)
MVC is one of the simple design and development architecture for iOS app development. MVC produces the well organised structure of your project code. And when you use MVC design structure or pattern, it will speed up your work.
Basically MVC is a three layered design structure where you can design your project in three layers Model, View, and Controller, each layer has their own roles play in iOS application development.
Let’s get into details of each,
Model
Model is a business layer where you can keep your business logic, validations and organised data of your project.
View
View is rectangular area where you can design and display the user interface, in iOS there are different ways of creating UI, such as you can create by programatically, xib file or by using storyboard. When you use xib or storyboard, that means you are placing UI elements visually by interface builder.
Controller
Finally controller, basically controller is a mediator or delegate between your Model and View, which means the model and view will never talks to each other directly.
The below diagram shows the complete understanding of MVC communication.
0 Comments