Still celebrating National IT Professionals Day with 3 months of free Premium Membership. Use Code ITDAY17

x
?
Solved

spring classpathxmlapplicationcontext

Posted on 2011-03-11
5
Medium Priority
?
440 Views
Last Modified: 2012-05-11
Hi,

I would like to know while instantiating  beanfactory why we use only classpathxmlapplicationcontext not other ones. What we use for ApplicationContext. What are the differences, similarities, uses of these two. Any ideas, suggestions, sample code, resources, links highly appreciated. Thanks in advance
0
Comment
Question by:gudii9
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 3
  • 2
5 Comments
 
LVL 20

Expert Comment

by:Sathish David Kumar N
ID: 35111328
0
 
LVL 7

Author Comment

by:gudii9
ID: 35218446
>>>where memory consumption might be critical and a few extra kilobytes might make a difference

does usage of application context consumes more memory. please advise
0
 
LVL 20

Expert Comment

by:Sathish David Kumar N
ID: 35221025
compare to beanfactory its take it takes less amount of memory , thats not main reason we go for applicationcontext! (AOP and transcation)

check diffrences table in that link .... u will get an idea

0
 
LVL 7

Author Comment

by:gudii9
ID: 35369029

Feature      BeanFactory      ApplicationContext
Bean instantiation/wiring

Yes

Yes

Automatic BeanPostProcessor registration

No

Yes

Automatic BeanFactoryPostProcessor registration

No

Yes

Convenient MessageSource access (for i18n)

No

Yes

ApplicationEvent publication

No

Yes



so

Automatic BeanPostProcessor registration

Automatic BeanFactoryPostProcessor registration

Convenient MessageSource access (for i18n)
ApplicationEvent publication

are not supported in BeanFactory where as supported in ApplicationContext. Tehn why we use BeanFactory. please advise
0
 
LVL 20

Accepted Solution

by:
Sathish David  Kumar N earned 2000 total points
ID: 35372593
ApplicationContext context extends beanfactory only ... so you can use application context ..

>>>>>>>Tehn why we use BeanFactory. please advise

Actult its mainly used for wiring concept . In your application you use only wiring then u go for beanfactory .

If you use applicationContext then it extends beanfactory only so both class memory will take here !
0

Featured Post

The top UI technologies you need to be aware of

An important part of the job as a front-end developer is to stay up to date and in contact with new tools, trends and workflows. That’s why you cannot miss this upcoming webinar to explore the latest trends in UI technologies!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction This article is the second of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers the basic installation and configuration of the test automation tools used by…
In this post we will learn how to make Android Gesture Tutorial and give different functionality whenever a user Touch or Scroll android screen.
Viewers will learn one way to get user input in Java. Introduce the Scanner object: Declare the variable that stores the user input: An example prompting the user for input: Methods you need to invoke in order to properly get  user input:
This tutorial explains how to use the VisualVM tool for the Java platform application. This video goes into detail on the Threads, Sampler, and Profiler tabs.

721 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question