Answer the question
In order to leave comments, you need to log in
What are clean architecture use cases in MVC?
I decided to read a little about clean architecture in the view of Robert Martin. I did not understand the above division into layers regarding the architecture of the web application a little. With entities, controllers, frameworks, in general, it’s probably understandable. However, a question arose regarding the red layer - use cases. As far as I understand, it contains the main business logic of the application. I understand correctly that in the classic MVC, the red and green layers are not separated, because logic is written in controllers (or models, it doesn't matter). Or does the green layer represent only routes, and the red one - controllers, models? Thanks in advance.
Add. question
Also, I didn’t really understand why Robert selects the Database in the topmost layer. If, judging by the hint, we take into account that the blue layer is a framework, everything is logical, because it does not depend on anything and manages all underlying layers, but this cannot be said about the database, because. underlying layers will interact with it anyway, violating the dependency rule. Is not it?
Answer the question
In order to leave comments, you need to log in
However, there was a question regarding the red layer - use cases
I understand correctly that in the classic MVC, the red and green layers are not separated, because logic is written in controllers (or models, it doesn't matter). Or does the green layer represent only routes, and the red one - controllers, models?
Also, I didn’t really understand why Robert selects the Database in the topmost layer.
because underlying layers will interact with it anyway, violating the dependency rule. Is not it?
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question