Class PackageHelper


  • public class PackageHelper
    extends Object
    • Field Detail

      • CONFIG_MANAGER_CLASS

        public static String CONFIG_MANAGER_CLASS
      • MODULE_MANAGER_CLASS

        public static String MODULE_MANAGER_CLASS
      • PANEL_MANAGER_CLASS

        public static String PANEL_MANAGER_CLASS
      • MODULE_CLASS

        public static String MODULE_CLASS
      • DATA_PATH

        public static String DATA_PATH
      • SERVICE_PATH

        public static String SERVICE_PATH
      • MODULE_MANAGER_PATH

        public static String MODULE_MANAGER_PATH
      • MODULE_PACKAGE

        public static String MODULE_PACKAGE
      • CONFIG_MANAGER_PATH

        public static String CONFIG_MANAGER_PATH
    • Constructor Detail

      • PackageHelper

        public PackageHelper()
    • Method Detail

      • getModuleName

        public static String getModuleName​(String element)
        gets module name. eg. module.android.LoginPanel with return android
        Parameters:
        element -
        Returns:
      • getPackagePath

        public static String getPackagePath​(String element)
      • getRootPath

        public static String getRootPath​(String path)
        path: module.android.panel
        Parameters:
        path -
        Returns:
        "module"
      • getAppName

        public static String getAppName​(Element element)
      • getFirstModuleFullPath

        public static String getFirstModuleFullPath​(Map<String,​List<String>> panelMap)
        gets the full path of the first module eg. module.android.panel
        Parameters:
        panelMap -
        Returns:
      • getModuleFromFullPath

        public static String getModuleFromFullPath​(File file)
        returns the module name from the file path module is directory after "module" directory eg. module.webapp.data.user.csv will return webapp outside module: data.user.csv will return data
        Returns:
      • getModuleList

        public static Set<String> getModuleList​(List<File> files)
        gets the list of modules that have csv data files
        Parameters:
        files -
        Returns:
      • hasPackagePath

        public static boolean hasPackagePath​(String value)
        returns true if package path is contained in the name eg. module.common.data.user
        Parameters:
        value -
        Returns:
      • getClassName

        public static String getClassName​(String classPath)
        gets class name from path eg. module.common.data.user returns user
        Parameters:
        classPath -
        Returns: