001    /**
002     * Copyright (c) 2000-present 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.portlet.mobiledevicerules.service;
016    
017    import aQute.bnd.annotation.ProviderType;
018    
019    import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
020    import com.liferay.portal.kernel.util.ReferenceRegistry;
021    
022    /**
023     * Provides the remote service utility for MDRRule. This utility wraps
024     * {@link com.liferay.portlet.mobiledevicerules.service.impl.MDRRuleServiceImpl} and is the
025     * primary access point for service operations in application layer code running
026     * on a remote server. Methods of this service are expected to have security
027     * checks based on the propagated JAAS credentials because this service can be
028     * accessed remotely.
029     *
030     * @author Edward C. Han
031     * @see MDRRuleService
032     * @see com.liferay.portlet.mobiledevicerules.service.base.MDRRuleServiceBaseImpl
033     * @see com.liferay.portlet.mobiledevicerules.service.impl.MDRRuleServiceImpl
034     * @generated
035     */
036    @ProviderType
037    public class MDRRuleServiceUtil {
038            /*
039             * NOTE FOR DEVELOPERS:
040             *
041             * Never modify this class directly. Add custom service methods to {@link com.liferay.portlet.mobiledevicerules.service.impl.MDRRuleServiceImpl} and rerun ServiceBuilder to regenerate this class.
042             */
043            public static com.liferay.portlet.mobiledevicerules.model.MDRRule addRule(
044                    long ruleGroupId,
045                    java.util.Map<java.util.Locale, java.lang.String> nameMap,
046                    java.util.Map<java.util.Locale, java.lang.String> descriptionMap,
047                    java.lang.String type,
048                    com.liferay.portal.kernel.util.UnicodeProperties typeSettings,
049                    com.liferay.portal.service.ServiceContext serviceContext)
050                    throws com.liferay.portal.kernel.exception.PortalException {
051                    return getService()
052                                       .addRule(ruleGroupId, nameMap, descriptionMap, type,
053                            typeSettings, serviceContext);
054            }
055    
056            public static com.liferay.portlet.mobiledevicerules.model.MDRRule addRule(
057                    long ruleGroupId,
058                    java.util.Map<java.util.Locale, java.lang.String> nameMap,
059                    java.util.Map<java.util.Locale, java.lang.String> descriptionMap,
060                    java.lang.String type, java.lang.String typeSettings,
061                    com.liferay.portal.service.ServiceContext serviceContext)
062                    throws com.liferay.portal.kernel.exception.PortalException {
063                    return getService()
064                                       .addRule(ruleGroupId, nameMap, descriptionMap, type,
065                            typeSettings, serviceContext);
066            }
067    
068            public static void deleteRule(long ruleId)
069                    throws com.liferay.portal.kernel.exception.PortalException {
070                    getService().deleteRule(ruleId);
071            }
072    
073            public static com.liferay.portlet.mobiledevicerules.model.MDRRule fetchRule(
074                    long ruleId) throws com.liferay.portal.kernel.exception.PortalException {
075                    return getService().fetchRule(ruleId);
076            }
077    
078            /**
079            * Returns the Spring bean ID for this bean.
080            *
081            * @return the Spring bean ID for this bean
082            */
083            public static java.lang.String getBeanIdentifier() {
084                    return getService().getBeanIdentifier();
085            }
086    
087            public static com.liferay.portlet.mobiledevicerules.model.MDRRule getRule(
088                    long ruleId) throws com.liferay.portal.kernel.exception.PortalException {
089                    return getService().getRule(ruleId);
090            }
091    
092            /**
093            * Sets the Spring bean ID for this bean.
094            *
095            * @param beanIdentifier the Spring bean ID for this bean
096            */
097            public static void setBeanIdentifier(java.lang.String beanIdentifier) {
098                    getService().setBeanIdentifier(beanIdentifier);
099            }
100    
101            public static com.liferay.portlet.mobiledevicerules.model.MDRRule updateRule(
102                    long ruleId, java.util.Map<java.util.Locale, java.lang.String> nameMap,
103                    java.util.Map<java.util.Locale, java.lang.String> descriptionMap,
104                    java.lang.String type, java.lang.String typeSettings,
105                    com.liferay.portal.service.ServiceContext serviceContext)
106                    throws com.liferay.portal.kernel.exception.PortalException {
107                    return getService()
108                                       .updateRule(ruleId, nameMap, descriptionMap, type,
109                            typeSettings, serviceContext);
110            }
111    
112            public static com.liferay.portlet.mobiledevicerules.model.MDRRule updateRule(
113                    long ruleId, java.util.Map<java.util.Locale, java.lang.String> nameMap,
114                    java.util.Map<java.util.Locale, java.lang.String> descriptionMap,
115                    java.lang.String type,
116                    com.liferay.portal.kernel.util.UnicodeProperties typeSettingsProperties,
117                    com.liferay.portal.service.ServiceContext serviceContext)
118                    throws com.liferay.portal.kernel.exception.PortalException {
119                    return getService()
120                                       .updateRule(ruleId, nameMap, descriptionMap, type,
121                            typeSettingsProperties, serviceContext);
122            }
123    
124            public static MDRRuleService getService() {
125                    if (_service == null) {
126                            _service = (MDRRuleService)PortalBeanLocatorUtil.locate(MDRRuleService.class.getName());
127    
128                            ReferenceRegistry.registerReference(MDRRuleServiceUtil.class,
129                                    "_service");
130                    }
131    
132                    return _service;
133            }
134    
135            /**
136             * @deprecated As of 6.2.0
137             */
138            @Deprecated
139            public void setService(MDRRuleService service) {
140            }
141    
142            private static MDRRuleService _service;
143    }