Example usage for org.springframework.context.support LiveBeansView registerApplicationContext

List of usage examples for org.springframework.context.support LiveBeansView registerApplicationContext

Introduction

In this page you can find the example usage for org.springframework.context.support LiveBeansView registerApplicationContext.

Prototype

static void registerApplicationContext(ConfigurableApplicationContext applicationContext) 

Source Link

Usage

From source file:org.springframework.context.support.AbstractApplicationContext.java

/**
 * Finish the refresh of this context, invoking the LifecycleProcessor's
 * onRefresh() method and publishing the
 * {@link org.springframework.context.event.ContextRefreshedEvent}.
 *///from  w  w  w  .j a  v  a2s  .c  om
protected void finishRefresh() {
    // Clear context-level resource caches (such as ASM metadata from scanning).
    clearResourceCaches();

    // Initialize lifecycle processor for this context.
    initLifecycleProcessor();

    // Propagate refresh to lifecycle processor first.
    getLifecycleProcessor().onRefresh();

    // Publish the final event.
    publishEvent(new ContextRefreshedEvent(this));

    // Participate in LiveBeansView MBean, if active.
    LiveBeansView.registerApplicationContext(this);
}