Class ApplicationContextHelper


  • @Deprecated
    public class ApplicationContextHelper
    extends org.alfresco.util.BaseApplicationContextHelper
    Deprecated.
    Helper class to provide static and common access to the Spring application context.

    Deprecated. It is better to use Spring annotations to define the application context to use in tests, see org.alfresco.util.BaseSpringTest

    Author:
    Derek Hulley
    • Nested Class Summary

      • Nested classes/interfaces inherited from class org.alfresco.util.BaseApplicationContextHelper

        org.alfresco.util.BaseApplicationContextHelper.ResourceFinder, org.alfresco.util.BaseApplicationContextHelper.VariableFeatureClassPathXmlApplicationContext
    • Field Summary

      Fields 
      Modifier and Type Field Description
      static java.lang.String[] CONFIG_LOCATIONS
      Deprecated.
      location of required configuration files
    • Method Summary

      All Methods Static Methods Concrete Methods Deprecated Methods 
      Modifier and Type Method Description
      static org.springframework.context.ApplicationContext getApplicationContext()
      Deprecated.
      Provides a static, single instance of the default Alfresco application context.
      static org.springframework.context.ApplicationContext getApplicationContext​(java.lang.String[] configLocations)
      Deprecated.
      Provides a static, single instance of an application context represented by the given array of config locations.
      static void main​(java.lang.String... args)
      Deprecated.
       
      • Methods inherited from class org.alfresco.util.BaseApplicationContextHelper

        buildClassLoader, closeApplicationContext, getApplicationContext, isContextLoaded, isNoAutoStart, isUsingLazyLoading, setNoAutoStart, setUseLazyLoading
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • CONFIG_LOCATIONS

        public static final java.lang.String[] CONFIG_LOCATIONS
        Deprecated.
        location of required configuration files
    • Constructor Detail

      • ApplicationContextHelper

        public ApplicationContextHelper()
        Deprecated.
    • Method Detail

      • getApplicationContext

        public static org.springframework.context.ApplicationContext getApplicationContext()
        Deprecated.
        Provides a static, single instance of the default Alfresco application context. This method can be called repeatedly.

        If the configuration requested differs from one used previously, then the previously-created context is shut down.

        Returns:
        Returns an application context for the default Alfresco configuration
      • getApplicationContext

        public static org.springframework.context.ApplicationContext getApplicationContext​(java.lang.String[] configLocations)
        Deprecated.
        Provides a static, single instance of an application context represented by the given array of config locations. This method can be called repeatedly.

        If the configuration requested differs from one used previously, then the previously-created context is shut down.

        Returns:
        Returns an application context for the given config locations
      • main

        public static void main​(java.lang.String... args)
        Deprecated.