Home » Spring-Framework-090522 » org.springframework » context » [javadoc | source]
org.springframework.context
public interface: ApplicationContext [javadoc | source]

All Implemented Interfaces:
    MessageSource, ApplicationEventPublisher, ListableBeanFactory, ResourcePatternResolver, HierarchicalBeanFactory

All Known Implementing Classes:
    ResourceAdapterApplicationContext, ConfigurableApplicationContext, AbstractXmlApplicationContext, GenericApplicationContext, AbstractRefreshableWebApplicationContext, XmlPortletApplicationContext, XmlWebApplicationContext, StaticApplicationContext, StaticPortletApplicationContext, GenericWebApplicationContext, AbstractApplicationContext, WebApplicationContext, ClassPathXmlApplicationContext, AbstractRefreshablePortletApplicationContext, AbstractRefreshableApplicationContext, StaticWebApplicationContext, ConfigurablePortletApplicationContext, AbstractRefreshableConfigApplicationContext, ConfigurableWebApplicationContext, FileSystemXmlApplicationContext

Central interface to provide configuration for an application. This is read-only while the application is running, but may be reloaded if the implementation supports this.

An ApplicationContext provides:

In addition to standard org.springframework.beans.factory.BeanFactory lifecycle capabilities, ApplicationContext implementations detect and invoke ApplicationContextAware beans as well as ResourceLoaderAware , ApplicationEventPublisherAware and MessageSourceAware beans.

Method from org.springframework.context.ApplicationContext Summary:
getAutowireCapableBeanFactory,   getDisplayName,   getId,   getParent,   getStartupDate
Method from org.springframework.context.ApplicationContext Detail:
 public AutowireCapableBeanFactory getAutowireCapableBeanFactory() throws IllegalStateException
    Expose AutowireCapableBeanFactory functionality for this context.

    This is not typically used by application code, except for the purpose of initializing bean instances that live outside the application context, applying the Spring bean lifecycle (fully or partly) to them.

    Alternatively, the internal BeanFactory exposed by the ConfigurableApplicationContext interface offers access to the AutowireCapableBeanFactory interface too. The present method mainly serves as convenient, specific facility on the ApplicationContext interface itself.

 public String getDisplayName()
    Return a friendly name for this context.
 public String getId()
    Return the unique id of this application context.
 public ApplicationContext getParent()
    Return the parent context, or null if there is no parent and this is the root of the context hierarchy.
 public long getStartupDate()
    Return the timestamp when this context was first loaded.