001    /**
002     * Copyright (c) 2000-2012 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.MethodCache;
019    import com.liferay.portal.kernel.util.ReferenceRegistry;
020    
021    /**
022     * The utility for the resource block local service. This utility wraps {@link com.liferay.portal.service.impl.ResourceBlockLocalServiceImpl} and is the primary access point for service operations in application layer code running on the local server.
023     *
024     * <p>
025     * 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.
026     * </p>
027     *
028     * @author Brian Wing Shun Chan
029     * @see ResourceBlockLocalService
030     * @see com.liferay.portal.service.base.ResourceBlockLocalServiceBaseImpl
031     * @see com.liferay.portal.service.impl.ResourceBlockLocalServiceImpl
032     * @generated
033     */
034    public class ResourceBlockLocalServiceUtil {
035            /*
036             * NOTE FOR DEVELOPERS:
037             *
038             * Never modify this class directly. Add custom service methods to {@link com.liferay.portal.service.impl.ResourceBlockLocalServiceImpl} and rerun ServiceBuilder to regenerate this class.
039             */
040    
041            /**
042            * Adds the resource block to the database. Also notifies the appropriate model listeners.
043            *
044            * @param resourceBlock the resource block
045            * @return the resource block that was added
046            * @throws SystemException if a system exception occurred
047            */
048            public static com.liferay.portal.model.ResourceBlock addResourceBlock(
049                    com.liferay.portal.model.ResourceBlock resourceBlock)
050                    throws com.liferay.portal.kernel.exception.SystemException {
051                    return getService().addResourceBlock(resourceBlock);
052            }
053    
054            /**
055            * Creates a new resource block with the primary key. Does not add the resource block to the database.
056            *
057            * @param resourceBlockId the primary key for the new resource block
058            * @return the new resource block
059            */
060            public static com.liferay.portal.model.ResourceBlock createResourceBlock(
061                    long resourceBlockId) {
062                    return getService().createResourceBlock(resourceBlockId);
063            }
064    
065            /**
066            * Deletes the resource block with the primary key from the database. Also notifies the appropriate model listeners.
067            *
068            * @param resourceBlockId the primary key of the resource block
069            * @throws PortalException if a resource block with the primary key could not be found
070            * @throws SystemException if a system exception occurred
071            */
072            public static void deleteResourceBlock(long resourceBlockId)
073                    throws com.liferay.portal.kernel.exception.PortalException,
074                            com.liferay.portal.kernel.exception.SystemException {
075                    getService().deleteResourceBlock(resourceBlockId);
076            }
077    
078            /**
079            * Deletes the resource block from the database. Also notifies the appropriate model listeners.
080            *
081            * @param resourceBlock the resource block
082            * @throws SystemException if a system exception occurred
083            */
084            public static void deleteResourceBlock(
085                    com.liferay.portal.model.ResourceBlock resourceBlock)
086                    throws com.liferay.portal.kernel.exception.SystemException {
087                    getService().deleteResourceBlock(resourceBlock);
088            }
089    
090            /**
091            * Performs a dynamic query on the database and returns the matching rows.
092            *
093            * @param dynamicQuery the dynamic query
094            * @return the matching rows
095            * @throws SystemException if a system exception occurred
096            */
097            @SuppressWarnings("rawtypes")
098            public static java.util.List dynamicQuery(
099                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
100                    throws com.liferay.portal.kernel.exception.SystemException {
101                    return getService().dynamicQuery(dynamicQuery);
102            }
103    
104            /**
105            * Performs a dynamic query on the database and returns a range of the matching rows.
106            *
107            * <p>
108            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
109            * </p>
110            *
111            * @param dynamicQuery the dynamic query
112            * @param start the lower bound of the range of model instances
113            * @param end the upper bound of the range of model instances (not inclusive)
114            * @return the range of matching rows
115            * @throws SystemException if a system exception occurred
116            */
117            @SuppressWarnings("rawtypes")
118            public static java.util.List dynamicQuery(
119                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
120                    int end) throws com.liferay.portal.kernel.exception.SystemException {
121                    return getService().dynamicQuery(dynamicQuery, start, end);
122            }
123    
124            /**
125            * Performs a dynamic query on the database and returns an ordered range of the matching rows.
126            *
127            * <p>
128            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
129            * </p>
130            *
131            * @param dynamicQuery the dynamic query
132            * @param start the lower bound of the range of model instances
133            * @param end the upper bound of the range of model instances (not inclusive)
134            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
135            * @return the ordered range of matching rows
136            * @throws SystemException if a system exception occurred
137            */
138            @SuppressWarnings("rawtypes")
139            public static java.util.List dynamicQuery(
140                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
141                    int end,
142                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
143                    throws com.liferay.portal.kernel.exception.SystemException {
144                    return getService()
145                                       .dynamicQuery(dynamicQuery, start, end, orderByComparator);
146            }
147    
148            /**
149            * Returns the number of rows that match the dynamic query.
150            *
151            * @param dynamicQuery the dynamic query
152            * @return the number of rows that match the dynamic query
153            * @throws SystemException if a system exception occurred
154            */
155            public static long dynamicQueryCount(
156                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
157                    throws com.liferay.portal.kernel.exception.SystemException {
158                    return getService().dynamicQueryCount(dynamicQuery);
159            }
160    
161            public static com.liferay.portal.model.ResourceBlock fetchResourceBlock(
162                    long resourceBlockId)
163                    throws com.liferay.portal.kernel.exception.SystemException {
164                    return getService().fetchResourceBlock(resourceBlockId);
165            }
166    
167            /**
168            * Returns the resource block with the primary key.
169            *
170            * @param resourceBlockId the primary key of the resource block
171            * @return the resource block
172            * @throws PortalException if a resource block with the primary key could not be found
173            * @throws SystemException if a system exception occurred
174            */
175            public static com.liferay.portal.model.ResourceBlock getResourceBlock(
176                    long resourceBlockId)
177                    throws com.liferay.portal.kernel.exception.PortalException,
178                            com.liferay.portal.kernel.exception.SystemException {
179                    return getService().getResourceBlock(resourceBlockId);
180            }
181    
182            public static com.liferay.portal.model.PersistedModel getPersistedModel(
183                    java.io.Serializable primaryKeyObj)
184                    throws com.liferay.portal.kernel.exception.PortalException,
185                            com.liferay.portal.kernel.exception.SystemException {
186                    return getService().getPersistedModel(primaryKeyObj);
187            }
188    
189            /**
190            * Returns a range of all the resource blocks.
191            *
192            * <p>
193            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
194            * </p>
195            *
196            * @param start the lower bound of the range of resource blocks
197            * @param end the upper bound of the range of resource blocks (not inclusive)
198            * @return the range of resource blocks
199            * @throws SystemException if a system exception occurred
200            */
201            public static java.util.List<com.liferay.portal.model.ResourceBlock> getResourceBlocks(
202                    int start, int end)
203                    throws com.liferay.portal.kernel.exception.SystemException {
204                    return getService().getResourceBlocks(start, end);
205            }
206    
207            /**
208            * Returns the number of resource blocks.
209            *
210            * @return the number of resource blocks
211            * @throws SystemException if a system exception occurred
212            */
213            public static int getResourceBlocksCount()
214                    throws com.liferay.portal.kernel.exception.SystemException {
215                    return getService().getResourceBlocksCount();
216            }
217    
218            /**
219            * Updates the resource block in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.
220            *
221            * @param resourceBlock the resource block
222            * @return the resource block that was updated
223            * @throws SystemException if a system exception occurred
224            */
225            public static com.liferay.portal.model.ResourceBlock updateResourceBlock(
226                    com.liferay.portal.model.ResourceBlock resourceBlock)
227                    throws com.liferay.portal.kernel.exception.SystemException {
228                    return getService().updateResourceBlock(resourceBlock);
229            }
230    
231            /**
232            * Updates the resource block in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.
233            *
234            * @param resourceBlock the resource block
235            * @param merge whether to merge the resource block with the current session. See {@link com.liferay.portal.service.persistence.BatchSession#update(com.liferay.portal.kernel.dao.orm.Session, com.liferay.portal.model.BaseModel, boolean)} for an explanation.
236            * @return the resource block that was updated
237            * @throws SystemException if a system exception occurred
238            */
239            public static com.liferay.portal.model.ResourceBlock updateResourceBlock(
240                    com.liferay.portal.model.ResourceBlock resourceBlock, boolean merge)
241                    throws com.liferay.portal.kernel.exception.SystemException {
242                    return getService().updateResourceBlock(resourceBlock, merge);
243            }
244    
245            /**
246            * Returns the Spring bean ID for this bean.
247            *
248            * @return the Spring bean ID for this bean
249            */
250            public static java.lang.String getBeanIdentifier() {
251                    return getService().getBeanIdentifier();
252            }
253    
254            /**
255            * Sets the Spring bean ID for this bean.
256            *
257            * @param beanIdentifier the Spring bean ID for this bean
258            */
259            public static void setBeanIdentifier(java.lang.String beanIdentifier) {
260                    getService().setBeanIdentifier(beanIdentifier);
261            }
262    
263            public static void addCompanyScopePermission(long companyId,
264                    java.lang.String name, long roleId, java.lang.String actionId)
265                    throws com.liferay.portal.kernel.exception.PortalException,
266                            com.liferay.portal.kernel.exception.SystemException {
267                    getService().addCompanyScopePermission(companyId, name, roleId, actionId);
268            }
269    
270            public static void addCompanyScopePermissions(long companyId,
271                    java.lang.String name, long roleId, long actionIdsLong)
272                    throws com.liferay.portal.kernel.exception.SystemException {
273                    getService()
274                            .addCompanyScopePermissions(companyId, name, roleId, actionIdsLong);
275            }
276    
277            public static void addGroupScopePermission(long companyId, long groupId,
278                    java.lang.String name, long roleId, java.lang.String actionId)
279                    throws com.liferay.portal.kernel.exception.PortalException,
280                            com.liferay.portal.kernel.exception.SystemException {
281                    getService()
282                            .addGroupScopePermission(companyId, groupId, name, roleId, actionId);
283            }
284    
285            public static void addGroupScopePermissions(long companyId, long groupId,
286                    java.lang.String name, long roleId, long actionIdsLong)
287                    throws com.liferay.portal.kernel.exception.SystemException {
288                    getService()
289                            .addGroupScopePermissions(companyId, groupId, name, roleId,
290                            actionIdsLong);
291            }
292    
293            public static void addIndividualScopePermission(long companyId,
294                    long groupId, java.lang.String name, long primKey, long roleId,
295                    java.lang.String actionId)
296                    throws com.liferay.portal.kernel.exception.PortalException,
297                            com.liferay.portal.kernel.exception.SystemException {
298                    getService()
299                            .addIndividualScopePermission(companyId, groupId, name, primKey,
300                            roleId, actionId);
301            }
302    
303            public static void addIndividualScopePermission(long companyId,
304                    long groupId, java.lang.String name,
305                    com.liferay.portal.model.PermissionedModel permissionedModel,
306                    long roleId, java.lang.String actionId)
307                    throws com.liferay.portal.kernel.exception.PortalException,
308                            com.liferay.portal.kernel.exception.SystemException {
309                    getService()
310                            .addIndividualScopePermission(companyId, groupId, name,
311                            permissionedModel, roleId, actionId);
312            }
313    
314            public static void addIndividualScopePermissions(long companyId,
315                    long groupId, java.lang.String name, long primKey, long roleId,
316                    long actionIdsLong)
317                    throws com.liferay.portal.kernel.exception.PortalException,
318                            com.liferay.portal.kernel.exception.SystemException {
319                    getService()
320                            .addIndividualScopePermissions(companyId, groupId, name, primKey,
321                            roleId, actionIdsLong);
322            }
323    
324            public static void addIndividualScopePermissions(long companyId,
325                    long groupId, java.lang.String name,
326                    com.liferay.portal.model.PermissionedModel permissionedModel,
327                    long roleId, long actionIdsLong)
328                    throws com.liferay.portal.kernel.exception.SystemException {
329                    getService()
330                            .addIndividualScopePermissions(companyId, groupId, name,
331                            permissionedModel, roleId, actionIdsLong);
332            }
333    
334            /**
335            * Adds a resource block if necessary and associates the resource block
336            * permissions with it. The resource block will have an initial reference
337            * count of one.
338            *
339            * @param companyId the primary key of the resource block's company
340            * @param groupId the primary key of the resource block's group
341            * @return the new resource block
342            * @throws SystemException if a system exception occurred
343            */
344            public static com.liferay.portal.model.ResourceBlock addResourceBlock(
345                    long companyId, long groupId, java.lang.String name,
346                    java.lang.String permissionsHash,
347                    com.liferay.portal.model.ResourceBlockPermissionsContainer resourceBlockPermissionsContainer)
348                    throws com.liferay.portal.kernel.exception.SystemException {
349                    return getService()
350                                       .addResourceBlock(companyId, groupId, name, permissionsHash,
351                            resourceBlockPermissionsContainer);
352            }
353    
354            public static long getActionId(java.lang.String name,
355                    java.lang.String actionId)
356                    throws com.liferay.portal.kernel.exception.PortalException {
357                    return getService().getActionId(name, actionId);
358            }
359    
360            public static long getActionIds(java.lang.String name,
361                    java.util.List<java.lang.String> actionIds)
362                    throws com.liferay.portal.kernel.exception.PortalException {
363                    return getService().getActionIds(name, actionIds);
364            }
365    
366            public static java.util.List<java.lang.String> getActionIds(
367                    java.lang.String name, long actionIdsLong)
368                    throws com.liferay.portal.kernel.exception.SystemException {
369                    return getService().getActionIds(name, actionIdsLong);
370            }
371    
372            public static java.util.List<java.lang.String> getCompanyScopePermissions(
373                    com.liferay.portal.model.ResourceBlock resourceBlock, long roleId)
374                    throws com.liferay.portal.kernel.exception.SystemException {
375                    return getService().getCompanyScopePermissions(resourceBlock, roleId);
376            }
377    
378            public static java.util.List<java.lang.String> getGroupScopePermissions(
379                    com.liferay.portal.model.ResourceBlock resourceBlock, long roleId)
380                    throws com.liferay.portal.kernel.exception.SystemException {
381                    return getService().getGroupScopePermissions(resourceBlock, roleId);
382            }
383    
384            public static com.liferay.portal.model.PermissionedModel getPermissionedModel(
385                    java.lang.String name, long primKey)
386                    throws com.liferay.portal.kernel.exception.PortalException,
387                            com.liferay.portal.kernel.exception.SystemException {
388                    return getService().getPermissionedModel(name, primKey);
389            }
390    
391            public static java.util.List<java.lang.String> getPermissions(
392                    com.liferay.portal.model.ResourceBlock resourceBlock, long roleId)
393                    throws com.liferay.portal.kernel.exception.SystemException {
394                    return getService().getPermissions(resourceBlock, roleId);
395            }
396    
397            /**
398            * Returns the permissions hash of the resource permissions. The permissions
399            * hash is a representation of all the roles with access to the resource
400            * along with the actions they can perform.
401            *
402            * @param resourceBlockPermissionsContainer the resource block permissions
403            * @return the permissions hash of the resource permissions
404            */
405            public static java.lang.String getPermissionsHash(
406                    com.liferay.portal.model.ResourceBlockPermissionsContainer resourceBlockPermissionsContainer) {
407                    return getService().getPermissionsHash(resourceBlockPermissionsContainer);
408            }
409    
410            public static com.liferay.portal.model.ResourceBlock getResourceBlock(
411                    java.lang.String name, long primKey)
412                    throws com.liferay.portal.kernel.exception.PortalException,
413                            com.liferay.portal.kernel.exception.SystemException {
414                    return getService().getResourceBlock(name, primKey);
415            }
416    
417            public static java.util.List<java.lang.Long> getResourceBlockIds(
418                    com.liferay.portal.security.permission.ResourceBlockIdsBag resourceBlockIdsBag,
419                    java.lang.String name, java.lang.String actionId)
420                    throws com.liferay.portal.kernel.exception.PortalException {
421                    return getService()
422                                       .getResourceBlockIds(resourceBlockIdsBag, name, actionId);
423            }
424    
425            public static com.liferay.portal.security.permission.ResourceBlockIdsBag getResourceBlockIdsBag(
426                    long companyId, long groupId, java.lang.String name, long[] roleIds)
427                    throws com.liferay.portal.kernel.exception.SystemException {
428                    return getService()
429                                       .getResourceBlockIdsBag(companyId, groupId, name, roleIds);
430            }
431    
432            public static boolean hasPermission(java.lang.String name, long primKey,
433                    java.lang.String actionId,
434                    com.liferay.portal.security.permission.ResourceBlockIdsBag resourceBlockIdsBag)
435                    throws com.liferay.portal.kernel.exception.PortalException,
436                            com.liferay.portal.kernel.exception.SystemException {
437                    return getService()
438                                       .hasPermission(name, primKey, actionId, resourceBlockIdsBag);
439            }
440    
441            public static boolean hasPermission(java.lang.String name,
442                    com.liferay.portal.model.PermissionedModel permissionedModel,
443                    java.lang.String actionId,
444                    com.liferay.portal.security.permission.ResourceBlockIdsBag resourceBlockIdsBag)
445                    throws com.liferay.portal.kernel.exception.PortalException {
446                    return getService()
447                                       .hasPermission(name, permissionedModel, actionId,
448                            resourceBlockIdsBag);
449            }
450    
451            public static boolean isSupported(java.lang.String name) {
452                    return getService().isSupported(name);
453            }
454    
455            public static void releasePermissionedModelResourceBlock(
456                    com.liferay.portal.model.PermissionedModel permissionedModel)
457                    throws com.liferay.portal.kernel.exception.PortalException,
458                            com.liferay.portal.kernel.exception.SystemException {
459                    getService().releasePermissionedModelResourceBlock(permissionedModel);
460            }
461    
462            public static void releasePermissionedModelResourceBlock(
463                    java.lang.String name, long primKey)
464                    throws com.liferay.portal.kernel.exception.PortalException,
465                            com.liferay.portal.kernel.exception.SystemException {
466                    getService().releasePermissionedModelResourceBlock(name, primKey);
467            }
468    
469            /**
470            * Decrements the reference count of the resource block and updates it in
471            * the database or deletes the resource block if the reference count reaches
472            * zero.
473            *
474            * @param resourceBlockId the primary key of the resource block
475            * @throws SystemException if a system exception occurred
476            */
477            public static void releaseResourceBlock(long resourceBlockId)
478                    throws com.liferay.portal.kernel.exception.PortalException,
479                            com.liferay.portal.kernel.exception.SystemException {
480                    getService().releaseResourceBlock(resourceBlockId);
481            }
482    
483            /**
484            * Decrements the reference count of the resource block and updates it in
485            * the database or deletes the resource block if the reference count reaches
486            * zero.
487            *
488            * @param resourceBlock the resource block
489            * @throws SystemException if a system exception occurred
490            */
491            public static void releaseResourceBlock(
492                    com.liferay.portal.model.ResourceBlock resourceBlock)
493                    throws com.liferay.portal.kernel.exception.SystemException {
494                    getService().releaseResourceBlock(resourceBlock);
495            }
496    
497            public static void removeAllGroupScopePermissions(long companyId,
498                    java.lang.String name, long roleId, long actionIdsLong)
499                    throws com.liferay.portal.kernel.exception.SystemException {
500                    getService()
501                            .removeAllGroupScopePermissions(companyId, name, roleId,
502                            actionIdsLong);
503            }
504    
505            public static void removeAllGroupScopePermissions(long companyId,
506                    java.lang.String name, long roleId, java.lang.String actionId)
507                    throws com.liferay.portal.kernel.exception.PortalException,
508                            com.liferay.portal.kernel.exception.SystemException {
509                    getService()
510                            .removeAllGroupScopePermissions(companyId, name, roleId, actionId);
511            }
512    
513            public static void removeCompanyScopePermission(long companyId,
514                    java.lang.String name, long roleId, java.lang.String actionId)
515                    throws com.liferay.portal.kernel.exception.PortalException,
516                            com.liferay.portal.kernel.exception.SystemException {
517                    getService()
518                            .removeCompanyScopePermission(companyId, name, roleId, actionId);
519            }
520    
521            public static void removeCompanyScopePermissions(long companyId,
522                    java.lang.String name, long roleId, long actionIdsLong)
523                    throws com.liferay.portal.kernel.exception.SystemException {
524                    getService()
525                            .removeCompanyScopePermissions(companyId, name, roleId,
526                            actionIdsLong);
527            }
528    
529            public static void removeGroupScopePermission(long companyId, long groupId,
530                    java.lang.String name, long roleId, java.lang.String actionId)
531                    throws com.liferay.portal.kernel.exception.PortalException,
532                            com.liferay.portal.kernel.exception.SystemException {
533                    getService()
534                            .removeGroupScopePermission(companyId, groupId, name, roleId,
535                            actionId);
536            }
537    
538            public static void removeGroupScopePermissions(long companyId,
539                    long groupId, java.lang.String name, long roleId, long actionIdsLong)
540                    throws com.liferay.portal.kernel.exception.SystemException {
541                    getService()
542                            .removeGroupScopePermissions(companyId, groupId, name, roleId,
543                            actionIdsLong);
544            }
545    
546            public static void removeIndividualScopePermission(long companyId,
547                    long groupId, java.lang.String name, long primKey, long roleId,
548                    java.lang.String actionId)
549                    throws com.liferay.portal.kernel.exception.PortalException,
550                            com.liferay.portal.kernel.exception.SystemException {
551                    getService()
552                            .removeIndividualScopePermission(companyId, groupId, name, primKey,
553                            roleId, actionId);
554            }
555    
556            public static void removeIndividualScopePermission(long companyId,
557                    long groupId, java.lang.String name,
558                    com.liferay.portal.model.PermissionedModel permissionedModel,
559                    long roleId, java.lang.String actionId)
560                    throws com.liferay.portal.kernel.exception.PortalException,
561                            com.liferay.portal.kernel.exception.SystemException {
562                    getService()
563                            .removeIndividualScopePermission(companyId, groupId, name,
564                            permissionedModel, roleId, actionId);
565            }
566    
567            public static void removeIndividualScopePermissions(long companyId,
568                    long groupId, java.lang.String name, long primKey, long roleId,
569                    long actionIdsLong)
570                    throws com.liferay.portal.kernel.exception.PortalException,
571                            com.liferay.portal.kernel.exception.SystemException {
572                    getService()
573                            .removeIndividualScopePermissions(companyId, groupId, name,
574                            primKey, roleId, actionIdsLong);
575            }
576    
577            public static void removeIndividualScopePermissions(long companyId,
578                    long groupId, java.lang.String name,
579                    com.liferay.portal.model.PermissionedModel permissionedModel,
580                    long roleId, long actionIdsLong)
581                    throws com.liferay.portal.kernel.exception.SystemException {
582                    getService()
583                            .removeIndividualScopePermissions(companyId, groupId, name,
584                            permissionedModel, roleId, actionIdsLong);
585            }
586    
587            /**
588            * Increments the reference count of the resource block and updates it in
589            * the database.
590            *
591            * @param resourceBlockId the primary key of the resource block
592            * @throws SystemException if a system exception occurred
593            */
594            public static void retainResourceBlock(long resourceBlockId)
595                    throws com.liferay.portal.kernel.exception.PortalException,
596                            com.liferay.portal.kernel.exception.SystemException {
597                    getService().retainResourceBlock(resourceBlockId);
598            }
599    
600            /**
601            * Increments the reference count of the resource block and updates it in
602            * the database.
603            *
604            * @param resourceBlock the resource block
605            * @throws SystemException if a system exception occurred
606            */
607            public static void retainResourceBlock(
608                    com.liferay.portal.model.ResourceBlock resourceBlock)
609                    throws com.liferay.portal.kernel.exception.SystemException {
610                    getService().retainResourceBlock(resourceBlock);
611            }
612    
613            public static void setCompanyScopePermissions(long companyId,
614                    java.lang.String name, long roleId,
615                    java.util.List<java.lang.String> actionIds)
616                    throws com.liferay.portal.kernel.exception.PortalException,
617                            com.liferay.portal.kernel.exception.SystemException {
618                    getService()
619                            .setCompanyScopePermissions(companyId, name, roleId, actionIds);
620            }
621    
622            public static void setCompanyScopePermissions(long companyId,
623                    java.lang.String name, long roleId, long actionIdsLong)
624                    throws com.liferay.portal.kernel.exception.SystemException {
625                    getService()
626                            .setCompanyScopePermissions(companyId, name, roleId, actionIdsLong);
627            }
628    
629            public static void setGroupScopePermissions(long companyId, long groupId,
630                    java.lang.String name, long roleId,
631                    java.util.List<java.lang.String> actionIds)
632                    throws com.liferay.portal.kernel.exception.PortalException,
633                            com.liferay.portal.kernel.exception.SystemException {
634                    getService()
635                            .setGroupScopePermissions(companyId, groupId, name, roleId,
636                            actionIds);
637            }
638    
639            public static void setGroupScopePermissions(long companyId, long groupId,
640                    java.lang.String name, long roleId, long actionIdsLong)
641                    throws com.liferay.portal.kernel.exception.SystemException {
642                    getService()
643                            .setGroupScopePermissions(companyId, groupId, name, roleId,
644                            actionIdsLong);
645            }
646    
647            public static void setIndividualScopePermissions(long companyId,
648                    long groupId, java.lang.String name, long primKey, long roleId,
649                    java.util.List<java.lang.String> actionIds)
650                    throws com.liferay.portal.kernel.exception.PortalException,
651                            com.liferay.portal.kernel.exception.SystemException {
652                    getService()
653                            .setIndividualScopePermissions(companyId, groupId, name, primKey,
654                            roleId, actionIds);
655            }
656    
657            public static void setIndividualScopePermissions(long companyId,
658                    long groupId, java.lang.String name, long primKey, long roleId,
659                    long actionIdsLong)
660                    throws com.liferay.portal.kernel.exception.PortalException,
661                            com.liferay.portal.kernel.exception.SystemException {
662                    getService()
663                            .setIndividualScopePermissions(companyId, groupId, name, primKey,
664                            roleId, actionIdsLong);
665            }
666    
667            public static void setIndividualScopePermissions(long companyId,
668                    long groupId, java.lang.String name, long primKey,
669                    java.util.Map<java.lang.Long, java.lang.String[]> roleIdsToActionIds)
670                    throws com.liferay.portal.kernel.exception.PortalException,
671                            com.liferay.portal.kernel.exception.SystemException {
672                    getService()
673                            .setIndividualScopePermissions(companyId, groupId, name, primKey,
674                            roleIdsToActionIds);
675            }
676    
677            public static void setIndividualScopePermissions(long companyId,
678                    long groupId, java.lang.String name,
679                    com.liferay.portal.model.PermissionedModel permissionedModel,
680                    long roleId, java.util.List<java.lang.String> actionIds)
681                    throws com.liferay.portal.kernel.exception.PortalException,
682                            com.liferay.portal.kernel.exception.SystemException {
683                    getService()
684                            .setIndividualScopePermissions(companyId, groupId, name,
685                            permissionedModel, roleId, actionIds);
686            }
687    
688            public static void setIndividualScopePermissions(long companyId,
689                    long groupId, java.lang.String name,
690                    com.liferay.portal.model.PermissionedModel permissionedModel,
691                    long roleId, long actionIdsLong)
692                    throws com.liferay.portal.kernel.exception.SystemException {
693                    getService()
694                            .setIndividualScopePermissions(companyId, groupId, name,
695                            permissionedModel, roleId, actionIdsLong);
696            }
697    
698            public static void updateCompanyScopePermissions(long companyId,
699                    java.lang.String name, long roleId, long actionIdsLong, int operator)
700                    throws com.liferay.portal.kernel.exception.SystemException {
701                    getService()
702                            .updateCompanyScopePermissions(companyId, name, roleId,
703                            actionIdsLong, operator);
704            }
705    
706            public static void updateGroupScopePermissions(long companyId,
707                    long groupId, java.lang.String name, long roleId, long actionIdsLong,
708                    int operator)
709                    throws com.liferay.portal.kernel.exception.SystemException {
710                    getService()
711                            .updateGroupScopePermissions(companyId, groupId, name, roleId,
712                            actionIdsLong, operator);
713            }
714    
715            public static void updateIndividualScopePermissions(long companyId,
716                    long groupId, java.lang.String name,
717                    com.liferay.portal.model.PermissionedModel permissionedModel,
718                    long roleId, long actionIdsLong, int operator)
719                    throws com.liferay.portal.kernel.exception.SystemException {
720                    getService()
721                            .updateIndividualScopePermissions(companyId, groupId, name,
722                            permissionedModel, roleId, actionIdsLong, operator);
723            }
724    
725            public static com.liferay.portal.model.ResourceBlock updateResourceBlockId(
726                    long companyId, long groupId, java.lang.String name,
727                    com.liferay.portal.model.PermissionedModel permissionedModel,
728                    java.lang.String permissionsHash,
729                    com.liferay.portal.model.ResourceBlockPermissionsContainer resourceBlockPermissionsContainer)
730                    throws com.liferay.portal.kernel.exception.SystemException {
731                    return getService()
732                                       .updateResourceBlockId(companyId, groupId, name,
733                            permissionedModel, permissionsHash,
734                            resourceBlockPermissionsContainer);
735            }
736    
737            public static void verifyResourceBlockId(long companyId,
738                    java.lang.String name, long primKey)
739                    throws com.liferay.portal.kernel.exception.PortalException,
740                            com.liferay.portal.kernel.exception.SystemException {
741                    getService().verifyResourceBlockId(companyId, name, primKey);
742            }
743    
744            public static ResourceBlockLocalService getService() {
745                    if (_service == null) {
746                            _service = (ResourceBlockLocalService)PortalBeanLocatorUtil.locate(ResourceBlockLocalService.class.getName());
747    
748                            ReferenceRegistry.registerReference(ResourceBlockLocalServiceUtil.class,
749                                    "_service");
750                            MethodCache.remove(ResourceBlockLocalService.class);
751                    }
752    
753                    return _service;
754            }
755    
756            public void setService(ResourceBlockLocalService service) {
757                    MethodCache.remove(ResourceBlockLocalService.class);
758    
759                    _service = service;
760    
761                    ReferenceRegistry.registerReference(ResourceBlockLocalServiceUtil.class,
762                            "_service");
763                    MethodCache.remove(ResourceBlockLocalService.class);
764            }
765    
766            private static ResourceBlockLocalService _service;
767    }