001    /**
002     * Copyright (c) 2000-2012 Liferay, Inc. All rights reserved.
003     *
004     * The contents of this file are subject to the terms of the Liferay Enterprise
005     * Subscription License ("License"). You may not use this file except in
006     * compliance with the License. You can obtain a copy of the License by
007     * contacting Liferay, Inc. See the License for the specific language governing
008     * permissions and limitations under the License, including but not limited to
009     * distribution rights of the Software.
010     *
011     *
012     *
013     */
014    
015    package com.liferay.portal.service.persistence;
016    
017    import com.liferay.portal.model.ResourcePermission;
018    
019    /**
020     * The persistence interface for the resource permission service.
021     *
022     * <p>
023     * Caching information and settings can be found in <code>portal.properties</code>
024     * </p>
025     *
026     * @author Brian Wing Shun Chan
027     * @see ResourcePermissionPersistenceImpl
028     * @see ResourcePermissionUtil
029     * @generated
030     */
031    public interface ResourcePermissionPersistence extends BasePersistence<ResourcePermission> {
032            /*
033             * NOTE FOR DEVELOPERS:
034             *
035             * Never modify or reference this interface directly. Always use {@link ResourcePermissionUtil} to access the resource permission persistence. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this interface.
036             */
037    
038            /**
039            * Caches the resource permission in the entity cache if it is enabled.
040            *
041            * @param resourcePermission the resource permission
042            */
043            public void cacheResult(
044                    com.liferay.portal.model.ResourcePermission resourcePermission);
045    
046            /**
047            * Caches the resource permissions in the entity cache if it is enabled.
048            *
049            * @param resourcePermissions the resource permissions
050            */
051            public void cacheResult(
052                    java.util.List<com.liferay.portal.model.ResourcePermission> resourcePermissions);
053    
054            /**
055            * Creates a new resource permission with the primary key. Does not add the resource permission to the database.
056            *
057            * @param resourcePermissionId the primary key for the new resource permission
058            * @return the new resource permission
059            */
060            public com.liferay.portal.model.ResourcePermission create(
061                    long resourcePermissionId);
062    
063            /**
064            * Removes the resource permission with the primary key from the database. Also notifies the appropriate model listeners.
065            *
066            * @param resourcePermissionId the primary key of the resource permission
067            * @return the resource permission that was removed
068            * @throws com.liferay.portal.NoSuchResourcePermissionException if a resource permission with the primary key could not be found
069            * @throws SystemException if a system exception occurred
070            */
071            public com.liferay.portal.model.ResourcePermission remove(
072                    long resourcePermissionId)
073                    throws com.liferay.portal.NoSuchResourcePermissionException,
074                            com.liferay.portal.kernel.exception.SystemException;
075    
076            public com.liferay.portal.model.ResourcePermission updateImpl(
077                    com.liferay.portal.model.ResourcePermission resourcePermission,
078                    boolean merge)
079                    throws com.liferay.portal.kernel.exception.SystemException;
080    
081            /**
082            * Returns the resource permission with the primary key or throws a {@link com.liferay.portal.NoSuchResourcePermissionException} if it could not be found.
083            *
084            * @param resourcePermissionId the primary key of the resource permission
085            * @return the resource permission
086            * @throws com.liferay.portal.NoSuchResourcePermissionException if a resource permission with the primary key could not be found
087            * @throws SystemException if a system exception occurred
088            */
089            public com.liferay.portal.model.ResourcePermission findByPrimaryKey(
090                    long resourcePermissionId)
091                    throws com.liferay.portal.NoSuchResourcePermissionException,
092                            com.liferay.portal.kernel.exception.SystemException;
093    
094            /**
095            * Returns the resource permission with the primary key or returns <code>null</code> if it could not be found.
096            *
097            * @param resourcePermissionId the primary key of the resource permission
098            * @return the resource permission, or <code>null</code> if a resource permission with the primary key could not be found
099            * @throws SystemException if a system exception occurred
100            */
101            public com.liferay.portal.model.ResourcePermission fetchByPrimaryKey(
102                    long resourcePermissionId)
103                    throws com.liferay.portal.kernel.exception.SystemException;
104    
105            /**
106            * Returns all the resource permissions where scope = &#63;.
107            *
108            * @param scope the scope
109            * @return the matching resource permissions
110            * @throws SystemException if a system exception occurred
111            */
112            public java.util.List<com.liferay.portal.model.ResourcePermission> findByScope(
113                    int scope) throws com.liferay.portal.kernel.exception.SystemException;
114    
115            /**
116            * Returns a range of all the resource permissions where scope = &#63;.
117            *
118            * <p>
119            * 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.
120            * </p>
121            *
122            * @param scope the scope
123            * @param start the lower bound of the range of resource permissions
124            * @param end the upper bound of the range of resource permissions (not inclusive)
125            * @return the range of matching resource permissions
126            * @throws SystemException if a system exception occurred
127            */
128            public java.util.List<com.liferay.portal.model.ResourcePermission> findByScope(
129                    int scope, int start, int end)
130                    throws com.liferay.portal.kernel.exception.SystemException;
131    
132            /**
133            * Returns an ordered range of all the resource permissions where scope = &#63;.
134            *
135            * <p>
136            * 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.
137            * </p>
138            *
139            * @param scope the scope
140            * @param start the lower bound of the range of resource permissions
141            * @param end the upper bound of the range of resource permissions (not inclusive)
142            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
143            * @return the ordered range of matching resource permissions
144            * @throws SystemException if a system exception occurred
145            */
146            public java.util.List<com.liferay.portal.model.ResourcePermission> findByScope(
147                    int scope, int start, int end,
148                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
149                    throws com.liferay.portal.kernel.exception.SystemException;
150    
151            /**
152            * Returns the first resource permission in the ordered set where scope = &#63;.
153            *
154            * @param scope the scope
155            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
156            * @return the first matching resource permission
157            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
158            * @throws SystemException if a system exception occurred
159            */
160            public com.liferay.portal.model.ResourcePermission findByScope_First(
161                    int scope,
162                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
163                    throws com.liferay.portal.NoSuchResourcePermissionException,
164                            com.liferay.portal.kernel.exception.SystemException;
165    
166            /**
167            * Returns the first resource permission in the ordered set where scope = &#63;.
168            *
169            * @param scope the scope
170            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
171            * @return the first matching resource permission, or <code>null</code> if a matching resource permission could not be found
172            * @throws SystemException if a system exception occurred
173            */
174            public com.liferay.portal.model.ResourcePermission fetchByScope_First(
175                    int scope,
176                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
177                    throws com.liferay.portal.kernel.exception.SystemException;
178    
179            /**
180            * Returns the last resource permission in the ordered set where scope = &#63;.
181            *
182            * @param scope the scope
183            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
184            * @return the last matching resource permission
185            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
186            * @throws SystemException if a system exception occurred
187            */
188            public com.liferay.portal.model.ResourcePermission findByScope_Last(
189                    int scope,
190                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
191                    throws com.liferay.portal.NoSuchResourcePermissionException,
192                            com.liferay.portal.kernel.exception.SystemException;
193    
194            /**
195            * Returns the last resource permission in the ordered set where scope = &#63;.
196            *
197            * @param scope the scope
198            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
199            * @return the last matching resource permission, or <code>null</code> if a matching resource permission could not be found
200            * @throws SystemException if a system exception occurred
201            */
202            public com.liferay.portal.model.ResourcePermission fetchByScope_Last(
203                    int scope,
204                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
205                    throws com.liferay.portal.kernel.exception.SystemException;
206    
207            /**
208            * Returns the resource permissions before and after the current resource permission in the ordered set where scope = &#63;.
209            *
210            * @param resourcePermissionId the primary key of the current resource permission
211            * @param scope the scope
212            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
213            * @return the previous, current, and next resource permission
214            * @throws com.liferay.portal.NoSuchResourcePermissionException if a resource permission with the primary key could not be found
215            * @throws SystemException if a system exception occurred
216            */
217            public com.liferay.portal.model.ResourcePermission[] findByScope_PrevAndNext(
218                    long resourcePermissionId, int scope,
219                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
220                    throws com.liferay.portal.NoSuchResourcePermissionException,
221                            com.liferay.portal.kernel.exception.SystemException;
222    
223            /**
224            * Returns all the resource permissions where scope = any &#63;.
225            *
226            * <p>
227            * 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.
228            * </p>
229            *
230            * @param scopes the scopes
231            * @return the matching resource permissions
232            * @throws SystemException if a system exception occurred
233            */
234            public java.util.List<com.liferay.portal.model.ResourcePermission> findByScope(
235                    int[] scopes)
236                    throws com.liferay.portal.kernel.exception.SystemException;
237    
238            /**
239            * Returns a range of all the resource permissions where scope = any &#63;.
240            *
241            * <p>
242            * 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.
243            * </p>
244            *
245            * @param scopes the scopes
246            * @param start the lower bound of the range of resource permissions
247            * @param end the upper bound of the range of resource permissions (not inclusive)
248            * @return the range of matching resource permissions
249            * @throws SystemException if a system exception occurred
250            */
251            public java.util.List<com.liferay.portal.model.ResourcePermission> findByScope(
252                    int[] scopes, int start, int end)
253                    throws com.liferay.portal.kernel.exception.SystemException;
254    
255            /**
256            * Returns an ordered range of all the resource permissions where scope = any &#63;.
257            *
258            * <p>
259            * 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.
260            * </p>
261            *
262            * @param scopes the scopes
263            * @param start the lower bound of the range of resource permissions
264            * @param end the upper bound of the range of resource permissions (not inclusive)
265            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
266            * @return the ordered range of matching resource permissions
267            * @throws SystemException if a system exception occurred
268            */
269            public java.util.List<com.liferay.portal.model.ResourcePermission> findByScope(
270                    int[] scopes, int start, int end,
271                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
272                    throws com.liferay.portal.kernel.exception.SystemException;
273    
274            /**
275            * Returns all the resource permissions where roleId = &#63;.
276            *
277            * @param roleId the role ID
278            * @return the matching resource permissions
279            * @throws SystemException if a system exception occurred
280            */
281            public java.util.List<com.liferay.portal.model.ResourcePermission> findByRoleId(
282                    long roleId) throws com.liferay.portal.kernel.exception.SystemException;
283    
284            /**
285            * Returns a range of all the resource permissions where roleId = &#63;.
286            *
287            * <p>
288            * 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.
289            * </p>
290            *
291            * @param roleId the role ID
292            * @param start the lower bound of the range of resource permissions
293            * @param end the upper bound of the range of resource permissions (not inclusive)
294            * @return the range of matching resource permissions
295            * @throws SystemException if a system exception occurred
296            */
297            public java.util.List<com.liferay.portal.model.ResourcePermission> findByRoleId(
298                    long roleId, int start, int end)
299                    throws com.liferay.portal.kernel.exception.SystemException;
300    
301            /**
302            * Returns an ordered range of all the resource permissions where roleId = &#63;.
303            *
304            * <p>
305            * 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.
306            * </p>
307            *
308            * @param roleId the role ID
309            * @param start the lower bound of the range of resource permissions
310            * @param end the upper bound of the range of resource permissions (not inclusive)
311            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
312            * @return the ordered range of matching resource permissions
313            * @throws SystemException if a system exception occurred
314            */
315            public java.util.List<com.liferay.portal.model.ResourcePermission> findByRoleId(
316                    long roleId, int start, int end,
317                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
318                    throws com.liferay.portal.kernel.exception.SystemException;
319    
320            /**
321            * Returns the first resource permission in the ordered set where roleId = &#63;.
322            *
323            * @param roleId the role ID
324            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
325            * @return the first matching resource permission
326            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
327            * @throws SystemException if a system exception occurred
328            */
329            public com.liferay.portal.model.ResourcePermission findByRoleId_First(
330                    long roleId,
331                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
332                    throws com.liferay.portal.NoSuchResourcePermissionException,
333                            com.liferay.portal.kernel.exception.SystemException;
334    
335            /**
336            * Returns the first resource permission in the ordered set where roleId = &#63;.
337            *
338            * @param roleId the role ID
339            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
340            * @return the first matching resource permission, or <code>null</code> if a matching resource permission could not be found
341            * @throws SystemException if a system exception occurred
342            */
343            public com.liferay.portal.model.ResourcePermission fetchByRoleId_First(
344                    long roleId,
345                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
346                    throws com.liferay.portal.kernel.exception.SystemException;
347    
348            /**
349            * Returns the last resource permission in the ordered set where roleId = &#63;.
350            *
351            * @param roleId the role ID
352            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
353            * @return the last matching resource permission
354            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
355            * @throws SystemException if a system exception occurred
356            */
357            public com.liferay.portal.model.ResourcePermission findByRoleId_Last(
358                    long roleId,
359                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
360                    throws com.liferay.portal.NoSuchResourcePermissionException,
361                            com.liferay.portal.kernel.exception.SystemException;
362    
363            /**
364            * Returns the last resource permission in the ordered set where roleId = &#63;.
365            *
366            * @param roleId the role ID
367            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
368            * @return the last matching resource permission, or <code>null</code> if a matching resource permission could not be found
369            * @throws SystemException if a system exception occurred
370            */
371            public com.liferay.portal.model.ResourcePermission fetchByRoleId_Last(
372                    long roleId,
373                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
374                    throws com.liferay.portal.kernel.exception.SystemException;
375    
376            /**
377            * Returns the resource permissions before and after the current resource permission in the ordered set where roleId = &#63;.
378            *
379            * @param resourcePermissionId the primary key of the current resource permission
380            * @param roleId the role ID
381            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
382            * @return the previous, current, and next resource permission
383            * @throws com.liferay.portal.NoSuchResourcePermissionException if a resource permission with the primary key could not be found
384            * @throws SystemException if a system exception occurred
385            */
386            public com.liferay.portal.model.ResourcePermission[] findByRoleId_PrevAndNext(
387                    long resourcePermissionId, long roleId,
388                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
389                    throws com.liferay.portal.NoSuchResourcePermissionException,
390                            com.liferay.portal.kernel.exception.SystemException;
391    
392            /**
393            * Returns all the resource permissions where companyId = &#63; and primKey LIKE &#63;.
394            *
395            * @param companyId the company ID
396            * @param primKey the prim key
397            * @return the matching resource permissions
398            * @throws SystemException if a system exception occurred
399            */
400            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_P(
401                    long companyId, java.lang.String primKey)
402                    throws com.liferay.portal.kernel.exception.SystemException;
403    
404            /**
405            * Returns a range of all the resource permissions where companyId = &#63; and primKey LIKE &#63;.
406            *
407            * <p>
408            * 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.
409            * </p>
410            *
411            * @param companyId the company ID
412            * @param primKey the prim key
413            * @param start the lower bound of the range of resource permissions
414            * @param end the upper bound of the range of resource permissions (not inclusive)
415            * @return the range of matching resource permissions
416            * @throws SystemException if a system exception occurred
417            */
418            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_P(
419                    long companyId, java.lang.String primKey, int start, int end)
420                    throws com.liferay.portal.kernel.exception.SystemException;
421    
422            /**
423            * Returns an ordered range of all the resource permissions where companyId = &#63; and primKey LIKE &#63;.
424            *
425            * <p>
426            * 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.
427            * </p>
428            *
429            * @param companyId the company ID
430            * @param primKey the prim key
431            * @param start the lower bound of the range of resource permissions
432            * @param end the upper bound of the range of resource permissions (not inclusive)
433            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
434            * @return the ordered range of matching resource permissions
435            * @throws SystemException if a system exception occurred
436            */
437            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_P(
438                    long companyId, java.lang.String primKey, int start, int end,
439                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
440                    throws com.liferay.portal.kernel.exception.SystemException;
441    
442            /**
443            * Returns the first resource permission in the ordered set where companyId = &#63; and primKey LIKE &#63;.
444            *
445            * @param companyId the company ID
446            * @param primKey the prim key
447            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
448            * @return the first matching resource permission
449            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
450            * @throws SystemException if a system exception occurred
451            */
452            public com.liferay.portal.model.ResourcePermission findByC_P_First(
453                    long companyId, java.lang.String primKey,
454                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
455                    throws com.liferay.portal.NoSuchResourcePermissionException,
456                            com.liferay.portal.kernel.exception.SystemException;
457    
458            /**
459            * Returns the first resource permission in the ordered set where companyId = &#63; and primKey LIKE &#63;.
460            *
461            * @param companyId the company ID
462            * @param primKey the prim key
463            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
464            * @return the first matching resource permission, or <code>null</code> if a matching resource permission could not be found
465            * @throws SystemException if a system exception occurred
466            */
467            public com.liferay.portal.model.ResourcePermission fetchByC_P_First(
468                    long companyId, java.lang.String primKey,
469                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
470                    throws com.liferay.portal.kernel.exception.SystemException;
471    
472            /**
473            * Returns the last resource permission in the ordered set where companyId = &#63; and primKey LIKE &#63;.
474            *
475            * @param companyId the company ID
476            * @param primKey the prim key
477            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
478            * @return the last matching resource permission
479            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
480            * @throws SystemException if a system exception occurred
481            */
482            public com.liferay.portal.model.ResourcePermission findByC_P_Last(
483                    long companyId, java.lang.String primKey,
484                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
485                    throws com.liferay.portal.NoSuchResourcePermissionException,
486                            com.liferay.portal.kernel.exception.SystemException;
487    
488            /**
489            * Returns the last resource permission in the ordered set where companyId = &#63; and primKey LIKE &#63;.
490            *
491            * @param companyId the company ID
492            * @param primKey the prim key
493            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
494            * @return the last matching resource permission, or <code>null</code> if a matching resource permission could not be found
495            * @throws SystemException if a system exception occurred
496            */
497            public com.liferay.portal.model.ResourcePermission fetchByC_P_Last(
498                    long companyId, java.lang.String primKey,
499                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
500                    throws com.liferay.portal.kernel.exception.SystemException;
501    
502            /**
503            * Returns the resource permissions before and after the current resource permission in the ordered set where companyId = &#63; and primKey LIKE &#63;.
504            *
505            * @param resourcePermissionId the primary key of the current resource permission
506            * @param companyId the company ID
507            * @param primKey the prim key
508            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
509            * @return the previous, current, and next resource permission
510            * @throws com.liferay.portal.NoSuchResourcePermissionException if a resource permission with the primary key could not be found
511            * @throws SystemException if a system exception occurred
512            */
513            public com.liferay.portal.model.ResourcePermission[] findByC_P_PrevAndNext(
514                    long resourcePermissionId, long companyId, java.lang.String primKey,
515                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
516                    throws com.liferay.portal.NoSuchResourcePermissionException,
517                            com.liferay.portal.kernel.exception.SystemException;
518    
519            /**
520            * Returns all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63;.
521            *
522            * @param companyId the company ID
523            * @param name the name
524            * @param scope the scope
525            * @return the matching resource permissions
526            * @throws SystemException if a system exception occurred
527            */
528            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S(
529                    long companyId, java.lang.String name, int scope)
530                    throws com.liferay.portal.kernel.exception.SystemException;
531    
532            /**
533            * Returns a range of all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63;.
534            *
535            * <p>
536            * 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.
537            * </p>
538            *
539            * @param companyId the company ID
540            * @param name the name
541            * @param scope the scope
542            * @param start the lower bound of the range of resource permissions
543            * @param end the upper bound of the range of resource permissions (not inclusive)
544            * @return the range of matching resource permissions
545            * @throws SystemException if a system exception occurred
546            */
547            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S(
548                    long companyId, java.lang.String name, int scope, int start, int end)
549                    throws com.liferay.portal.kernel.exception.SystemException;
550    
551            /**
552            * Returns an ordered range of all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63;.
553            *
554            * <p>
555            * 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.
556            * </p>
557            *
558            * @param companyId the company ID
559            * @param name the name
560            * @param scope the scope
561            * @param start the lower bound of the range of resource permissions
562            * @param end the upper bound of the range of resource permissions (not inclusive)
563            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
564            * @return the ordered range of matching resource permissions
565            * @throws SystemException if a system exception occurred
566            */
567            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S(
568                    long companyId, java.lang.String name, int scope, int start, int end,
569                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
570                    throws com.liferay.portal.kernel.exception.SystemException;
571    
572            /**
573            * Returns the first resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63;.
574            *
575            * @param companyId the company ID
576            * @param name the name
577            * @param scope the scope
578            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
579            * @return the first matching resource permission
580            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
581            * @throws SystemException if a system exception occurred
582            */
583            public com.liferay.portal.model.ResourcePermission findByC_N_S_First(
584                    long companyId, java.lang.String name, int scope,
585                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
586                    throws com.liferay.portal.NoSuchResourcePermissionException,
587                            com.liferay.portal.kernel.exception.SystemException;
588    
589            /**
590            * Returns the first resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63;.
591            *
592            * @param companyId the company ID
593            * @param name the name
594            * @param scope the scope
595            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
596            * @return the first matching resource permission, or <code>null</code> if a matching resource permission could not be found
597            * @throws SystemException if a system exception occurred
598            */
599            public com.liferay.portal.model.ResourcePermission fetchByC_N_S_First(
600                    long companyId, java.lang.String name, int scope,
601                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
602                    throws com.liferay.portal.kernel.exception.SystemException;
603    
604            /**
605            * Returns the last resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63;.
606            *
607            * @param companyId the company ID
608            * @param name the name
609            * @param scope the scope
610            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
611            * @return the last matching resource permission
612            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
613            * @throws SystemException if a system exception occurred
614            */
615            public com.liferay.portal.model.ResourcePermission findByC_N_S_Last(
616                    long companyId, java.lang.String name, int scope,
617                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
618                    throws com.liferay.portal.NoSuchResourcePermissionException,
619                            com.liferay.portal.kernel.exception.SystemException;
620    
621            /**
622            * Returns the last resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63;.
623            *
624            * @param companyId the company ID
625            * @param name the name
626            * @param scope the scope
627            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
628            * @return the last matching resource permission, or <code>null</code> if a matching resource permission could not be found
629            * @throws SystemException if a system exception occurred
630            */
631            public com.liferay.portal.model.ResourcePermission fetchByC_N_S_Last(
632                    long companyId, java.lang.String name, int scope,
633                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
634                    throws com.liferay.portal.kernel.exception.SystemException;
635    
636            /**
637            * Returns the resource permissions before and after the current resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63;.
638            *
639            * @param resourcePermissionId the primary key of the current resource permission
640            * @param companyId the company ID
641            * @param name the name
642            * @param scope the scope
643            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
644            * @return the previous, current, and next resource permission
645            * @throws com.liferay.portal.NoSuchResourcePermissionException if a resource permission with the primary key could not be found
646            * @throws SystemException if a system exception occurred
647            */
648            public com.liferay.portal.model.ResourcePermission[] findByC_N_S_PrevAndNext(
649                    long resourcePermissionId, long companyId, java.lang.String name,
650                    int scope,
651                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
652                    throws com.liferay.portal.NoSuchResourcePermissionException,
653                            com.liferay.portal.kernel.exception.SystemException;
654    
655            /**
656            * Returns all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63;.
657            *
658            * @param companyId the company ID
659            * @param name the name
660            * @param scope the scope
661            * @param primKey the prim key
662            * @return the matching resource permissions
663            * @throws SystemException if a system exception occurred
664            */
665            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P(
666                    long companyId, java.lang.String name, int scope,
667                    java.lang.String primKey)
668                    throws com.liferay.portal.kernel.exception.SystemException;
669    
670            /**
671            * Returns a range of all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63;.
672            *
673            * <p>
674            * 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.
675            * </p>
676            *
677            * @param companyId the company ID
678            * @param name the name
679            * @param scope the scope
680            * @param primKey the prim key
681            * @param start the lower bound of the range of resource permissions
682            * @param end the upper bound of the range of resource permissions (not inclusive)
683            * @return the range of matching resource permissions
684            * @throws SystemException if a system exception occurred
685            */
686            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P(
687                    long companyId, java.lang.String name, int scope,
688                    java.lang.String primKey, int start, int end)
689                    throws com.liferay.portal.kernel.exception.SystemException;
690    
691            /**
692            * Returns an ordered range of all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63;.
693            *
694            * <p>
695            * 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.
696            * </p>
697            *
698            * @param companyId the company ID
699            * @param name the name
700            * @param scope the scope
701            * @param primKey the prim key
702            * @param start the lower bound of the range of resource permissions
703            * @param end the upper bound of the range of resource permissions (not inclusive)
704            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
705            * @return the ordered range of matching resource permissions
706            * @throws SystemException if a system exception occurred
707            */
708            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P(
709                    long companyId, java.lang.String name, int scope,
710                    java.lang.String primKey, int start, int end,
711                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
712                    throws com.liferay.portal.kernel.exception.SystemException;
713    
714            /**
715            * Returns the first resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63;.
716            *
717            * @param companyId the company ID
718            * @param name the name
719            * @param scope the scope
720            * @param primKey the prim key
721            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
722            * @return the first matching resource permission
723            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
724            * @throws SystemException if a system exception occurred
725            */
726            public com.liferay.portal.model.ResourcePermission findByC_N_S_P_First(
727                    long companyId, java.lang.String name, int scope,
728                    java.lang.String primKey,
729                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
730                    throws com.liferay.portal.NoSuchResourcePermissionException,
731                            com.liferay.portal.kernel.exception.SystemException;
732    
733            /**
734            * Returns the first resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63;.
735            *
736            * @param companyId the company ID
737            * @param name the name
738            * @param scope the scope
739            * @param primKey the prim key
740            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
741            * @return the first matching resource permission, or <code>null</code> if a matching resource permission could not be found
742            * @throws SystemException if a system exception occurred
743            */
744            public com.liferay.portal.model.ResourcePermission fetchByC_N_S_P_First(
745                    long companyId, java.lang.String name, int scope,
746                    java.lang.String primKey,
747                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
748                    throws com.liferay.portal.kernel.exception.SystemException;
749    
750            /**
751            * Returns the last resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63;.
752            *
753            * @param companyId the company ID
754            * @param name the name
755            * @param scope the scope
756            * @param primKey the prim key
757            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
758            * @return the last matching resource permission
759            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
760            * @throws SystemException if a system exception occurred
761            */
762            public com.liferay.portal.model.ResourcePermission findByC_N_S_P_Last(
763                    long companyId, java.lang.String name, int scope,
764                    java.lang.String primKey,
765                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
766                    throws com.liferay.portal.NoSuchResourcePermissionException,
767                            com.liferay.portal.kernel.exception.SystemException;
768    
769            /**
770            * Returns the last resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63;.
771            *
772            * @param companyId the company ID
773            * @param name the name
774            * @param scope the scope
775            * @param primKey the prim key
776            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
777            * @return the last matching resource permission, or <code>null</code> if a matching resource permission could not be found
778            * @throws SystemException if a system exception occurred
779            */
780            public com.liferay.portal.model.ResourcePermission fetchByC_N_S_P_Last(
781                    long companyId, java.lang.String name, int scope,
782                    java.lang.String primKey,
783                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
784                    throws com.liferay.portal.kernel.exception.SystemException;
785    
786            /**
787            * Returns the resource permissions before and after the current resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63;.
788            *
789            * @param resourcePermissionId the primary key of the current resource permission
790            * @param companyId the company ID
791            * @param name the name
792            * @param scope the scope
793            * @param primKey the prim key
794            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
795            * @return the previous, current, and next resource permission
796            * @throws com.liferay.portal.NoSuchResourcePermissionException if a resource permission with the primary key could not be found
797            * @throws SystemException if a system exception occurred
798            */
799            public com.liferay.portal.model.ResourcePermission[] findByC_N_S_P_PrevAndNext(
800                    long resourcePermissionId, long companyId, java.lang.String name,
801                    int scope, java.lang.String primKey,
802                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
803                    throws com.liferay.portal.NoSuchResourcePermissionException,
804                            com.liferay.portal.kernel.exception.SystemException;
805    
806            /**
807            * Returns all the resource permissions where companyId = &#63; and name = &#63; and primKey = &#63; and ownerId = &#63;.
808            *
809            * @param companyId the company ID
810            * @param name the name
811            * @param primKey the prim key
812            * @param ownerId the owner ID
813            * @return the matching resource permissions
814            * @throws SystemException if a system exception occurred
815            */
816            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_P_O(
817                    long companyId, java.lang.String name, java.lang.String primKey,
818                    long ownerId)
819                    throws com.liferay.portal.kernel.exception.SystemException;
820    
821            /**
822            * Returns a range of all the resource permissions where companyId = &#63; and name = &#63; and primKey = &#63; and ownerId = &#63;.
823            *
824            * <p>
825            * 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.
826            * </p>
827            *
828            * @param companyId the company ID
829            * @param name the name
830            * @param primKey the prim key
831            * @param ownerId the owner ID
832            * @param start the lower bound of the range of resource permissions
833            * @param end the upper bound of the range of resource permissions (not inclusive)
834            * @return the range of matching resource permissions
835            * @throws SystemException if a system exception occurred
836            */
837            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_P_O(
838                    long companyId, java.lang.String name, java.lang.String primKey,
839                    long ownerId, int start, int end)
840                    throws com.liferay.portal.kernel.exception.SystemException;
841    
842            /**
843            * Returns an ordered range of all the resource permissions where companyId = &#63; and name = &#63; and primKey = &#63; and ownerId = &#63;.
844            *
845            * <p>
846            * 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.
847            * </p>
848            *
849            * @param companyId the company ID
850            * @param name the name
851            * @param primKey the prim key
852            * @param ownerId the owner ID
853            * @param start the lower bound of the range of resource permissions
854            * @param end the upper bound of the range of resource permissions (not inclusive)
855            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
856            * @return the ordered range of matching resource permissions
857            * @throws SystemException if a system exception occurred
858            */
859            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_P_O(
860                    long companyId, java.lang.String name, java.lang.String primKey,
861                    long ownerId, int start, int end,
862                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
863                    throws com.liferay.portal.kernel.exception.SystemException;
864    
865            /**
866            * Returns the first resource permission in the ordered set where companyId = &#63; and name = &#63; and primKey = &#63; and ownerId = &#63;.
867            *
868            * @param companyId the company ID
869            * @param name the name
870            * @param primKey the prim key
871            * @param ownerId the owner ID
872            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
873            * @return the first matching resource permission
874            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
875            * @throws SystemException if a system exception occurred
876            */
877            public com.liferay.portal.model.ResourcePermission findByC_N_P_O_First(
878                    long companyId, java.lang.String name, java.lang.String primKey,
879                    long ownerId,
880                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
881                    throws com.liferay.portal.NoSuchResourcePermissionException,
882                            com.liferay.portal.kernel.exception.SystemException;
883    
884            /**
885            * Returns the first resource permission in the ordered set where companyId = &#63; and name = &#63; and primKey = &#63; and ownerId = &#63;.
886            *
887            * @param companyId the company ID
888            * @param name the name
889            * @param primKey the prim key
890            * @param ownerId the owner ID
891            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
892            * @return the first matching resource permission, or <code>null</code> if a matching resource permission could not be found
893            * @throws SystemException if a system exception occurred
894            */
895            public com.liferay.portal.model.ResourcePermission fetchByC_N_P_O_First(
896                    long companyId, java.lang.String name, java.lang.String primKey,
897                    long ownerId,
898                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
899                    throws com.liferay.portal.kernel.exception.SystemException;
900    
901            /**
902            * Returns the last resource permission in the ordered set where companyId = &#63; and name = &#63; and primKey = &#63; and ownerId = &#63;.
903            *
904            * @param companyId the company ID
905            * @param name the name
906            * @param primKey the prim key
907            * @param ownerId the owner ID
908            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
909            * @return the last matching resource permission
910            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
911            * @throws SystemException if a system exception occurred
912            */
913            public com.liferay.portal.model.ResourcePermission findByC_N_P_O_Last(
914                    long companyId, java.lang.String name, java.lang.String primKey,
915                    long ownerId,
916                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
917                    throws com.liferay.portal.NoSuchResourcePermissionException,
918                            com.liferay.portal.kernel.exception.SystemException;
919    
920            /**
921            * Returns the last resource permission in the ordered set where companyId = &#63; and name = &#63; and primKey = &#63; and ownerId = &#63;.
922            *
923            * @param companyId the company ID
924            * @param name the name
925            * @param primKey the prim key
926            * @param ownerId the owner ID
927            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
928            * @return the last matching resource permission, or <code>null</code> if a matching resource permission could not be found
929            * @throws SystemException if a system exception occurred
930            */
931            public com.liferay.portal.model.ResourcePermission fetchByC_N_P_O_Last(
932                    long companyId, java.lang.String name, java.lang.String primKey,
933                    long ownerId,
934                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
935                    throws com.liferay.portal.kernel.exception.SystemException;
936    
937            /**
938            * Returns the resource permissions before and after the current resource permission in the ordered set where companyId = &#63; and name = &#63; and primKey = &#63; and ownerId = &#63;.
939            *
940            * @param resourcePermissionId the primary key of the current resource permission
941            * @param companyId the company ID
942            * @param name the name
943            * @param primKey the prim key
944            * @param ownerId the owner ID
945            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
946            * @return the previous, current, and next resource permission
947            * @throws com.liferay.portal.NoSuchResourcePermissionException if a resource permission with the primary key could not be found
948            * @throws SystemException if a system exception occurred
949            */
950            public com.liferay.portal.model.ResourcePermission[] findByC_N_P_O_PrevAndNext(
951                    long resourcePermissionId, long companyId, java.lang.String name,
952                    java.lang.String primKey, long ownerId,
953                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
954                    throws com.liferay.portal.NoSuchResourcePermissionException,
955                            com.liferay.portal.kernel.exception.SystemException;
956    
957            /**
958            * Returns all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63;.
959            *
960            * @param companyId the company ID
961            * @param name the name
962            * @param scope the scope
963            * @param primKey the prim key
964            * @param roleId the role ID
965            * @return the matching resource permissions
966            * @throws SystemException if a system exception occurred
967            */
968            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P_R(
969                    long companyId, java.lang.String name, int scope,
970                    java.lang.String primKey, long roleId)
971                    throws com.liferay.portal.kernel.exception.SystemException;
972    
973            /**
974            * Returns a range of all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63;.
975            *
976            * <p>
977            * 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.
978            * </p>
979            *
980            * @param companyId the company ID
981            * @param name the name
982            * @param scope the scope
983            * @param primKey the prim key
984            * @param roleId the role ID
985            * @param start the lower bound of the range of resource permissions
986            * @param end the upper bound of the range of resource permissions (not inclusive)
987            * @return the range of matching resource permissions
988            * @throws SystemException if a system exception occurred
989            */
990            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P_R(
991                    long companyId, java.lang.String name, int scope,
992                    java.lang.String primKey, long roleId, int start, int end)
993                    throws com.liferay.portal.kernel.exception.SystemException;
994    
995            /**
996            * Returns an ordered range of all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63;.
997            *
998            * <p>
999            * 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.
1000            * </p>
1001            *
1002            * @param companyId the company ID
1003            * @param name the name
1004            * @param scope the scope
1005            * @param primKey the prim key
1006            * @param roleId the role ID
1007            * @param start the lower bound of the range of resource permissions
1008            * @param end the upper bound of the range of resource permissions (not inclusive)
1009            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1010            * @return the ordered range of matching resource permissions
1011            * @throws SystemException if a system exception occurred
1012            */
1013            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P_R(
1014                    long companyId, java.lang.String name, int scope,
1015                    java.lang.String primKey, long roleId, int start, int end,
1016                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1017                    throws com.liferay.portal.kernel.exception.SystemException;
1018    
1019            /**
1020            * Returns the first resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63;.
1021            *
1022            * @param companyId the company ID
1023            * @param name the name
1024            * @param scope the scope
1025            * @param primKey the prim key
1026            * @param roleId the role ID
1027            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1028            * @return the first matching resource permission
1029            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
1030            * @throws SystemException if a system exception occurred
1031            */
1032            public com.liferay.portal.model.ResourcePermission findByC_N_S_P_R_First(
1033                    long companyId, java.lang.String name, int scope,
1034                    java.lang.String primKey, long roleId,
1035                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1036                    throws com.liferay.portal.NoSuchResourcePermissionException,
1037                            com.liferay.portal.kernel.exception.SystemException;
1038    
1039            /**
1040            * Returns the first resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63;.
1041            *
1042            * @param companyId the company ID
1043            * @param name the name
1044            * @param scope the scope
1045            * @param primKey the prim key
1046            * @param roleId the role ID
1047            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1048            * @return the first matching resource permission, or <code>null</code> if a matching resource permission could not be found
1049            * @throws SystemException if a system exception occurred
1050            */
1051            public com.liferay.portal.model.ResourcePermission fetchByC_N_S_P_R_First(
1052                    long companyId, java.lang.String name, int scope,
1053                    java.lang.String primKey, long roleId,
1054                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1055                    throws com.liferay.portal.kernel.exception.SystemException;
1056    
1057            /**
1058            * Returns the last resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63;.
1059            *
1060            * @param companyId the company ID
1061            * @param name the name
1062            * @param scope the scope
1063            * @param primKey the prim key
1064            * @param roleId the role ID
1065            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1066            * @return the last matching resource permission
1067            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
1068            * @throws SystemException if a system exception occurred
1069            */
1070            public com.liferay.portal.model.ResourcePermission findByC_N_S_P_R_Last(
1071                    long companyId, java.lang.String name, int scope,
1072                    java.lang.String primKey, long roleId,
1073                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1074                    throws com.liferay.portal.NoSuchResourcePermissionException,
1075                            com.liferay.portal.kernel.exception.SystemException;
1076    
1077            /**
1078            * Returns the last resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63;.
1079            *
1080            * @param companyId the company ID
1081            * @param name the name
1082            * @param scope the scope
1083            * @param primKey the prim key
1084            * @param roleId the role ID
1085            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1086            * @return the last matching resource permission, or <code>null</code> if a matching resource permission could not be found
1087            * @throws SystemException if a system exception occurred
1088            */
1089            public com.liferay.portal.model.ResourcePermission fetchByC_N_S_P_R_Last(
1090                    long companyId, java.lang.String name, int scope,
1091                    java.lang.String primKey, long roleId,
1092                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1093                    throws com.liferay.portal.kernel.exception.SystemException;
1094    
1095            /**
1096            * Returns the resource permissions before and after the current resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63;.
1097            *
1098            * @param resourcePermissionId the primary key of the current resource permission
1099            * @param companyId the company ID
1100            * @param name the name
1101            * @param scope the scope
1102            * @param primKey the prim key
1103            * @param roleId the role ID
1104            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1105            * @return the previous, current, and next resource permission
1106            * @throws com.liferay.portal.NoSuchResourcePermissionException if a resource permission with the primary key could not be found
1107            * @throws SystemException if a system exception occurred
1108            */
1109            public com.liferay.portal.model.ResourcePermission[] findByC_N_S_P_R_PrevAndNext(
1110                    long resourcePermissionId, long companyId, java.lang.String name,
1111                    int scope, java.lang.String primKey, long roleId,
1112                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1113                    throws com.liferay.portal.NoSuchResourcePermissionException,
1114                            com.liferay.portal.kernel.exception.SystemException;
1115    
1116            /**
1117            * Returns all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = any &#63;.
1118            *
1119            * <p>
1120            * 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.
1121            * </p>
1122            *
1123            * @param companyId the company ID
1124            * @param name the name
1125            * @param scope the scope
1126            * @param primKey the prim key
1127            * @param roleIds the role IDs
1128            * @return the matching resource permissions
1129            * @throws SystemException if a system exception occurred
1130            */
1131            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P_R(
1132                    long companyId, java.lang.String name, int scope,
1133                    java.lang.String primKey, long[] roleIds)
1134                    throws com.liferay.portal.kernel.exception.SystemException;
1135    
1136            /**
1137            * Returns a range of all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = any &#63;.
1138            *
1139            * <p>
1140            * 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.
1141            * </p>
1142            *
1143            * @param companyId the company ID
1144            * @param name the name
1145            * @param scope the scope
1146            * @param primKey the prim key
1147            * @param roleIds the role IDs
1148            * @param start the lower bound of the range of resource permissions
1149            * @param end the upper bound of the range of resource permissions (not inclusive)
1150            * @return the range of matching resource permissions
1151            * @throws SystemException if a system exception occurred
1152            */
1153            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P_R(
1154                    long companyId, java.lang.String name, int scope,
1155                    java.lang.String primKey, long[] roleIds, int start, int end)
1156                    throws com.liferay.portal.kernel.exception.SystemException;
1157    
1158            /**
1159            * Returns an ordered range of all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = any &#63;.
1160            *
1161            * <p>
1162            * 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.
1163            * </p>
1164            *
1165            * @param companyId the company ID
1166            * @param name the name
1167            * @param scope the scope
1168            * @param primKey the prim key
1169            * @param roleIds the role IDs
1170            * @param start the lower bound of the range of resource permissions
1171            * @param end the upper bound of the range of resource permissions (not inclusive)
1172            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1173            * @return the ordered range of matching resource permissions
1174            * @throws SystemException if a system exception occurred
1175            */
1176            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P_R(
1177                    long companyId, java.lang.String name, int scope,
1178                    java.lang.String primKey, long[] roleIds, int start, int end,
1179                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1180                    throws com.liferay.portal.kernel.exception.SystemException;
1181    
1182            /**
1183            * Returns all the resource permissions where companyId = &#63; and name = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1184            *
1185            * @param companyId the company ID
1186            * @param name the name
1187            * @param primKey the prim key
1188            * @param roleId the role ID
1189            * @param actionIds the action IDs
1190            * @return the matching resource permissions
1191            * @throws SystemException if a system exception occurred
1192            */
1193            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_P_R_A(
1194                    long companyId, java.lang.String name, java.lang.String primKey,
1195                    long roleId, long actionIds)
1196                    throws com.liferay.portal.kernel.exception.SystemException;
1197    
1198            /**
1199            * Returns a range of all the resource permissions where companyId = &#63; and name = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1200            *
1201            * <p>
1202            * 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.
1203            * </p>
1204            *
1205            * @param companyId the company ID
1206            * @param name the name
1207            * @param primKey the prim key
1208            * @param roleId the role ID
1209            * @param actionIds the action IDs
1210            * @param start the lower bound of the range of resource permissions
1211            * @param end the upper bound of the range of resource permissions (not inclusive)
1212            * @return the range of matching resource permissions
1213            * @throws SystemException if a system exception occurred
1214            */
1215            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_P_R_A(
1216                    long companyId, java.lang.String name, java.lang.String primKey,
1217                    long roleId, long actionIds, int start, int end)
1218                    throws com.liferay.portal.kernel.exception.SystemException;
1219    
1220            /**
1221            * Returns an ordered range of all the resource permissions where companyId = &#63; and name = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1222            *
1223            * <p>
1224            * 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.
1225            * </p>
1226            *
1227            * @param companyId the company ID
1228            * @param name the name
1229            * @param primKey the prim key
1230            * @param roleId the role ID
1231            * @param actionIds the action IDs
1232            * @param start the lower bound of the range of resource permissions
1233            * @param end the upper bound of the range of resource permissions (not inclusive)
1234            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1235            * @return the ordered range of matching resource permissions
1236            * @throws SystemException if a system exception occurred
1237            */
1238            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_P_R_A(
1239                    long companyId, java.lang.String name, java.lang.String primKey,
1240                    long roleId, long actionIds, int start, int end,
1241                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1242                    throws com.liferay.portal.kernel.exception.SystemException;
1243    
1244            /**
1245            * Returns the first resource permission in the ordered set where companyId = &#63; and name = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1246            *
1247            * @param companyId the company ID
1248            * @param name the name
1249            * @param primKey the prim key
1250            * @param roleId the role ID
1251            * @param actionIds the action IDs
1252            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1253            * @return the first matching resource permission
1254            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
1255            * @throws SystemException if a system exception occurred
1256            */
1257            public com.liferay.portal.model.ResourcePermission findByC_N_P_R_A_First(
1258                    long companyId, java.lang.String name, java.lang.String primKey,
1259                    long roleId, long actionIds,
1260                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1261                    throws com.liferay.portal.NoSuchResourcePermissionException,
1262                            com.liferay.portal.kernel.exception.SystemException;
1263    
1264            /**
1265            * Returns the first resource permission in the ordered set where companyId = &#63; and name = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1266            *
1267            * @param companyId the company ID
1268            * @param name the name
1269            * @param primKey the prim key
1270            * @param roleId the role ID
1271            * @param actionIds the action IDs
1272            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1273            * @return the first matching resource permission, or <code>null</code> if a matching resource permission could not be found
1274            * @throws SystemException if a system exception occurred
1275            */
1276            public com.liferay.portal.model.ResourcePermission fetchByC_N_P_R_A_First(
1277                    long companyId, java.lang.String name, java.lang.String primKey,
1278                    long roleId, long actionIds,
1279                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1280                    throws com.liferay.portal.kernel.exception.SystemException;
1281    
1282            /**
1283            * Returns the last resource permission in the ordered set where companyId = &#63; and name = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1284            *
1285            * @param companyId the company ID
1286            * @param name the name
1287            * @param primKey the prim key
1288            * @param roleId the role ID
1289            * @param actionIds the action IDs
1290            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1291            * @return the last matching resource permission
1292            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
1293            * @throws SystemException if a system exception occurred
1294            */
1295            public com.liferay.portal.model.ResourcePermission findByC_N_P_R_A_Last(
1296                    long companyId, java.lang.String name, java.lang.String primKey,
1297                    long roleId, long actionIds,
1298                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1299                    throws com.liferay.portal.NoSuchResourcePermissionException,
1300                            com.liferay.portal.kernel.exception.SystemException;
1301    
1302            /**
1303            * Returns the last resource permission in the ordered set where companyId = &#63; and name = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1304            *
1305            * @param companyId the company ID
1306            * @param name the name
1307            * @param primKey the prim key
1308            * @param roleId the role ID
1309            * @param actionIds the action IDs
1310            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1311            * @return the last matching resource permission, or <code>null</code> if a matching resource permission could not be found
1312            * @throws SystemException if a system exception occurred
1313            */
1314            public com.liferay.portal.model.ResourcePermission fetchByC_N_P_R_A_Last(
1315                    long companyId, java.lang.String name, java.lang.String primKey,
1316                    long roleId, long actionIds,
1317                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1318                    throws com.liferay.portal.kernel.exception.SystemException;
1319    
1320            /**
1321            * Returns the resource permissions before and after the current resource permission in the ordered set where companyId = &#63; and name = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1322            *
1323            * @param resourcePermissionId the primary key of the current resource permission
1324            * @param companyId the company ID
1325            * @param name the name
1326            * @param primKey the prim key
1327            * @param roleId the role ID
1328            * @param actionIds the action IDs
1329            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1330            * @return the previous, current, and next resource permission
1331            * @throws com.liferay.portal.NoSuchResourcePermissionException if a resource permission with the primary key could not be found
1332            * @throws SystemException if a system exception occurred
1333            */
1334            public com.liferay.portal.model.ResourcePermission[] findByC_N_P_R_A_PrevAndNext(
1335                    long resourcePermissionId, long companyId, java.lang.String name,
1336                    java.lang.String primKey, long roleId, long actionIds,
1337                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1338                    throws com.liferay.portal.NoSuchResourcePermissionException,
1339                            com.liferay.portal.kernel.exception.SystemException;
1340    
1341            /**
1342            * Returns all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1343            *
1344            * @param companyId the company ID
1345            * @param name the name
1346            * @param scope the scope
1347            * @param primKey the prim key
1348            * @param roleId the role ID
1349            * @param actionIds the action IDs
1350            * @return the matching resource permissions
1351            * @throws SystemException if a system exception occurred
1352            */
1353            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P_R_A(
1354                    long companyId, java.lang.String name, int scope,
1355                    java.lang.String primKey, long roleId, long actionIds)
1356                    throws com.liferay.portal.kernel.exception.SystemException;
1357    
1358            /**
1359            * Returns a range of all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1360            *
1361            * <p>
1362            * 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.
1363            * </p>
1364            *
1365            * @param companyId the company ID
1366            * @param name the name
1367            * @param scope the scope
1368            * @param primKey the prim key
1369            * @param roleId the role ID
1370            * @param actionIds the action IDs
1371            * @param start the lower bound of the range of resource permissions
1372            * @param end the upper bound of the range of resource permissions (not inclusive)
1373            * @return the range of matching resource permissions
1374            * @throws SystemException if a system exception occurred
1375            */
1376            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P_R_A(
1377                    long companyId, java.lang.String name, int scope,
1378                    java.lang.String primKey, long roleId, long actionIds, int start,
1379                    int end) throws com.liferay.portal.kernel.exception.SystemException;
1380    
1381            /**
1382            * Returns an ordered range of all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1383            *
1384            * <p>
1385            * 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.
1386            * </p>
1387            *
1388            * @param companyId the company ID
1389            * @param name the name
1390            * @param scope the scope
1391            * @param primKey the prim key
1392            * @param roleId the role ID
1393            * @param actionIds the action IDs
1394            * @param start the lower bound of the range of resource permissions
1395            * @param end the upper bound of the range of resource permissions (not inclusive)
1396            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1397            * @return the ordered range of matching resource permissions
1398            * @throws SystemException if a system exception occurred
1399            */
1400            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P_R_A(
1401                    long companyId, java.lang.String name, int scope,
1402                    java.lang.String primKey, long roleId, long actionIds, int start,
1403                    int end,
1404                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1405                    throws com.liferay.portal.kernel.exception.SystemException;
1406    
1407            /**
1408            * Returns the first resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1409            *
1410            * @param companyId the company ID
1411            * @param name the name
1412            * @param scope the scope
1413            * @param primKey the prim key
1414            * @param roleId the role ID
1415            * @param actionIds the action IDs
1416            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1417            * @return the first matching resource permission
1418            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
1419            * @throws SystemException if a system exception occurred
1420            */
1421            public com.liferay.portal.model.ResourcePermission findByC_N_S_P_R_A_First(
1422                    long companyId, java.lang.String name, int scope,
1423                    java.lang.String primKey, long roleId, long actionIds,
1424                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1425                    throws com.liferay.portal.NoSuchResourcePermissionException,
1426                            com.liferay.portal.kernel.exception.SystemException;
1427    
1428            /**
1429            * Returns the first resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1430            *
1431            * @param companyId the company ID
1432            * @param name the name
1433            * @param scope the scope
1434            * @param primKey the prim key
1435            * @param roleId the role ID
1436            * @param actionIds the action IDs
1437            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1438            * @return the first matching resource permission, or <code>null</code> if a matching resource permission could not be found
1439            * @throws SystemException if a system exception occurred
1440            */
1441            public com.liferay.portal.model.ResourcePermission fetchByC_N_S_P_R_A_First(
1442                    long companyId, java.lang.String name, int scope,
1443                    java.lang.String primKey, long roleId, long actionIds,
1444                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1445                    throws com.liferay.portal.kernel.exception.SystemException;
1446    
1447            /**
1448            * Returns the last resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1449            *
1450            * @param companyId the company ID
1451            * @param name the name
1452            * @param scope the scope
1453            * @param primKey the prim key
1454            * @param roleId the role ID
1455            * @param actionIds the action IDs
1456            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1457            * @return the last matching resource permission
1458            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
1459            * @throws SystemException if a system exception occurred
1460            */
1461            public com.liferay.portal.model.ResourcePermission findByC_N_S_P_R_A_Last(
1462                    long companyId, java.lang.String name, int scope,
1463                    java.lang.String primKey, long roleId, long actionIds,
1464                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1465                    throws com.liferay.portal.NoSuchResourcePermissionException,
1466                            com.liferay.portal.kernel.exception.SystemException;
1467    
1468            /**
1469            * Returns the last resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1470            *
1471            * @param companyId the company ID
1472            * @param name the name
1473            * @param scope the scope
1474            * @param primKey the prim key
1475            * @param roleId the role ID
1476            * @param actionIds the action IDs
1477            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1478            * @return the last matching resource permission, or <code>null</code> if a matching resource permission could not be found
1479            * @throws SystemException if a system exception occurred
1480            */
1481            public com.liferay.portal.model.ResourcePermission fetchByC_N_S_P_R_A_Last(
1482                    long companyId, java.lang.String name, int scope,
1483                    java.lang.String primKey, long roleId, long actionIds,
1484                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1485                    throws com.liferay.portal.kernel.exception.SystemException;
1486    
1487            /**
1488            * Returns the resource permissions before and after the current resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1489            *
1490            * @param resourcePermissionId the primary key of the current resource permission
1491            * @param companyId the company ID
1492            * @param name the name
1493            * @param scope the scope
1494            * @param primKey the prim key
1495            * @param roleId the role ID
1496            * @param actionIds the action IDs
1497            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1498            * @return the previous, current, and next resource permission
1499            * @throws com.liferay.portal.NoSuchResourcePermissionException if a resource permission with the primary key could not be found
1500            * @throws SystemException if a system exception occurred
1501            */
1502            public com.liferay.portal.model.ResourcePermission[] findByC_N_S_P_R_A_PrevAndNext(
1503                    long resourcePermissionId, long companyId, java.lang.String name,
1504                    int scope, java.lang.String primKey, long roleId, long actionIds,
1505                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1506                    throws com.liferay.portal.NoSuchResourcePermissionException,
1507                            com.liferay.portal.kernel.exception.SystemException;
1508    
1509            /**
1510            * Returns all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = any &#63; and actionIds = &#63;.
1511            *
1512            * <p>
1513            * 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.
1514            * </p>
1515            *
1516            * @param companyId the company ID
1517            * @param name the name
1518            * @param scope the scope
1519            * @param primKey the prim key
1520            * @param roleIds the role IDs
1521            * @param actionIds the action IDs
1522            * @return the matching resource permissions
1523            * @throws SystemException if a system exception occurred
1524            */
1525            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P_R_A(
1526                    long companyId, java.lang.String name, int scope,
1527                    java.lang.String primKey, long[] roleIds, long actionIds)
1528                    throws com.liferay.portal.kernel.exception.SystemException;
1529    
1530            /**
1531            * Returns a range of all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = any &#63; and actionIds = &#63;.
1532            *
1533            * <p>
1534            * 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.
1535            * </p>
1536            *
1537            * @param companyId the company ID
1538            * @param name the name
1539            * @param scope the scope
1540            * @param primKey the prim key
1541            * @param roleIds the role IDs
1542            * @param actionIds the action IDs
1543            * @param start the lower bound of the range of resource permissions
1544            * @param end the upper bound of the range of resource permissions (not inclusive)
1545            * @return the range of matching resource permissions
1546            * @throws SystemException if a system exception occurred
1547            */
1548            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P_R_A(
1549                    long companyId, java.lang.String name, int scope,
1550                    java.lang.String primKey, long[] roleIds, long actionIds, int start,
1551                    int end) throws com.liferay.portal.kernel.exception.SystemException;
1552    
1553            /**
1554            * Returns an ordered range of all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = any &#63; and actionIds = &#63;.
1555            *
1556            * <p>
1557            * 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.
1558            * </p>
1559            *
1560            * @param companyId the company ID
1561            * @param name the name
1562            * @param scope the scope
1563            * @param primKey the prim key
1564            * @param roleIds the role IDs
1565            * @param actionIds the action IDs
1566            * @param start the lower bound of the range of resource permissions
1567            * @param end the upper bound of the range of resource permissions (not inclusive)
1568            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1569            * @return the ordered range of matching resource permissions
1570            * @throws SystemException if a system exception occurred
1571            */
1572            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P_R_A(
1573                    long companyId, java.lang.String name, int scope,
1574                    java.lang.String primKey, long[] roleIds, long actionIds, int start,
1575                    int end,
1576                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1577                    throws com.liferay.portal.kernel.exception.SystemException;
1578    
1579            /**
1580            * Returns the resource permission where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63; and ownerId = &#63; and actionIds = &#63; or throws a {@link com.liferay.portal.NoSuchResourcePermissionException} if it could not be found.
1581            *
1582            * @param companyId the company ID
1583            * @param name the name
1584            * @param scope the scope
1585            * @param primKey the prim key
1586            * @param roleId the role ID
1587            * @param ownerId the owner ID
1588            * @param actionIds the action IDs
1589            * @return the matching resource permission
1590            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
1591            * @throws SystemException if a system exception occurred
1592            */
1593            public com.liferay.portal.model.ResourcePermission findByC_N_S_P_R_O_A(
1594                    long companyId, java.lang.String name, int scope,
1595                    java.lang.String primKey, long roleId, long ownerId, long actionIds)
1596                    throws com.liferay.portal.NoSuchResourcePermissionException,
1597                            com.liferay.portal.kernel.exception.SystemException;
1598    
1599            /**
1600            * Returns the resource permission where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63; and ownerId = &#63; and actionIds = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
1601            *
1602            * @param companyId the company ID
1603            * @param name the name
1604            * @param scope the scope
1605            * @param primKey the prim key
1606            * @param roleId the role ID
1607            * @param ownerId the owner ID
1608            * @param actionIds the action IDs
1609            * @return the matching resource permission, or <code>null</code> if a matching resource permission could not be found
1610            * @throws SystemException if a system exception occurred
1611            */
1612            public com.liferay.portal.model.ResourcePermission fetchByC_N_S_P_R_O_A(
1613                    long companyId, java.lang.String name, int scope,
1614                    java.lang.String primKey, long roleId, long ownerId, long actionIds)
1615                    throws com.liferay.portal.kernel.exception.SystemException;
1616    
1617            /**
1618            * Returns the resource permission where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63; and ownerId = &#63; and actionIds = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
1619            *
1620            * @param companyId the company ID
1621            * @param name the name
1622            * @param scope the scope
1623            * @param primKey the prim key
1624            * @param roleId the role ID
1625            * @param ownerId the owner ID
1626            * @param actionIds the action IDs
1627            * @param retrieveFromCache whether to use the finder cache
1628            * @return the matching resource permission, or <code>null</code> if a matching resource permission could not be found
1629            * @throws SystemException if a system exception occurred
1630            */
1631            public com.liferay.portal.model.ResourcePermission fetchByC_N_S_P_R_O_A(
1632                    long companyId, java.lang.String name, int scope,
1633                    java.lang.String primKey, long roleId, long ownerId, long actionIds,
1634                    boolean retrieveFromCache)
1635                    throws com.liferay.portal.kernel.exception.SystemException;
1636    
1637            /**
1638            * Returns all the resource permissions.
1639            *
1640            * @return the resource permissions
1641            * @throws SystemException if a system exception occurred
1642            */
1643            public java.util.List<com.liferay.portal.model.ResourcePermission> findAll()
1644                    throws com.liferay.portal.kernel.exception.SystemException;
1645    
1646            /**
1647            * Returns a range of all the resource permissions.
1648            *
1649            * <p>
1650            * 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.
1651            * </p>
1652            *
1653            * @param start the lower bound of the range of resource permissions
1654            * @param end the upper bound of the range of resource permissions (not inclusive)
1655            * @return the range of resource permissions
1656            * @throws SystemException if a system exception occurred
1657            */
1658            public java.util.List<com.liferay.portal.model.ResourcePermission> findAll(
1659                    int start, int end)
1660                    throws com.liferay.portal.kernel.exception.SystemException;
1661    
1662            /**
1663            * Returns an ordered range of all the resource permissions.
1664            *
1665            * <p>
1666            * 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.
1667            * </p>
1668            *
1669            * @param start the lower bound of the range of resource permissions
1670            * @param end the upper bound of the range of resource permissions (not inclusive)
1671            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1672            * @return the ordered range of resource permissions
1673            * @throws SystemException if a system exception occurred
1674            */
1675            public java.util.List<com.liferay.portal.model.ResourcePermission> findAll(
1676                    int start, int end,
1677                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1678                    throws com.liferay.portal.kernel.exception.SystemException;
1679    
1680            /**
1681            * Removes all the resource permissions where scope = &#63; from the database.
1682            *
1683            * @param scope the scope
1684            * @throws SystemException if a system exception occurred
1685            */
1686            public void removeByScope(int scope)
1687                    throws com.liferay.portal.kernel.exception.SystemException;
1688    
1689            /**
1690            * Removes all the resource permissions where roleId = &#63; from the database.
1691            *
1692            * @param roleId the role ID
1693            * @throws SystemException if a system exception occurred
1694            */
1695            public void removeByRoleId(long roleId)
1696                    throws com.liferay.portal.kernel.exception.SystemException;
1697    
1698            /**
1699            * Removes all the resource permissions where companyId = &#63; and primKey LIKE &#63; from the database.
1700            *
1701            * @param companyId the company ID
1702            * @param primKey the prim key
1703            * @throws SystemException if a system exception occurred
1704            */
1705            public void removeByC_P(long companyId, java.lang.String primKey)
1706                    throws com.liferay.portal.kernel.exception.SystemException;
1707    
1708            /**
1709            * Removes all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; from the database.
1710            *
1711            * @param companyId the company ID
1712            * @param name the name
1713            * @param scope the scope
1714            * @throws SystemException if a system exception occurred
1715            */
1716            public void removeByC_N_S(long companyId, java.lang.String name, int scope)
1717                    throws com.liferay.portal.kernel.exception.SystemException;
1718    
1719            /**
1720            * Removes all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; from the database.
1721            *
1722            * @param companyId the company ID
1723            * @param name the name
1724            * @param scope the scope
1725            * @param primKey the prim key
1726            * @throws SystemException if a system exception occurred
1727            */
1728            public void removeByC_N_S_P(long companyId, java.lang.String name,
1729                    int scope, java.lang.String primKey)
1730                    throws com.liferay.portal.kernel.exception.SystemException;
1731    
1732            /**
1733            * Removes all the resource permissions where companyId = &#63; and name = &#63; and primKey = &#63; and ownerId = &#63; from the database.
1734            *
1735            * @param companyId the company ID
1736            * @param name the name
1737            * @param primKey the prim key
1738            * @param ownerId the owner ID
1739            * @throws SystemException if a system exception occurred
1740            */
1741            public void removeByC_N_P_O(long companyId, java.lang.String name,
1742                    java.lang.String primKey, long ownerId)
1743                    throws com.liferay.portal.kernel.exception.SystemException;
1744    
1745            /**
1746            * Removes all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63; from the database.
1747            *
1748            * @param companyId the company ID
1749            * @param name the name
1750            * @param scope the scope
1751            * @param primKey the prim key
1752            * @param roleId the role ID
1753            * @throws SystemException if a system exception occurred
1754            */
1755            public void removeByC_N_S_P_R(long companyId, java.lang.String name,
1756                    int scope, java.lang.String primKey, long roleId)
1757                    throws com.liferay.portal.kernel.exception.SystemException;
1758    
1759            /**
1760            * Removes all the resource permissions where companyId = &#63; and name = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63; from the database.
1761            *
1762            * @param companyId the company ID
1763            * @param name the name
1764            * @param primKey the prim key
1765            * @param roleId the role ID
1766            * @param actionIds the action IDs
1767            * @throws SystemException if a system exception occurred
1768            */
1769            public void removeByC_N_P_R_A(long companyId, java.lang.String name,
1770                    java.lang.String primKey, long roleId, long actionIds)
1771                    throws com.liferay.portal.kernel.exception.SystemException;
1772    
1773            /**
1774            * Removes all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63; from the database.
1775            *
1776            * @param companyId the company ID
1777            * @param name the name
1778            * @param scope the scope
1779            * @param primKey the prim key
1780            * @param roleId the role ID
1781            * @param actionIds the action IDs
1782            * @throws SystemException if a system exception occurred
1783            */
1784            public void removeByC_N_S_P_R_A(long companyId, java.lang.String name,
1785                    int scope, java.lang.String primKey, long roleId, long actionIds)
1786                    throws com.liferay.portal.kernel.exception.SystemException;
1787    
1788            /**
1789            * Removes the resource permission where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63; and ownerId = &#63; and actionIds = &#63; from the database.
1790            *
1791            * @param companyId the company ID
1792            * @param name the name
1793            * @param scope the scope
1794            * @param primKey the prim key
1795            * @param roleId the role ID
1796            * @param ownerId the owner ID
1797            * @param actionIds the action IDs
1798            * @return the resource permission that was removed
1799            * @throws SystemException if a system exception occurred
1800            */
1801            public com.liferay.portal.model.ResourcePermission removeByC_N_S_P_R_O_A(
1802                    long companyId, java.lang.String name, int scope,
1803                    java.lang.String primKey, long roleId, long ownerId, long actionIds)
1804                    throws com.liferay.portal.NoSuchResourcePermissionException,
1805                            com.liferay.portal.kernel.exception.SystemException;
1806    
1807            /**
1808            * Removes all the resource permissions from the database.
1809            *
1810            * @throws SystemException if a system exception occurred
1811            */
1812            public void removeAll()
1813                    throws com.liferay.portal.kernel.exception.SystemException;
1814    
1815            /**
1816            * Returns the number of resource permissions where scope = &#63;.
1817            *
1818            * @param scope the scope
1819            * @return the number of matching resource permissions
1820            * @throws SystemException if a system exception occurred
1821            */
1822            public int countByScope(int scope)
1823                    throws com.liferay.portal.kernel.exception.SystemException;
1824    
1825            /**
1826            * Returns the number of resource permissions where scope = any &#63;.
1827            *
1828            * @param scopes the scopes
1829            * @return the number of matching resource permissions
1830            * @throws SystemException if a system exception occurred
1831            */
1832            public int countByScope(int[] scopes)
1833                    throws com.liferay.portal.kernel.exception.SystemException;
1834    
1835            /**
1836            * Returns the number of resource permissions where roleId = &#63;.
1837            *
1838            * @param roleId the role ID
1839            * @return the number of matching resource permissions
1840            * @throws SystemException if a system exception occurred
1841            */
1842            public int countByRoleId(long roleId)
1843                    throws com.liferay.portal.kernel.exception.SystemException;
1844    
1845            /**
1846            * Returns the number of resource permissions where companyId = &#63; and primKey LIKE &#63;.
1847            *
1848            * @param companyId the company ID
1849            * @param primKey the prim key
1850            * @return the number of matching resource permissions
1851            * @throws SystemException if a system exception occurred
1852            */
1853            public int countByC_P(long companyId, java.lang.String primKey)
1854                    throws com.liferay.portal.kernel.exception.SystemException;
1855    
1856            /**
1857            * Returns the number of resource permissions where companyId = &#63; and name = &#63; and scope = &#63;.
1858            *
1859            * @param companyId the company ID
1860            * @param name the name
1861            * @param scope the scope
1862            * @return the number of matching resource permissions
1863            * @throws SystemException if a system exception occurred
1864            */
1865            public int countByC_N_S(long companyId, java.lang.String name, int scope)
1866                    throws com.liferay.portal.kernel.exception.SystemException;
1867    
1868            /**
1869            * Returns the number of resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63;.
1870            *
1871            * @param companyId the company ID
1872            * @param name the name
1873            * @param scope the scope
1874            * @param primKey the prim key
1875            * @return the number of matching resource permissions
1876            * @throws SystemException if a system exception occurred
1877            */
1878            public int countByC_N_S_P(long companyId, java.lang.String name, int scope,
1879                    java.lang.String primKey)
1880                    throws com.liferay.portal.kernel.exception.SystemException;
1881    
1882            /**
1883            * Returns the number of resource permissions where companyId = &#63; and name = &#63; and primKey = &#63; and ownerId = &#63;.
1884            *
1885            * @param companyId the company ID
1886            * @param name the name
1887            * @param primKey the prim key
1888            * @param ownerId the owner ID
1889            * @return the number of matching resource permissions
1890            * @throws SystemException if a system exception occurred
1891            */
1892            public int countByC_N_P_O(long companyId, java.lang.String name,
1893                    java.lang.String primKey, long ownerId)
1894                    throws com.liferay.portal.kernel.exception.SystemException;
1895    
1896            /**
1897            * Returns the number of resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63;.
1898            *
1899            * @param companyId the company ID
1900            * @param name the name
1901            * @param scope the scope
1902            * @param primKey the prim key
1903            * @param roleId the role ID
1904            * @return the number of matching resource permissions
1905            * @throws SystemException if a system exception occurred
1906            */
1907            public int countByC_N_S_P_R(long companyId, java.lang.String name,
1908                    int scope, java.lang.String primKey, long roleId)
1909                    throws com.liferay.portal.kernel.exception.SystemException;
1910    
1911            /**
1912            * Returns the number of resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = any &#63;.
1913            *
1914            * @param companyId the company ID
1915            * @param name the name
1916            * @param scope the scope
1917            * @param primKey the prim key
1918            * @param roleIds the role IDs
1919            * @return the number of matching resource permissions
1920            * @throws SystemException if a system exception occurred
1921            */
1922            public int countByC_N_S_P_R(long companyId, java.lang.String name,
1923                    int scope, java.lang.String primKey, long[] roleIds)
1924                    throws com.liferay.portal.kernel.exception.SystemException;
1925    
1926            /**
1927            * Returns the number of resource permissions where companyId = &#63; and name = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1928            *
1929            * @param companyId the company ID
1930            * @param name the name
1931            * @param primKey the prim key
1932            * @param roleId the role ID
1933            * @param actionIds the action IDs
1934            * @return the number of matching resource permissions
1935            * @throws SystemException if a system exception occurred
1936            */
1937            public int countByC_N_P_R_A(long companyId, java.lang.String name,
1938                    java.lang.String primKey, long roleId, long actionIds)
1939                    throws com.liferay.portal.kernel.exception.SystemException;
1940    
1941            /**
1942            * Returns the number of resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1943            *
1944            * @param companyId the company ID
1945            * @param name the name
1946            * @param scope the scope
1947            * @param primKey the prim key
1948            * @param roleId the role ID
1949            * @param actionIds the action IDs
1950            * @return the number of matching resource permissions
1951            * @throws SystemException if a system exception occurred
1952            */
1953            public int countByC_N_S_P_R_A(long companyId, java.lang.String name,
1954                    int scope, java.lang.String primKey, long roleId, long actionIds)
1955                    throws com.liferay.portal.kernel.exception.SystemException;
1956    
1957            /**
1958            * Returns the number of resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = any &#63; and actionIds = &#63;.
1959            *
1960            * @param companyId the company ID
1961            * @param name the name
1962            * @param scope the scope
1963            * @param primKey the prim key
1964            * @param roleIds the role IDs
1965            * @param actionIds the action IDs
1966            * @return the number of matching resource permissions
1967            * @throws SystemException if a system exception occurred
1968            */
1969            public int countByC_N_S_P_R_A(long companyId, java.lang.String name,
1970                    int scope, java.lang.String primKey, long[] roleIds, long actionIds)
1971                    throws com.liferay.portal.kernel.exception.SystemException;
1972    
1973            /**
1974            * Returns the number of resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63; and ownerId = &#63; and actionIds = &#63;.
1975            *
1976            * @param companyId the company ID
1977            * @param name the name
1978            * @param scope the scope
1979            * @param primKey the prim key
1980            * @param roleId the role ID
1981            * @param ownerId the owner ID
1982            * @param actionIds the action IDs
1983            * @return the number of matching resource permissions
1984            * @throws SystemException if a system exception occurred
1985            */
1986            public int countByC_N_S_P_R_O_A(long companyId, java.lang.String name,
1987                    int scope, java.lang.String primKey, long roleId, long ownerId,
1988                    long actionIds)
1989                    throws com.liferay.portal.kernel.exception.SystemException;
1990    
1991            /**
1992            * Returns the number of resource permissions.
1993            *
1994            * @return the number of resource permissions
1995            * @throws SystemException if a system exception occurred
1996            */
1997            public int countAll()
1998                    throws com.liferay.portal.kernel.exception.SystemException;
1999    }