001    /**
002     * Copyright (c) 2000-2013 Liferay, Inc. All rights reserved.
003     *
004     * This library is free software; you can redistribute it and/or modify it under
005     * the terms of the GNU Lesser General Public License as published by the Free
006     * Software Foundation; either version 2.1 of the License, or (at your option)
007     * any later version.
008     *
009     * This library is distributed in the hope that it will be useful, but WITHOUT
010     * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
011     * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
012     * details.
013     */
014    
015    package com.liferay.portal.service;
016    
017    import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
018    import com.liferay.portal.kernel.util.ReferenceRegistry;
019    
020    /**
021     * The utility for the theme local service. This utility wraps {@link com.liferay.portal.service.impl.ThemeLocalServiceImpl} and is the primary access point for service operations in application layer code running on the local server.
022     *
023     * <p>
024     * This is a local service. Methods of this service will not have security checks based on the propagated JAAS credentials because this service can only be accessed from within the same VM.
025     * </p>
026     *
027     * @author Brian Wing Shun Chan
028     * @see ThemeLocalService
029     * @see com.liferay.portal.service.base.ThemeLocalServiceBaseImpl
030     * @see com.liferay.portal.service.impl.ThemeLocalServiceImpl
031     * @generated
032     */
033    public class ThemeLocalServiceUtil {
034            /*
035             * NOTE FOR DEVELOPERS:
036             *
037             * Never modify this class directly. Add custom service methods to {@link com.liferay.portal.service.impl.ThemeLocalServiceImpl} and rerun ServiceBuilder to regenerate this class.
038             */
039    
040            /**
041            * Returns the Spring bean ID for this bean.
042            *
043            * @return the Spring bean ID for this bean
044            */
045            public static java.lang.String getBeanIdentifier() {
046                    return getService().getBeanIdentifier();
047            }
048    
049            /**
050            * Sets the Spring bean ID for this bean.
051            *
052            * @param beanIdentifier the Spring bean ID for this bean
053            */
054            public static void setBeanIdentifier(java.lang.String beanIdentifier) {
055                    getService().setBeanIdentifier(beanIdentifier);
056            }
057    
058            public static com.liferay.portal.model.ColorScheme fetchColorScheme(
059                    long companyId, java.lang.String themeId, java.lang.String colorSchemeId) {
060                    return getService().fetchColorScheme(companyId, themeId, colorSchemeId);
061            }
062    
063            public static com.liferay.portal.model.Theme fetchTheme(long companyId,
064                    java.lang.String themeId) {
065                    return getService().fetchTheme(companyId, themeId);
066            }
067    
068            public static com.liferay.portal.model.ColorScheme getColorScheme(
069                    long companyId, java.lang.String themeId,
070                    java.lang.String colorSchemeId, boolean wapTheme)
071                    throws com.liferay.portal.kernel.exception.SystemException {
072                    return getService()
073                                       .getColorScheme(companyId, themeId, colorSchemeId, wapTheme);
074            }
075    
076            public static com.liferay.portal.model.Theme getTheme(long companyId,
077                    java.lang.String themeId, boolean wapTheme)
078                    throws com.liferay.portal.kernel.exception.SystemException {
079                    return getService().getTheme(companyId, themeId, wapTheme);
080            }
081    
082            public static java.util.List<com.liferay.portal.model.Theme> getThemes(
083                    long companyId) {
084                    return getService().getThemes(companyId);
085            }
086    
087            public static java.util.List<com.liferay.portal.model.Theme> getThemes(
088                    long companyId, long groupId, long userId, boolean wapTheme)
089                    throws com.liferay.portal.kernel.exception.SystemException {
090                    return getService().getThemes(companyId, groupId, userId, wapTheme);
091            }
092    
093            public static java.util.List<com.liferay.portal.model.Theme> getWARThemes() {
094                    return getService().getWARThemes();
095            }
096    
097            public static java.util.List<java.lang.String> init(
098                    javax.servlet.ServletContext servletContext,
099                    java.lang.String themesPath, boolean loadFromServletContext,
100                    java.lang.String[] xmls,
101                    com.liferay.portal.kernel.plugin.PluginPackage pluginPackage) {
102                    return getService()
103                                       .init(servletContext, themesPath, loadFromServletContext,
104                            xmls, pluginPackage);
105            }
106    
107            public static java.util.List<java.lang.String> init(
108                    java.lang.String servletContextName,
109                    javax.servlet.ServletContext servletContext,
110                    java.lang.String themesPath, boolean loadFromServletContext,
111                    java.lang.String[] xmls,
112                    com.liferay.portal.kernel.plugin.PluginPackage pluginPackage) {
113                    return getService()
114                                       .init(servletContextName, servletContext, themesPath,
115                            loadFromServletContext, xmls, pluginPackage);
116            }
117    
118            public static void uninstallThemes(
119                    java.util.List<java.lang.String> themeIds) {
120                    getService().uninstallThemes(themeIds);
121            }
122    
123            public static ThemeLocalService getService() {
124                    if (_service == null) {
125                            _service = (ThemeLocalService)PortalBeanLocatorUtil.locate(ThemeLocalService.class.getName());
126    
127                            ReferenceRegistry.registerReference(ThemeLocalServiceUtil.class,
128                                    "_service");
129                    }
130    
131                    return _service;
132            }
133    
134            /**
135             * @deprecated
136             */
137            public void setService(ThemeLocalService service) {
138            }
139    
140            private static ThemeLocalService _service;
141    }