Separation of concerns
The Separation of concerns is a principle for separating a computer program into distinct modules, where each module addresses a separate concern. A concern can be defined as a set of information or behavior that is part of a computer programming. An example could be persisting data in a store or calculating the discount to apply in an e-commerce app. A program that has an effective and clear separation of concerns is called modular. Dependency Injection helps to reach the modularity of a software defining only the interface of the module so that the details of the implementation don't interfere with the business logic of the module. However, a loosely-coupled code isn't automatically obtained with DI, it needs to be ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access