|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.springframework.richclient.application.ProgressMonitoringBeanFactoryPostProcessor
public class ProgressMonitoringBeanFactoryPostProcessor
A BeanFactoryPostProcessor
that notifies a specified
ProgressMonitor
of progress made while loading a bean factory.
The messages sent to the progress monitor can be internationalized by
providing a MessageSource
to the constructor of this class. Note that
if a MessageSource
is provided it must already be initialized in
order for it to successfully retrieve messages.
The progress monitor will be notified once prior to initializing the beans in the bean factory and once for each singleton bean before it is initialized. The message keys used to find these messages are "progress.loading.applicationContext" and "progress.loading.bean". If the message source is unable to find any messages under these keys, or if no message source is provided, default messages (in English) will be used instead.
ProgressMonitor
Field Summary | |
---|---|
static String |
LOADING_APP_CONTEXT_KEY
The message key used to retrieve the message to be sent to the progress monitor when the application context begins loading. |
static String |
LOADING_BEAN_KEY
The message key used to retrieve the message to be sent to the progress monitor for each bean that is loaded. |
Constructor Summary | |
---|---|
ProgressMonitoringBeanFactoryPostProcessor(ProgressMonitor progressMonitor,
MessageSource messageSource)
Creates a new ProgressMonitoringBeanFactoryPostProcessor that
will report the progress of loading the beans in a bean factory to the
given progress monitor, optionally providing internationalized messages. |
Method Summary | |
---|---|
void |
postProcessBeanFactory(ConfigurableListableBeanFactory beanFactory)
Notifies this instance's associated progress monitor of progress made while processing the given bean factory. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String LOADING_APP_CONTEXT_KEY
public static final String LOADING_BEAN_KEY
Constructor Detail |
---|
public ProgressMonitoringBeanFactoryPostProcessor(ProgressMonitor progressMonitor, MessageSource messageSource)
ProgressMonitoringBeanFactoryPostProcessor
that
will report the progress of loading the beans in a bean factory to the
given progress monitor, optionally providing internationalized messages.
progressMonitor
- The progress monitor that will be notified of
progress while processing the bean factory.messageSource
- The message source that will be used to resolve
messages to be displayed by the progress monitor. May be null.
IllegalArgumentException
- if progressMonitor
is null.Method Detail |
---|
public void postProcessBeanFactory(ConfigurableListableBeanFactory beanFactory) throws BeansException
postProcessBeanFactory
in interface BeanFactoryPostProcessor
beanFactory
- the bean factory that is to be processed.
BeansException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |