I am new to Spring . I was going through An article on spring injection dependency. I read following thing.
in case of Constructor Injection the dependencies are handed over at the time of object instantiation of the dependent objects whereas In case of Setter/Mutator Injection the dependencies are injected after the dependent object has already been created
If i have a Interface IUserService . Code is like that.
then please make me clear that is userService is a dependent component??
And let me know that who create the dependent object In context of following article.
Good luck!!
A small leak can sink a Gigantic ship.>
I think it first creates the object !
as we are calling a method findUser() without instantiating UserService class with implements IUserService.
how can a method be called without object.
it clears that Spring container manages the object instntiation .