Watch “Spring Part-3 | Tight Coupling and Loose Coupling in Spring Framework (Gujarati)” on YouTube

Tight coupling:
✔️ In general, Tight coupling means the two classes often change together.
✔️ In other words, if A knows more than it should about the way in which B was implemented, then A and B are tightly coupled.

Loose coupling:
✔️ In simple words, loose coupling means they are mostly independent. If the only knowledge that class A has about class B, is what class B has exposed through its interface, then class A and class B are said to be loosely coupled.
✔️ In order to over come from the problems of tight coupling between objects, spring framework uses dependency injection mechanism with the help of POJO/POJI model and through dependency injection its possible to achieve loose coupling.

Follow me @

#RaviROza #SpringFramework #AdvanceJava #Jdk #Java #Gujarati

Leave a Comment

%d bloggers like this: