Class ApplicationContextHolder

java.lang.Object
org.hawaiiframework.context.ApplicationContextHolder

public final class ApplicationContextHolder extends Object
Utility class to obtain Spring's application context.
Since:
2.0.0
  • Method Details

    • getRequiredApplicationContext

      public static org.springframework.context.ApplicationContext getRequiredApplicationContext()
      Get the application context, or throw an IllegalStateException.
    • getApplicationContext

      public static org.springframework.context.ApplicationContext getApplicationContext()
      Get the application context, or return null.
    • bind

      public static void bind(org.springframework.context.ApplicationContext context)
      Binds the ApplicationContext to the current context class loader.
      Parameters:
      context - the application context to bind
    • release

      public static void release()
      Releases the ApplicationContext associated with the current context class loader.