This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Spring and the fly likes When to use ApplicationContext start() Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Frameworks » Spring
Bookmark "When to use ApplicationContext start()" Watch "When to use ApplicationContext start()" New topic
Author

When to use ApplicationContext start()

Kaspar Christenson
Greenhorn

Joined: Feb 26, 2009
Posts: 21

When would you ever use the ApplicationContext start() method?

I've seen some books do this:


Why would anyone do that?
If you use start() do you have to use close()?

I just don't see where start() would be used outside of the spring framework.
Ankit Garg
Sheriff

Joined: Aug 03, 2008
Posts: 9291
    
  17

I don't see any start method in ApplicationContext class. In which books have you seen it being used?


SCJP 6 | SCWCD 5 | Javaranch SCJP FAQ | SCWCD Links
Kaspar Christenson
Greenhorn

Joined: Feb 26, 2009
Posts: 21

My mistake was to use ApplicationContext (I going from memory). Correct class in ClassPathXmlApplicationContext.

Pro Spring Integration
By: Dr. Mark Lui; Mario Gray; Andy Chan; Josh Long
Publisher: Apress
Pub. Date: March 24, 2011
Print ISBN: 978-1-4302-3345-9
Web ISBN: 1-4302-3345-1

In Chapter 5 and about 6 other places in the book.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: When to use ApplicationContext start()
 
Similar Threads
Spring MVC-How to get WebApplicationContext in Spring without ContextLoaderListener?
How does this works
1st Day in Springs: Introductory question
very new to spring. Need help in this small spring program
Best way to instantiate Spring context in a Servlet ?