Class ComponentsLoader


  • public class ComponentsLoader
    extends Object

    Load the available Sakai components into the shared component manager's Spring ApplicationContext

    • Constructor Detail

      • ComponentsLoader

        public ComponentsLoader()
      • ComponentsLoader

        public ComponentsLoader​(File overridesFolder)
    • Method Detail

      • load

        public void load​(org.springframework.context.ConfigurableApplicationContext ac,
                         String componentsRoot)
      • loadComponentPackage

        protected void loadComponentPackage​(File dir,
                                            org.springframework.context.ConfigurableApplicationContext ac)
        Load one component package into the AC
        Parameters:
        dir - The file path to the component package
        ac - The ApplicationContext to load into
      • validComponentsPackage

        protected boolean validComponentsPackage​(File dir)
        Test if this File is a valid components package directory.
        Parameters:
        dir - The file to test
        Returns:
        true if it is a valid components package directory, false if not.
      • newPackageClassLoader

        protected ClassLoader newPackageClassLoader​(File dir)
        Create the class loader for this component package
        Parameters:
        dir - The package's root directory.
        Returns:
        A class loader, whose parent is this class's loader, which has the classes/ and jars for this component.