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.portal.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 ResourceBlock. This utility wraps
024     * {@link com.liferay.portal.service.impl.ResourceBlockServiceImpl} 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 Brian Wing Shun Chan
031     * @see ResourceBlockService
032     * @see com.liferay.portal.service.base.ResourceBlockServiceBaseImpl
033     * @see com.liferay.portal.service.impl.ResourceBlockServiceImpl
034     * @generated
035     */
036    @ProviderType
037    public class ResourceBlockServiceUtil {
038            /*
039             * NOTE FOR DEVELOPERS:
040             *
041             * Never modify this class directly. Add custom service methods to {@link com.liferay.portal.service.impl.ResourceBlockServiceImpl} and rerun ServiceBuilder to regenerate this class.
042             */
043            public static void addCompanyScopePermission(long scopeGroupId,
044                    long companyId, java.lang.String name, long roleId,
045                    java.lang.String actionId)
046                    throws com.liferay.portal.kernel.exception.PortalException {
047                    getService()
048                            .addCompanyScopePermission(scopeGroupId, companyId, name, roleId,
049                            actionId);
050            }
051    
052            public static void addGroupScopePermission(long scopeGroupId,
053                    long companyId, long groupId, java.lang.String name, long roleId,
054                    java.lang.String actionId)
055                    throws com.liferay.portal.kernel.exception.PortalException {
056                    getService()
057                            .addGroupScopePermission(scopeGroupId, companyId, groupId, name,
058                            roleId, actionId);
059            }
060    
061            public static void addIndividualScopePermission(long companyId,
062                    long groupId, java.lang.String name, long primKey, long roleId,
063                    java.lang.String actionId)
064                    throws com.liferay.portal.kernel.exception.PortalException {
065                    getService()
066                            .addIndividualScopePermission(companyId, groupId, name, primKey,
067                            roleId, actionId);
068            }
069    
070            /**
071            * Returns the OSGi service identifier.
072            *
073            * @return the OSGi service identifier
074            */
075            public static java.lang.String getOSGiServiceIdentifier() {
076                    return getService().getOSGiServiceIdentifier();
077            }
078    
079            public static void removeAllGroupScopePermissions(long scopeGroupId,
080                    long companyId, java.lang.String name, long roleId,
081                    java.lang.String actionId)
082                    throws com.liferay.portal.kernel.exception.PortalException {
083                    getService()
084                            .removeAllGroupScopePermissions(scopeGroupId, companyId, name,
085                            roleId, actionId);
086            }
087    
088            public static void removeCompanyScopePermission(long scopeGroupId,
089                    long companyId, java.lang.String name, long roleId,
090                    java.lang.String actionId)
091                    throws com.liferay.portal.kernel.exception.PortalException {
092                    getService()
093                            .removeCompanyScopePermission(scopeGroupId, companyId, name,
094                            roleId, actionId);
095            }
096    
097            public static void removeGroupScopePermission(long scopeGroupId,
098                    long companyId, long groupId, java.lang.String name, long roleId,
099                    java.lang.String actionId)
100                    throws com.liferay.portal.kernel.exception.PortalException {
101                    getService()
102                            .removeGroupScopePermission(scopeGroupId, companyId, groupId, name,
103                            roleId, actionId);
104            }
105    
106            public static void removeIndividualScopePermission(long companyId,
107                    long groupId, java.lang.String name, long primKey, long roleId,
108                    java.lang.String actionId)
109                    throws com.liferay.portal.kernel.exception.PortalException {
110                    getService()
111                            .removeIndividualScopePermission(companyId, groupId, name, primKey,
112                            roleId, actionId);
113            }
114    
115            public static void setCompanyScopePermissions(long scopeGroupId,
116                    long companyId, java.lang.String name, long roleId,
117                    java.util.List<java.lang.String> actionIds)
118                    throws com.liferay.portal.kernel.exception.PortalException {
119                    getService()
120                            .setCompanyScopePermissions(scopeGroupId, companyId, name, roleId,
121                            actionIds);
122            }
123    
124            public static void setGroupScopePermissions(long scopeGroupId,
125                    long companyId, long groupId, java.lang.String name, long roleId,
126                    java.util.List<java.lang.String> actionIds)
127                    throws com.liferay.portal.kernel.exception.PortalException {
128                    getService()
129                            .setGroupScopePermissions(scopeGroupId, companyId, groupId, name,
130                            roleId, actionIds);
131            }
132    
133            public static void setIndividualScopePermissions(long companyId,
134                    long groupId, java.lang.String name, long primKey, long roleId,
135                    java.util.List<java.lang.String> actionIds)
136                    throws com.liferay.portal.kernel.exception.PortalException {
137                    getService()
138                            .setIndividualScopePermissions(companyId, groupId, name, primKey,
139                            roleId, actionIds);
140            }
141    
142            public static void setIndividualScopePermissions(long companyId,
143                    long groupId, java.lang.String name, long primKey,
144                    java.util.Map<java.lang.Long, java.lang.String[]> roleIdsToActionIds)
145                    throws com.liferay.portal.kernel.exception.PortalException {
146                    getService()
147                            .setIndividualScopePermissions(companyId, groupId, name, primKey,
148                            roleIdsToActionIds);
149            }
150    
151            public static ResourceBlockService getService() {
152                    if (_service == null) {
153                            _service = (ResourceBlockService)PortalBeanLocatorUtil.locate(ResourceBlockService.class.getName());
154    
155                            ReferenceRegistry.registerReference(ResourceBlockServiceUtil.class,
156                                    "_service");
157                    }
158    
159                    return _service;
160            }
161    
162            private static ResourceBlockService _service;
163    }