Java Doc for AbstractRefreshableApplicationContext.java in  » J2EE » spring-framework-2.0.6 » org » springframework » context » support » Java Source Code / Java DocumentationJava Source Code and Java Documentation

Java Source Code / Java Documentation
1. 6.0 JDK Core
2. 6.0 JDK Modules
3. 6.0 JDK Modules com.sun
4. 6.0 JDK Modules com.sun.java
5. 6.0 JDK Modules sun
6. 6.0 JDK Platform
7. Ajax
8. Apache Harmony Java SE
9. Aspect oriented
10. Authentication Authorization
11. Blogger System
12. Build
13. Byte Code
14. Cache
15. Chart
16. Chat
17. Code Analyzer
18. Collaboration
19. Content Management System
20. Database Client
21. Database DBMS
22. Database JDBC Connection Pool
23. Database ORM
24. Development
25. EJB Server geronimo
26. EJB Server GlassFish
27. EJB Server JBoss 4.2.1
28. EJB Server resin 3.1.5
29. ERP CRM Financial
30. ESB
31. Forum
32. GIS
33. Graphic Library
34. Groupware
35. HTML Parser
36. IDE
37. IDE Eclipse
38. IDE Netbeans
39. Installer
40. Internationalization Localization
41. Inversion of Control
42. Issue Tracking
43. J2EE
44. JBoss
45. JMS
46. JMX
47. Library
48. Mail Clients
49. Net
50. Parser
51. PDF
52. Portal
53. Profiler
54. Project Management
55. Report
56. RSS RDF
57. Rule Engine
58. Science
59. Scripting
60. Search Engine
61. Security
62. Sevlet Container
63. Source Control
64. Swing Library
65. Template Engine
66. Test Coverage
67. Testing
68. UML
69. Web Crawler
70. Web Framework
71. Web Mail
72. Web Server
73. Web Services
74. Web Services apache cxf 2.0.1
75. Web Services AXIS2
76. Wiki Engine
77. Workflow Engines
78. XML
79. XML UI
Java
Java Tutorial
Java Open Source
Jar File Download
Java Articles
Java Products
Java by API
Photoshop Tutorials
Maya Tutorials
Flash Tutorials
3ds-Max Tutorials
Illustrator Tutorials
GIMP Tutorials
C# / C Sharp
C# / CSharp Tutorial
C# / CSharp Open Source
ASP.Net
ASP.NET Tutorial
JavaScript DHTML
JavaScript Tutorial
JavaScript Reference
HTML / CSS
HTML CSS Reference
C / ANSI-C
C Tutorial
C++
C++ Tutorial
Ruby
PHP
Python
Python Tutorial
Python Open Source
SQL Server / T-SQL
SQL Server / T-SQL Tutorial
Oracle PL / SQL
Oracle PL/SQL Tutorial
PostgreSQL
SQL / MySQL
MySQL Tutorial
VB.Net
VB.Net Tutorial
Flash / Flex / ActionScript
VBA / Excel / Access / Word
XML
XML Tutorial
Microsoft Office PowerPoint 2007 Tutorial
Microsoft Office Excel 2007 Tutorial
Microsoft Office Word 2007 Tutorial
Java Source Code / Java Documentation » J2EE » spring framework 2.0.6 » org.springframework.context.support 
Source Cross Reference  Class Diagram Java Document (Java Doc) 


org.springframework.context.support.AbstractApplicationContext
   org.springframework.context.support.AbstractRefreshableApplicationContext

All known Subclasses:   org.springframework.web.portlet.context.AbstractRefreshablePortletApplicationContext,  org.springframework.context.support.AbstractXmlApplicationContext,  org.springframework.web.context.support.AbstractRefreshableWebApplicationContext,
AbstractRefreshableApplicationContext
abstract public class AbstractRefreshableApplicationContext extends AbstractApplicationContext (Code)
Base class for org.springframework.context.ApplicationContext implementations which are supposed to support multiple refreshs, creating a new internal bean factory instance every time. Typically (but not necessarily), such a context will be driven by a set of config locations to load bean definitions from.

The only method to be implemented by subclasses is AbstractRefreshableApplicationContext.loadBeanDefinitions , which gets invoked on each refresh. A concrete implementation is supposed to load bean definitions into the given org.springframework.beans.factory.support.DefaultListableBeanFactory , typically delegating to one or more specific bean definition readers.

Note that there is a similar base class for WebApplicationContexts. org.springframework.web.context.support.AbstractRefreshableWebApplicationContext provides the same subclassing strategy, but additionally pre-implements all context functionality for web environments. There is also a pre-defined way to receive config locations for a web context.

Concrete standalone subclasses of this base class, reading in a specific bean definition format, are ClassPathXmlApplicationContext and FileSystemXmlApplicationContext , which both derive from the common AbstractXmlApplicationContext base class.
author:
   Juergen Hoeller
since:
   1.1.3
See Also:   AbstractRefreshableApplicationContext.loadBeanDefinitions
See Also:   org.springframework.beans.factory.support.DefaultListableBeanFactory
See Also:   org.springframework.web.context.support.AbstractRefreshableWebApplicationContext
See Also:   AbstractXmlApplicationContext
See Also:   ClassPathXmlApplicationContext
See Also:   FileSystemXmlApplicationContext




Constructor Summary
public  AbstractRefreshableApplicationContext()
     Create a new AbstractRefreshableApplicationContext with no parent.
public  AbstractRefreshableApplicationContext(ApplicationContext parent)
     Create a new AbstractRefreshableApplicationContext with the given parent context.

Method Summary
final protected  voidcloseBeanFactory()
    
protected  DefaultListableBeanFactorycreateBeanFactory()
     Create an internal bean factory for this context. Called for each AbstractRefreshableApplicationContext.refresh() attempt.

The default implementation creates a org.springframework.beans.factory.support.DefaultListableBeanFactory with the AbstractRefreshableApplicationContext.getInternalParentBeanFactory() internal bean factory of this context's parent as parent bean factory.

protected  voidcustomizeBeanFactory(DefaultListableBeanFactory beanFactory)
     Customize the internal bean factory used by this context. Called for each AbstractRefreshableApplicationContext.refresh() attempt.

The default implementation is empty.

final public  ConfigurableListableBeanFactorygetBeanFactory()
    
abstract protected  voidloadBeanDefinitions(DefaultListableBeanFactory beanFactory)
     Load bean definitions into the given bean factory, typically through delegating to one or more bean definition readers.
final protected  voidrefreshBeanFactory()
    


Constructor Detail
AbstractRefreshableApplicationContext
public AbstractRefreshableApplicationContext()(Code)
Create a new AbstractRefreshableApplicationContext with no parent.



AbstractRefreshableApplicationContext
public AbstractRefreshableApplicationContext(ApplicationContext parent)(Code)
Create a new AbstractRefreshableApplicationContext with the given parent context.
Parameters:
  parent - the parent context




Method Detail
closeBeanFactory
final protected void closeBeanFactory()(Code)



createBeanFactory
protected DefaultListableBeanFactory createBeanFactory()(Code)
Create an internal bean factory for this context. Called for each AbstractRefreshableApplicationContext.refresh() attempt.

The default implementation creates a org.springframework.beans.factory.support.DefaultListableBeanFactory with the AbstractRefreshableApplicationContext.getInternalParentBeanFactory() internal bean factory of this context's parent as parent bean factory. Can be overridden in subclasses, for example to customize DefaultListableBeanFactory's settings. the bean factory for this context
See Also:   org.springframework.beans.factory.support.DefaultListableBeanFactory.setAllowBeanDefinitionOverriding
See Also:   org.springframework.beans.factory.support.DefaultListableBeanFactory.setAllowEagerClassLoading
See Also:   org.springframework.beans.factory.support.DefaultListableBeanFactory.setAllowCircularReferences
See Also:   org.springframework.beans.factory.support.DefaultListableBeanFactory.setAllowRawInjectionDespiteWrapping




customizeBeanFactory
protected void customizeBeanFactory(DefaultListableBeanFactory beanFactory)(Code)
Customize the internal bean factory used by this context. Called for each AbstractRefreshableApplicationContext.refresh() attempt.

The default implementation is empty. Can be overridden in subclasses to customize DefaultListableBeanFactory's standard settings.
Parameters:
  beanFactory - the newly created bean factory for this context
See Also:   org.springframework.beans.factory.support.DefaultListableBeanFactory.setAllowBeanDefinitionOverriding
See Also:   org.springframework.beans.factory.support.DefaultListableBeanFactory.setAllowEagerClassLoading
See Also:   org.springframework.beans.factory.support.DefaultListableBeanFactory.setAllowCircularReferences
See Also:   org.springframework.beans.factory.support.DefaultListableBeanFactory.setAllowRawInjectionDespiteWrapping




getBeanFactory
final public ConfigurableListableBeanFactory getBeanFactory()(Code)



loadBeanDefinitions
abstract protected void loadBeanDefinitions(DefaultListableBeanFactory beanFactory) throws IOException, BeansException(Code)
Load bean definitions into the given bean factory, typically through delegating to one or more bean definition readers.
Parameters:
  beanFactory - the bean factory to load bean definitions into
throws:
  IOException - if loading of bean definition files failed
throws:
  BeansException - if parsing of the bean definitions failed
See Also:   org.springframework.beans.factory.support.PropertiesBeanDefinitionReader
See Also:   org.springframework.beans.factory.xml.XmlBeanDefinitionReader



refreshBeanFactory
final protected void refreshBeanFactory() throws BeansException(Code)



Fields inherited from org.springframework.context.support.AbstractApplicationContext
final public static String APPLICATION_EVENT_MULTICASTER_BEAN_NAME(Code)(Java Doc)
final public static String MESSAGE_SOURCE_BEAN_NAME(Code)(Java Doc)
final protected Log logger(Code)(Java Doc)

Methods inherited from org.springframework.context.support.AbstractApplicationContext
public void addApplicationListener(ApplicationListener listener)(Code)(Java Doc)
public void addBeanFactoryPostProcessor(BeanFactoryPostProcessor beanFactoryPostProcessor)(Code)(Java Doc)
protected void addListener(ApplicationListener listener)(Code)(Java Doc)
public void close()(Code)(Java Doc)
abstract protected void closeBeanFactory()(Code)(Java Doc)
public boolean containsBean(String name)(Code)(Java Doc)
public boolean containsBeanDefinition(String name)(Code)(Java Doc)
public boolean containsLocalBean(String name)(Code)(Java Doc)
public void destroy()(Code)(Java Doc)
protected void destroyBeans()(Code)(Java Doc)
protected void doClose()(Code)(Java Doc)
public String[] getAliases(String name)(Code)(Java Doc)
public List getApplicationListeners()(Code)(Java Doc)
public AutowireCapableBeanFactory getAutowireCapableBeanFactory() throws IllegalStateException(Code)(Java Doc)
public Object getBean(String name) throws BeansException(Code)(Java Doc)
public Object getBean(String name, Class requiredType) throws BeansException(Code)(Java Doc)
public int getBeanDefinitionCount()(Code)(Java Doc)
public String[] getBeanDefinitionNames()(Code)(Java Doc)
abstract public ConfigurableListableBeanFactory getBeanFactory() throws IllegalStateException(Code)(Java Doc)
public List getBeanFactoryPostProcessors()(Code)(Java Doc)
public String[] getBeanNamesForType(Class type)(Code)(Java Doc)
public String[] getBeanNamesForType(Class type, boolean includePrototypes, boolean allowEagerInit)(Code)(Java Doc)
public Map getBeansOfType(Class type) throws BeansException(Code)(Java Doc)
public Map getBeansOfType(Class type, boolean includePrototypes, boolean allowEagerInit) throws BeansException(Code)(Java Doc)
public String getDisplayName()(Code)(Java Doc)
protected BeanFactory getInternalParentBeanFactory()(Code)(Java Doc)
protected MessageSource getInternalParentMessageSource()(Code)(Java Doc)
protected Collection getLifecycleBeans()(Code)(Java Doc)
public String getMessage(String code, Object args, String defaultMessage, Locale locale)(Code)(Java Doc)
public String getMessage(String code, Object args, Locale locale) throws NoSuchMessageException(Code)(Java Doc)
public String getMessage(MessageSourceResolvable resolvable, Locale locale) throws NoSuchMessageException(Code)(Java Doc)
public ApplicationContext getParent()(Code)(Java Doc)
public BeanFactory getParentBeanFactory()(Code)(Java Doc)
protected ResourcePatternResolver getResourcePatternResolver()(Code)(Java Doc)
public Resource[] getResources(String locationPattern) throws IOException(Code)(Java Doc)
public long getStartupDate()(Code)(Java Doc)
public Class getType(String name) throws NoSuchBeanDefinitionException(Code)(Java Doc)
protected void initApplicationEventMulticaster()(Code)(Java Doc)
protected void initMessageSource()(Code)(Java Doc)
protected void invokeBeanFactoryPostProcessors(ConfigurableListableBeanFactory beanFactory)(Code)(Java Doc)
public boolean isActive()(Code)(Java Doc)
public boolean isPrototype(String name) throws NoSuchBeanDefinitionException(Code)(Java Doc)
public boolean isRunning()(Code)(Java Doc)
public boolean isSingleton(String name) throws NoSuchBeanDefinitionException(Code)(Java Doc)
public boolean isTypeMatch(String name, Class targetType) throws NoSuchBeanDefinitionException(Code)(Java Doc)
protected ConfigurableListableBeanFactory obtainFreshBeanFactory()(Code)(Java Doc)
protected void onClose()(Code)(Java Doc)
protected void onRefresh() throws BeansException(Code)(Java Doc)
protected void postProcessBeanFactory(ConfigurableListableBeanFactory beanFactory)(Code)(Java Doc)
protected void prepareBeanFactory(ConfigurableListableBeanFactory beanFactory)(Code)(Java Doc)
protected void prepareRefresh()(Code)(Java Doc)
public void publishEvent(ApplicationEvent event)(Code)(Java Doc)
public void refresh() throws BeansException, IllegalStateException(Code)(Java Doc)
abstract protected void refreshBeanFactory() throws BeansException, IllegalStateException(Code)(Java Doc)
protected void registerBeanPostProcessors(ConfigurableListableBeanFactory beanFactory)(Code)(Java Doc)
protected void registerListeners()(Code)(Java Doc)
public void registerShutdownHook()(Code)(Java Doc)
public void setDisplayName(String displayName)(Code)(Java Doc)
public void setParent(ApplicationContext parent)(Code)(Java Doc)
public void start()(Code)(Java Doc)
public void stop()(Code)(Java Doc)
public String toString()(Code)(Java Doc)

www.java2java.com | Contact Us
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.