Class ThemeUtil


  • public class ThemeUtil
    extends Object
    • Constructor Detail

      • ThemeUtil

        public ThemeUtil()
    • Method Detail

      • setRegistryService

        public static void setRegistryService​(org.wso2.carbon.registry.core.service.RegistryService service)
      • getRegistryService

        public static org.wso2.carbon.registry.core.service.RegistryService getRegistryService()
      • setRealmService

        public static void setRealmService​(org.wso2.carbon.user.core.service.RealmService service)
      • getRealmService

        public static org.wso2.carbon.user.core.service.RealmService getRealmService()
      • getThemeMgtSystemRegistry

        public static org.wso2.carbon.registry.core.session.UserRegistry getThemeMgtSystemRegistry​(String tenantPass)
                                                                                            throws org.wso2.carbon.registry.core.exceptions.RegistryException
        Throws:
        org.wso2.carbon.registry.core.exceptions.RegistryException
      • removeTheUUID

        public static void removeTheUUID​(String tenantPass)
                                  throws org.wso2.carbon.registry.core.exceptions.RegistryException
        Throws:
        org.wso2.carbon.registry.core.exceptions.RegistryException
      • transferAllThemesToRegistry

        public static void transferAllThemesToRegistry​(File rootDirectory,
                                                       org.wso2.carbon.registry.core.Registry registry,
                                                       String registryPath)
                                                throws org.wso2.carbon.registry.core.exceptions.RegistryException
        Throws:
        org.wso2.carbon.registry.core.exceptions.RegistryException
      • getThemeRegistryFromTenantPass

        public static org.wso2.carbon.registry.core.session.UserRegistry getThemeRegistryFromTenantPass​(String tenantPass)
                                                                                                 throws org.wso2.carbon.registry.core.exceptions.RegistryException
        Throws:
        org.wso2.carbon.registry.core.exceptions.RegistryException
      • getThemeRegistry

        public static org.wso2.carbon.registry.core.session.UserRegistry getThemeRegistry​(org.wso2.carbon.registry.core.Registry registry)
                                                                                   throws org.wso2.carbon.registry.core.exceptions.RegistryException
        Throws:
        org.wso2.carbon.registry.core.exceptions.RegistryException
      • loadResourceThemes

        public static void loadResourceThemes()
                                       throws org.wso2.carbon.registry.core.exceptions.RegistryException
        Throws:
        org.wso2.carbon.registry.core.exceptions.RegistryException
      • getAvailableThemes

        public static String[] getAvailableThemes()
                                           throws org.wso2.carbon.registry.core.exceptions.RegistryException
        Throws:
        org.wso2.carbon.registry.core.exceptions.RegistryException
      • loadTheme

        public static void loadTheme​(int tenantId)
                              throws org.wso2.carbon.registry.core.exceptions.RegistryException
        Throws:
        org.wso2.carbon.registry.core.exceptions.RegistryException
      • applyTheme

        public static void applyTheme​(String themeName,
                                      String tenantPass,
                                      org.wso2.carbon.registry.core.session.UserRegistry systemTenantRegistry)
                               throws Exception
        Throws:
        Exception
      • applyThemeForDomain

        public static void applyThemeForDomain​(String themeName,
                                               org.wso2.carbon.registry.core.session.UserRegistry systemTenantRegistry)
                                        throws org.wso2.carbon.registry.core.exceptions.RegistryException
        Throws:
        org.wso2.carbon.registry.core.exceptions.RegistryException
      • getCurrentTheme

        public static String getCurrentTheme​(String tenantPass,
                                             org.wso2.carbon.registry.core.session.UserRegistry registry)
                                      throws Exception
        Throws:
        Exception