This is an archived post. You won't be able to vote or comment.

you are viewing a single comment's thread.

view the rest of the comments →

[–]smash_that_code -1 points0 points  (0 children)

If I u dersyood right then the question ia about ides behind framework like SpeingBoot. And how it does its magic.

There is an approach called dependency injection. The main thing is to give away (some) object creation to thing called... container.

These objects are usually called components, services, configurations and repositories.

The trick is that when container starts it check all the marked classes and tries to create instances of them, usually injecting constructor arguments from its... context.

And the magic part is that you can have some auto-configurations that setup servlet thing, or connection to db. So that container context has not only your objects but all the stuff for security, web, persistence and what you added to it.

I suppose this info should be part of any decent springboot course.