bean wiring in Spring framework

what is bean wiring in Spring framework ? Could you please explain a bit.

Any example please.
cofactorAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

StealthyDevCommented:
0
cofactorAuthor Commented:
Buddy, I have read that already . But I don't understand the concept . Please explain
its written as ...

Combining together beans within the Spring container is known as bean wiring or wiring. When wiring beans, you should tell the container what beans are needed and how the container should use dependency injection to tie them together. '
How do we combine beans ?  I need example .  How do we do the bean wiring ?
0
StealthyDevCommented:
See the below Example, you will be surprised!

http://www.javalobby.org/java/forums/t18396.html

Best Regards.
0
Build an E-Commerce Site with Angular 5

Learn how to build an E-Commerce site with Angular 5, a JavaScript framework used by developers to build web, desktop, and mobile applications.

Sathish David Kumar NArchitectCommented:
before that you must know the
singleton and prototype define of beans in spring ... this is the main concept here !

0
Sathish David Kumar NArchitectCommented:
<bean id="check1" class="">
    <property value="check2" />
</bean>

<bean id="check2".........

this is you have defined the dispatcher-servlet xml file

check1,cheak2 are beans , you defined the check2 bean as property of check1 bean od this is combination of beans
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
cofactorAuthor Commented:
>dispatcher-servlet xml
did you mean the Spring configuration file ?
0
rajkumar_pbCommented:
^^ Yes the dispatcher-servlet.xml is none other than spring cfg file.

Wiring :

In traditional programming ,creating associations between objects lead to code that is difficult to reuse and unit-test, and these objects are usually highly coupled to each-other making them hard to reuse and unit test, and they are doing more work than they should making them less cohesive.In spring components are not responsible for managing associations with other components. Instead they are given references to collaborating components by the container. The act of creating these associations between applications is called wiring.
You got that?

Refer this if you still have any doubt :

http://static.springsource.org/spring/docs/2.5.x/reference/beans.html#beans-dependencies
0
Sathish David Kumar NArchitectCommented:
yes your correct !!
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Java

From novice to tech pro — start learning today.