001    /**
002     * Copyright (c) 2000-2012 Liferay, Inc. All rights reserved.
003     *
004     * This library is free software; you can redistribute it and/or modify it under
005     * the terms of the GNU Lesser General Public License as published by the Free
006     * Software Foundation; either version 2.1 of the License, or (at your option)
007     * any later version.
008     *
009     * This library is distributed in the hope that it will be useful, but WITHOUT
010     * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
011     * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
012     * details.
013     */
014    
015    package com.liferay.portal.service.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            * <p>
155            * 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.
156            * </p>
157            *
158            * @param scope the scope
159            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
160            * @return the first matching resource permission
161            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
162            * @throws SystemException if a system exception occurred
163            */
164            public com.liferay.portal.model.ResourcePermission findByScope_First(
165                    int scope,
166                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
167                    throws com.liferay.portal.NoSuchResourcePermissionException,
168                            com.liferay.portal.kernel.exception.SystemException;
169    
170            /**
171            * Returns the last resource permission in the ordered set where scope = &#63;.
172            *
173            * <p>
174            * 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.
175            * </p>
176            *
177            * @param scope the scope
178            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
179            * @return the last matching resource permission
180            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
181            * @throws SystemException if a system exception occurred
182            */
183            public com.liferay.portal.model.ResourcePermission findByScope_Last(
184                    int scope,
185                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
186                    throws com.liferay.portal.NoSuchResourcePermissionException,
187                            com.liferay.portal.kernel.exception.SystemException;
188    
189            /**
190            * Returns the resource permissions before and after the current resource permission in the ordered set where scope = &#63;.
191            *
192            * <p>
193            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
194            * </p>
195            *
196            * @param resourcePermissionId the primary key of the current resource permission
197            * @param scope the scope
198            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
199            * @return the previous, current, and next resource permission
200            * @throws com.liferay.portal.NoSuchResourcePermissionException if a resource permission with the primary key could not be found
201            * @throws SystemException if a system exception occurred
202            */
203            public com.liferay.portal.model.ResourcePermission[] findByScope_PrevAndNext(
204                    long resourcePermissionId, int scope,
205                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
206                    throws com.liferay.portal.NoSuchResourcePermissionException,
207                            com.liferay.portal.kernel.exception.SystemException;
208    
209            /**
210            * Returns all the resource permissions where scope = any &#63;.
211            *
212            * <p>
213            * 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.
214            * </p>
215            *
216            * @param scopes the scopes
217            * @return the matching resource permissions
218            * @throws SystemException if a system exception occurred
219            */
220            public java.util.List<com.liferay.portal.model.ResourcePermission> findByScope(
221                    int[] scopes)
222                    throws com.liferay.portal.kernel.exception.SystemException;
223    
224            /**
225            * Returns a range of all the resource permissions where scope = any &#63;.
226            *
227            * <p>
228            * 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.
229            * </p>
230            *
231            * @param scopes the scopes
232            * @param start the lower bound of the range of resource permissions
233            * @param end the upper bound of the range of resource permissions (not inclusive)
234            * @return the range of matching resource permissions
235            * @throws SystemException if a system exception occurred
236            */
237            public java.util.List<com.liferay.portal.model.ResourcePermission> findByScope(
238                    int[] scopes, int start, int end)
239                    throws com.liferay.portal.kernel.exception.SystemException;
240    
241            /**
242            * Returns an ordered range of all the resource permissions where scope = any &#63;.
243            *
244            * <p>
245            * 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.
246            * </p>
247            *
248            * @param scopes the scopes
249            * @param start the lower bound of the range of resource permissions
250            * @param end the upper bound of the range of resource permissions (not inclusive)
251            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
252            * @return the ordered range of matching resource permissions
253            * @throws SystemException if a system exception occurred
254            */
255            public java.util.List<com.liferay.portal.model.ResourcePermission> findByScope(
256                    int[] scopes, int start, int end,
257                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
258                    throws com.liferay.portal.kernel.exception.SystemException;
259    
260            /**
261            * Returns all the resource permissions where roleId = &#63;.
262            *
263            * @param roleId the role ID
264            * @return the matching resource permissions
265            * @throws SystemException if a system exception occurred
266            */
267            public java.util.List<com.liferay.portal.model.ResourcePermission> findByRoleId(
268                    long roleId) throws com.liferay.portal.kernel.exception.SystemException;
269    
270            /**
271            * Returns a range of all the resource permissions where roleId = &#63;.
272            *
273            * <p>
274            * 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.
275            * </p>
276            *
277            * @param roleId the role ID
278            * @param start the lower bound of the range of resource permissions
279            * @param end the upper bound of the range of resource permissions (not inclusive)
280            * @return the range of matching resource permissions
281            * @throws SystemException if a system exception occurred
282            */
283            public java.util.List<com.liferay.portal.model.ResourcePermission> findByRoleId(
284                    long roleId, int start, int end)
285                    throws com.liferay.portal.kernel.exception.SystemException;
286    
287            /**
288            * Returns an ordered range of all the resource permissions where roleId = &#63;.
289            *
290            * <p>
291            * 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.
292            * </p>
293            *
294            * @param roleId the role ID
295            * @param start the lower bound of the range of resource permissions
296            * @param end the upper bound of the range of resource permissions (not inclusive)
297            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
298            * @return the ordered range of matching resource permissions
299            * @throws SystemException if a system exception occurred
300            */
301            public java.util.List<com.liferay.portal.model.ResourcePermission> findByRoleId(
302                    long roleId, int start, int end,
303                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
304                    throws com.liferay.portal.kernel.exception.SystemException;
305    
306            /**
307            * Returns the first resource permission in the ordered set where roleId = &#63;.
308            *
309            * <p>
310            * 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.
311            * </p>
312            *
313            * @param roleId the role ID
314            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
315            * @return the first matching resource permission
316            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
317            * @throws SystemException if a system exception occurred
318            */
319            public com.liferay.portal.model.ResourcePermission findByRoleId_First(
320                    long roleId,
321                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
322                    throws com.liferay.portal.NoSuchResourcePermissionException,
323                            com.liferay.portal.kernel.exception.SystemException;
324    
325            /**
326            * Returns the last resource permission in the ordered set where roleId = &#63;.
327            *
328            * <p>
329            * 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.
330            * </p>
331            *
332            * @param roleId the role ID
333            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
334            * @return the last matching resource permission
335            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
336            * @throws SystemException if a system exception occurred
337            */
338            public com.liferay.portal.model.ResourcePermission findByRoleId_Last(
339                    long roleId,
340                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
341                    throws com.liferay.portal.NoSuchResourcePermissionException,
342                            com.liferay.portal.kernel.exception.SystemException;
343    
344            /**
345            * Returns the resource permissions before and after the current resource permission in the ordered set where roleId = &#63;.
346            *
347            * <p>
348            * 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.
349            * </p>
350            *
351            * @param resourcePermissionId the primary key of the current resource permission
352            * @param roleId the role ID
353            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
354            * @return the previous, current, and next resource permission
355            * @throws com.liferay.portal.NoSuchResourcePermissionException if a resource permission with the primary key could not be found
356            * @throws SystemException if a system exception occurred
357            */
358            public com.liferay.portal.model.ResourcePermission[] findByRoleId_PrevAndNext(
359                    long resourcePermissionId, long roleId,
360                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
361                    throws com.liferay.portal.NoSuchResourcePermissionException,
362                            com.liferay.portal.kernel.exception.SystemException;
363    
364            /**
365            * Returns all the resource permissions where companyId = &#63; and primKey LIKE &#63;.
366            *
367            * @param companyId the company ID
368            * @param primKey the prim key
369            * @return the matching resource permissions
370            * @throws SystemException if a system exception occurred
371            */
372            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_P(
373                    long companyId, java.lang.String primKey)
374                    throws com.liferay.portal.kernel.exception.SystemException;
375    
376            /**
377            * Returns a range of all the resource permissions where companyId = &#63; and primKey LIKE &#63;.
378            *
379            * <p>
380            * 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.
381            * </p>
382            *
383            * @param companyId the company ID
384            * @param primKey the prim key
385            * @param start the lower bound of the range of resource permissions
386            * @param end the upper bound of the range of resource permissions (not inclusive)
387            * @return the range of matching resource permissions
388            * @throws SystemException if a system exception occurred
389            */
390            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_P(
391                    long companyId, java.lang.String primKey, int start, int end)
392                    throws com.liferay.portal.kernel.exception.SystemException;
393    
394            /**
395            * Returns an ordered range of all the resource permissions where companyId = &#63; and primKey LIKE &#63;.
396            *
397            * <p>
398            * 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.
399            * </p>
400            *
401            * @param companyId the company ID
402            * @param primKey the prim key
403            * @param start the lower bound of the range of resource permissions
404            * @param end the upper bound of the range of resource permissions (not inclusive)
405            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
406            * @return the ordered range of matching resource permissions
407            * @throws SystemException if a system exception occurred
408            */
409            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_P(
410                    long companyId, java.lang.String primKey, int start, int end,
411                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
412                    throws com.liferay.portal.kernel.exception.SystemException;
413    
414            /**
415            * Returns the first resource permission in the ordered set where companyId = &#63; and primKey LIKE &#63;.
416            *
417            * <p>
418            * 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.
419            * </p>
420            *
421            * @param companyId the company ID
422            * @param primKey the prim key
423            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
424            * @return the first matching resource permission
425            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
426            * @throws SystemException if a system exception occurred
427            */
428            public com.liferay.portal.model.ResourcePermission findByC_P_First(
429                    long companyId, java.lang.String primKey,
430                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
431                    throws com.liferay.portal.NoSuchResourcePermissionException,
432                            com.liferay.portal.kernel.exception.SystemException;
433    
434            /**
435            * Returns the last resource permission in the ordered set where companyId = &#63; and primKey LIKE &#63;.
436            *
437            * <p>
438            * 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.
439            * </p>
440            *
441            * @param companyId the company ID
442            * @param primKey the prim key
443            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
444            * @return the last matching resource permission
445            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
446            * @throws SystemException if a system exception occurred
447            */
448            public com.liferay.portal.model.ResourcePermission findByC_P_Last(
449                    long companyId, java.lang.String primKey,
450                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
451                    throws com.liferay.portal.NoSuchResourcePermissionException,
452                            com.liferay.portal.kernel.exception.SystemException;
453    
454            /**
455            * Returns the resource permissions before and after the current resource permission in the ordered set where companyId = &#63; and primKey LIKE &#63;.
456            *
457            * <p>
458            * 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.
459            * </p>
460            *
461            * @param resourcePermissionId the primary key of the current resource permission
462            * @param companyId the company ID
463            * @param primKey the prim key
464            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
465            * @return the previous, current, and next resource permission
466            * @throws com.liferay.portal.NoSuchResourcePermissionException if a resource permission with the primary key could not be found
467            * @throws SystemException if a system exception occurred
468            */
469            public com.liferay.portal.model.ResourcePermission[] findByC_P_PrevAndNext(
470                    long resourcePermissionId, long companyId, java.lang.String primKey,
471                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
472                    throws com.liferay.portal.NoSuchResourcePermissionException,
473                            com.liferay.portal.kernel.exception.SystemException;
474    
475            /**
476            * Returns all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63;.
477            *
478            * @param companyId the company ID
479            * @param name the name
480            * @param scope the scope
481            * @return the matching resource permissions
482            * @throws SystemException if a system exception occurred
483            */
484            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S(
485                    long companyId, java.lang.String name, int scope)
486                    throws com.liferay.portal.kernel.exception.SystemException;
487    
488            /**
489            * Returns a range of all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63;.
490            *
491            * <p>
492            * 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.
493            * </p>
494            *
495            * @param companyId the company ID
496            * @param name the name
497            * @param scope the scope
498            * @param start the lower bound of the range of resource permissions
499            * @param end the upper bound of the range of resource permissions (not inclusive)
500            * @return the range of matching resource permissions
501            * @throws SystemException if a system exception occurred
502            */
503            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S(
504                    long companyId, java.lang.String name, int scope, int start, int end)
505                    throws com.liferay.portal.kernel.exception.SystemException;
506    
507            /**
508            * Returns an ordered range of all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63;.
509            *
510            * <p>
511            * 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.
512            * </p>
513            *
514            * @param companyId the company ID
515            * @param name the name
516            * @param scope the scope
517            * @param start the lower bound of the range of resource permissions
518            * @param end the upper bound of the range of resource permissions (not inclusive)
519            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
520            * @return the ordered range of matching resource permissions
521            * @throws SystemException if a system exception occurred
522            */
523            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S(
524                    long companyId, java.lang.String name, int scope, int start, int end,
525                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
526                    throws com.liferay.portal.kernel.exception.SystemException;
527    
528            /**
529            * Returns the first resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63;.
530            *
531            * <p>
532            * 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.
533            * </p>
534            *
535            * @param companyId the company ID
536            * @param name the name
537            * @param scope the scope
538            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
539            * @return the first matching resource permission
540            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
541            * @throws SystemException if a system exception occurred
542            */
543            public com.liferay.portal.model.ResourcePermission findByC_N_S_First(
544                    long companyId, java.lang.String name, int scope,
545                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
546                    throws com.liferay.portal.NoSuchResourcePermissionException,
547                            com.liferay.portal.kernel.exception.SystemException;
548    
549            /**
550            * Returns the last resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63;.
551            *
552            * <p>
553            * 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.
554            * </p>
555            *
556            * @param companyId the company ID
557            * @param name the name
558            * @param scope the scope
559            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
560            * @return the last matching resource permission
561            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
562            * @throws SystemException if a system exception occurred
563            */
564            public com.liferay.portal.model.ResourcePermission findByC_N_S_Last(
565                    long companyId, java.lang.String name, int scope,
566                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
567                    throws com.liferay.portal.NoSuchResourcePermissionException,
568                            com.liferay.portal.kernel.exception.SystemException;
569    
570            /**
571            * Returns the resource permissions before and after the current resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63;.
572            *
573            * <p>
574            * 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.
575            * </p>
576            *
577            * @param resourcePermissionId the primary key of the current resource permission
578            * @param companyId the company ID
579            * @param name the name
580            * @param scope the scope
581            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
582            * @return the previous, current, and next resource permission
583            * @throws com.liferay.portal.NoSuchResourcePermissionException if a resource permission with the primary key could not be found
584            * @throws SystemException if a system exception occurred
585            */
586            public com.liferay.portal.model.ResourcePermission[] findByC_N_S_PrevAndNext(
587                    long resourcePermissionId, long companyId, java.lang.String name,
588                    int scope,
589                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
590                    throws com.liferay.portal.NoSuchResourcePermissionException,
591                            com.liferay.portal.kernel.exception.SystemException;
592    
593            /**
594            * Returns all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63;.
595            *
596            * @param companyId the company ID
597            * @param name the name
598            * @param scope the scope
599            * @param primKey the prim key
600            * @return the matching resource permissions
601            * @throws SystemException if a system exception occurred
602            */
603            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P(
604                    long companyId, java.lang.String name, int scope,
605                    java.lang.String primKey)
606                    throws com.liferay.portal.kernel.exception.SystemException;
607    
608            /**
609            * Returns a range of all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63;.
610            *
611            * <p>
612            * 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.
613            * </p>
614            *
615            * @param companyId the company ID
616            * @param name the name
617            * @param scope the scope
618            * @param primKey the prim key
619            * @param start the lower bound of the range of resource permissions
620            * @param end the upper bound of the range of resource permissions (not inclusive)
621            * @return the range of matching resource permissions
622            * @throws SystemException if a system exception occurred
623            */
624            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P(
625                    long companyId, java.lang.String name, int scope,
626                    java.lang.String primKey, int start, int end)
627                    throws com.liferay.portal.kernel.exception.SystemException;
628    
629            /**
630            * Returns an ordered range of all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63;.
631            *
632            * <p>
633            * 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.
634            * </p>
635            *
636            * @param companyId the company ID
637            * @param name the name
638            * @param scope the scope
639            * @param primKey the prim key
640            * @param start the lower bound of the range of resource permissions
641            * @param end the upper bound of the range of resource permissions (not inclusive)
642            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
643            * @return the ordered range of matching resource permissions
644            * @throws SystemException if a system exception occurred
645            */
646            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P(
647                    long companyId, java.lang.String name, int scope,
648                    java.lang.String primKey, int start, int end,
649                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
650                    throws com.liferay.portal.kernel.exception.SystemException;
651    
652            /**
653            * Returns the first resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63;.
654            *
655            * <p>
656            * 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.
657            * </p>
658            *
659            * @param companyId the company ID
660            * @param name the name
661            * @param scope the scope
662            * @param primKey the prim key
663            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
664            * @return the first matching resource permission
665            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
666            * @throws SystemException if a system exception occurred
667            */
668            public com.liferay.portal.model.ResourcePermission findByC_N_S_P_First(
669                    long companyId, java.lang.String name, int scope,
670                    java.lang.String primKey,
671                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
672                    throws com.liferay.portal.NoSuchResourcePermissionException,
673                            com.liferay.portal.kernel.exception.SystemException;
674    
675            /**
676            * Returns the last resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63;.
677            *
678            * <p>
679            * 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.
680            * </p>
681            *
682            * @param companyId the company ID
683            * @param name the name
684            * @param scope the scope
685            * @param primKey the prim key
686            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
687            * @return the last matching resource permission
688            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
689            * @throws SystemException if a system exception occurred
690            */
691            public com.liferay.portal.model.ResourcePermission findByC_N_S_P_Last(
692                    long companyId, java.lang.String name, int scope,
693                    java.lang.String primKey,
694                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
695                    throws com.liferay.portal.NoSuchResourcePermissionException,
696                            com.liferay.portal.kernel.exception.SystemException;
697    
698            /**
699            * 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;.
700            *
701            * <p>
702            * 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.
703            * </p>
704            *
705            * @param resourcePermissionId the primary key of the current resource permission
706            * @param companyId the company ID
707            * @param name the name
708            * @param scope the scope
709            * @param primKey the prim key
710            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
711            * @return the previous, current, and next resource permission
712            * @throws com.liferay.portal.NoSuchResourcePermissionException if a resource permission with the primary key could not be found
713            * @throws SystemException if a system exception occurred
714            */
715            public com.liferay.portal.model.ResourcePermission[] findByC_N_S_P_PrevAndNext(
716                    long resourcePermissionId, long companyId, java.lang.String name,
717                    int scope, java.lang.String primKey,
718                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
719                    throws com.liferay.portal.NoSuchResourcePermissionException,
720                            com.liferay.portal.kernel.exception.SystemException;
721    
722            /**
723            * Returns all the resource permissions where companyId = &#63; and name = &#63; and primKey = &#63; and ownerId = &#63;.
724            *
725            * @param companyId the company ID
726            * @param name the name
727            * @param primKey the prim key
728            * @param ownerId the owner ID
729            * @return the matching resource permissions
730            * @throws SystemException if a system exception occurred
731            */
732            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_P_O(
733                    long companyId, java.lang.String name, java.lang.String primKey,
734                    long ownerId)
735                    throws com.liferay.portal.kernel.exception.SystemException;
736    
737            /**
738            * Returns a range of all the resource permissions where companyId = &#63; and name = &#63; and primKey = &#63; and ownerId = &#63;.
739            *
740            * <p>
741            * 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.
742            * </p>
743            *
744            * @param companyId the company ID
745            * @param name the name
746            * @param primKey the prim key
747            * @param ownerId the owner ID
748            * @param start the lower bound of the range of resource permissions
749            * @param end the upper bound of the range of resource permissions (not inclusive)
750            * @return the range of matching resource permissions
751            * @throws SystemException if a system exception occurred
752            */
753            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_P_O(
754                    long companyId, java.lang.String name, java.lang.String primKey,
755                    long ownerId, int start, int end)
756                    throws com.liferay.portal.kernel.exception.SystemException;
757    
758            /**
759            * Returns an ordered range of all the resource permissions where companyId = &#63; and name = &#63; and primKey = &#63; and ownerId = &#63;.
760            *
761            * <p>
762            * 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.
763            * </p>
764            *
765            * @param companyId the company ID
766            * @param name the name
767            * @param primKey the prim key
768            * @param ownerId the owner ID
769            * @param start the lower bound of the range of resource permissions
770            * @param end the upper bound of the range of resource permissions (not inclusive)
771            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
772            * @return the ordered range of matching resource permissions
773            * @throws SystemException if a system exception occurred
774            */
775            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_P_O(
776                    long companyId, java.lang.String name, java.lang.String primKey,
777                    long ownerId, int start, int end,
778                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
779                    throws com.liferay.portal.kernel.exception.SystemException;
780    
781            /**
782            * Returns the first resource permission in the ordered set where companyId = &#63; and name = &#63; and primKey = &#63; and ownerId = &#63;.
783            *
784            * <p>
785            * 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.
786            * </p>
787            *
788            * @param companyId the company ID
789            * @param name the name
790            * @param primKey the prim key
791            * @param ownerId the owner ID
792            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
793            * @return the first matching resource permission
794            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
795            * @throws SystemException if a system exception occurred
796            */
797            public com.liferay.portal.model.ResourcePermission findByC_N_P_O_First(
798                    long companyId, java.lang.String name, java.lang.String primKey,
799                    long ownerId,
800                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
801                    throws com.liferay.portal.NoSuchResourcePermissionException,
802                            com.liferay.portal.kernel.exception.SystemException;
803    
804            /**
805            * Returns the last resource permission in the ordered set where companyId = &#63; and name = &#63; and primKey = &#63; and ownerId = &#63;.
806            *
807            * <p>
808            * 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.
809            * </p>
810            *
811            * @param companyId the company ID
812            * @param name the name
813            * @param primKey the prim key
814            * @param ownerId the owner ID
815            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
816            * @return the last matching resource permission
817            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
818            * @throws SystemException if a system exception occurred
819            */
820            public com.liferay.portal.model.ResourcePermission findByC_N_P_O_Last(
821                    long companyId, java.lang.String name, java.lang.String primKey,
822                    long ownerId,
823                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
824                    throws com.liferay.portal.NoSuchResourcePermissionException,
825                            com.liferay.portal.kernel.exception.SystemException;
826    
827            /**
828            * 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;.
829            *
830            * <p>
831            * 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.
832            * </p>
833            *
834            * @param resourcePermissionId the primary key of the current resource permission
835            * @param companyId the company ID
836            * @param name the name
837            * @param primKey the prim key
838            * @param ownerId the owner ID
839            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
840            * @return the previous, current, and next resource permission
841            * @throws com.liferay.portal.NoSuchResourcePermissionException if a resource permission with the primary key could not be found
842            * @throws SystemException if a system exception occurred
843            */
844            public com.liferay.portal.model.ResourcePermission[] findByC_N_P_O_PrevAndNext(
845                    long resourcePermissionId, long companyId, java.lang.String name,
846                    java.lang.String primKey, long ownerId,
847                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
848                    throws com.liferay.portal.NoSuchResourcePermissionException,
849                            com.liferay.portal.kernel.exception.SystemException;
850    
851            /**
852            * Returns all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63;.
853            *
854            * @param companyId the company ID
855            * @param name the name
856            * @param scope the scope
857            * @param primKey the prim key
858            * @param roleId the role ID
859            * @return the matching resource permissions
860            * @throws SystemException if a system exception occurred
861            */
862            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P_R(
863                    long companyId, java.lang.String name, int scope,
864                    java.lang.String primKey, long roleId)
865                    throws com.liferay.portal.kernel.exception.SystemException;
866    
867            /**
868            * Returns a range of all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63;.
869            *
870            * <p>
871            * 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.
872            * </p>
873            *
874            * @param companyId the company ID
875            * @param name the name
876            * @param scope the scope
877            * @param primKey the prim key
878            * @param roleId the role ID
879            * @param start the lower bound of the range of resource permissions
880            * @param end the upper bound of the range of resource permissions (not inclusive)
881            * @return the range of matching resource permissions
882            * @throws SystemException if a system exception occurred
883            */
884            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P_R(
885                    long companyId, java.lang.String name, int scope,
886                    java.lang.String primKey, long roleId, int start, int end)
887                    throws com.liferay.portal.kernel.exception.SystemException;
888    
889            /**
890            * Returns an ordered range of all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63;.
891            *
892            * <p>
893            * 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.
894            * </p>
895            *
896            * @param companyId the company ID
897            * @param name the name
898            * @param scope the scope
899            * @param primKey the prim key
900            * @param roleId the role ID
901            * @param start the lower bound of the range of resource permissions
902            * @param end the upper bound of the range of resource permissions (not inclusive)
903            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
904            * @return the ordered range of matching resource permissions
905            * @throws SystemException if a system exception occurred
906            */
907            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P_R(
908                    long companyId, java.lang.String name, int scope,
909                    java.lang.String primKey, long roleId, int start, int end,
910                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
911                    throws com.liferay.portal.kernel.exception.SystemException;
912    
913            /**
914            * Returns the first resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63;.
915            *
916            * <p>
917            * 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.
918            * </p>
919            *
920            * @param companyId the company ID
921            * @param name the name
922            * @param scope the scope
923            * @param primKey the prim key
924            * @param roleId the role ID
925            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
926            * @return the first matching resource permission
927            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
928            * @throws SystemException if a system exception occurred
929            */
930            public com.liferay.portal.model.ResourcePermission findByC_N_S_P_R_First(
931                    long companyId, java.lang.String name, int scope,
932                    java.lang.String primKey, long roleId,
933                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
934                    throws com.liferay.portal.NoSuchResourcePermissionException,
935                            com.liferay.portal.kernel.exception.SystemException;
936    
937            /**
938            * Returns the last resource permission in the ordered set where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63;.
939            *
940            * <p>
941            * 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.
942            * </p>
943            *
944            * @param companyId the company ID
945            * @param name the name
946            * @param scope the scope
947            * @param primKey the prim key
948            * @param roleId the role ID
949            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
950            * @return the last matching resource permission
951            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
952            * @throws SystemException if a system exception occurred
953            */
954            public com.liferay.portal.model.ResourcePermission findByC_N_S_P_R_Last(
955                    long companyId, java.lang.String name, int scope,
956                    java.lang.String primKey, long roleId,
957                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
958                    throws com.liferay.portal.NoSuchResourcePermissionException,
959                            com.liferay.portal.kernel.exception.SystemException;
960    
961            /**
962            * 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;.
963            *
964            * <p>
965            * 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.
966            * </p>
967            *
968            * @param resourcePermissionId the primary key of the current resource permission
969            * @param companyId the company ID
970            * @param name the name
971            * @param scope the scope
972            * @param primKey the prim key
973            * @param roleId the role ID
974            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
975            * @return the previous, current, and next resource permission
976            * @throws com.liferay.portal.NoSuchResourcePermissionException if a resource permission with the primary key could not be found
977            * @throws SystemException if a system exception occurred
978            */
979            public com.liferay.portal.model.ResourcePermission[] findByC_N_S_P_R_PrevAndNext(
980                    long resourcePermissionId, long companyId, java.lang.String name,
981                    int scope, java.lang.String primKey, long roleId,
982                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
983                    throws com.liferay.portal.NoSuchResourcePermissionException,
984                            com.liferay.portal.kernel.exception.SystemException;
985    
986            /**
987            * Returns all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = any &#63;.
988            *
989            * <p>
990            * 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.
991            * </p>
992            *
993            * @param companyId the company ID
994            * @param name the name
995            * @param scope the scope
996            * @param primKey the prim key
997            * @param roleIds the role IDs
998            * @return the matching resource permissions
999            * @throws SystemException if a system exception occurred
1000            */
1001            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P_R(
1002                    long companyId, java.lang.String name, int scope,
1003                    java.lang.String primKey, long[] roleIds)
1004                    throws com.liferay.portal.kernel.exception.SystemException;
1005    
1006            /**
1007            * Returns a range of all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = any &#63;.
1008            *
1009            * <p>
1010            * 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.
1011            * </p>
1012            *
1013            * @param companyId the company ID
1014            * @param name the name
1015            * @param scope the scope
1016            * @param primKey the prim key
1017            * @param roleIds the role IDs
1018            * @param start the lower bound of the range of resource permissions
1019            * @param end the upper bound of the range of resource permissions (not inclusive)
1020            * @return the range of matching resource permissions
1021            * @throws SystemException if a system exception occurred
1022            */
1023            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P_R(
1024                    long companyId, java.lang.String name, int scope,
1025                    java.lang.String primKey, long[] roleIds, int start, int end)
1026                    throws com.liferay.portal.kernel.exception.SystemException;
1027    
1028            /**
1029            * 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;.
1030            *
1031            * <p>
1032            * 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.
1033            * </p>
1034            *
1035            * @param companyId the company ID
1036            * @param name the name
1037            * @param scope the scope
1038            * @param primKey the prim key
1039            * @param roleIds the role IDs
1040            * @param start the lower bound of the range of resource permissions
1041            * @param end the upper bound of the range of resource permissions (not inclusive)
1042            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1043            * @return the ordered range of matching resource permissions
1044            * @throws SystemException if a system exception occurred
1045            */
1046            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P_R(
1047                    long companyId, java.lang.String name, int scope,
1048                    java.lang.String primKey, long[] roleIds, int start, int end,
1049                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1050                    throws com.liferay.portal.kernel.exception.SystemException;
1051    
1052            /**
1053            * Returns all the resource permissions where companyId = &#63; and name = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1054            *
1055            * @param companyId the company ID
1056            * @param name the name
1057            * @param primKey the prim key
1058            * @param roleId the role ID
1059            * @param actionIds the action IDs
1060            * @return the matching resource permissions
1061            * @throws SystemException if a system exception occurred
1062            */
1063            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_P_R_A(
1064                    long companyId, java.lang.String name, java.lang.String primKey,
1065                    long roleId, long actionIds)
1066                    throws com.liferay.portal.kernel.exception.SystemException;
1067    
1068            /**
1069            * Returns a range of all the resource permissions where companyId = &#63; and name = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1070            *
1071            * <p>
1072            * 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.
1073            * </p>
1074            *
1075            * @param companyId the company ID
1076            * @param name the name
1077            * @param primKey the prim key
1078            * @param roleId the role ID
1079            * @param actionIds the action IDs
1080            * @param start the lower bound of the range of resource permissions
1081            * @param end the upper bound of the range of resource permissions (not inclusive)
1082            * @return the range of matching resource permissions
1083            * @throws SystemException if a system exception occurred
1084            */
1085            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_P_R_A(
1086                    long companyId, java.lang.String name, java.lang.String primKey,
1087                    long roleId, long actionIds, int start, int end)
1088                    throws com.liferay.portal.kernel.exception.SystemException;
1089    
1090            /**
1091            * Returns an ordered range of all the resource permissions where companyId = &#63; and name = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1092            *
1093            * <p>
1094            * 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.
1095            * </p>
1096            *
1097            * @param companyId the company ID
1098            * @param name the name
1099            * @param primKey the prim key
1100            * @param roleId the role ID
1101            * @param actionIds the action IDs
1102            * @param start the lower bound of the range of resource permissions
1103            * @param end the upper bound of the range of resource permissions (not inclusive)
1104            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1105            * @return the ordered range of matching resource permissions
1106            * @throws SystemException if a system exception occurred
1107            */
1108            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_P_R_A(
1109                    long companyId, java.lang.String name, java.lang.String primKey,
1110                    long roleId, long actionIds, int start, int end,
1111                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1112                    throws com.liferay.portal.kernel.exception.SystemException;
1113    
1114            /**
1115            * Returns the first resource permission in the ordered set where companyId = &#63; and name = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1116            *
1117            * <p>
1118            * 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.
1119            * </p>
1120            *
1121            * @param companyId the company ID
1122            * @param name the name
1123            * @param primKey the prim key
1124            * @param roleId the role ID
1125            * @param actionIds the action IDs
1126            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1127            * @return the first matching resource permission
1128            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
1129            * @throws SystemException if a system exception occurred
1130            */
1131            public com.liferay.portal.model.ResourcePermission findByC_N_P_R_A_First(
1132                    long companyId, java.lang.String name, java.lang.String primKey,
1133                    long roleId, long actionIds,
1134                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1135                    throws com.liferay.portal.NoSuchResourcePermissionException,
1136                            com.liferay.portal.kernel.exception.SystemException;
1137    
1138            /**
1139            * Returns the last resource permission in the ordered set where companyId = &#63; and name = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1140            *
1141            * <p>
1142            * 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.
1143            * </p>
1144            *
1145            * @param companyId the company ID
1146            * @param name the name
1147            * @param primKey the prim key
1148            * @param roleId the role ID
1149            * @param actionIds the action IDs
1150            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1151            * @return the last matching resource permission
1152            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
1153            * @throws SystemException if a system exception occurred
1154            */
1155            public com.liferay.portal.model.ResourcePermission findByC_N_P_R_A_Last(
1156                    long companyId, java.lang.String name, java.lang.String primKey,
1157                    long roleId, long actionIds,
1158                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1159                    throws com.liferay.portal.NoSuchResourcePermissionException,
1160                            com.liferay.portal.kernel.exception.SystemException;
1161    
1162            /**
1163            * 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;.
1164            *
1165            * <p>
1166            * 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.
1167            * </p>
1168            *
1169            * @param resourcePermissionId the primary key of the current resource permission
1170            * @param companyId the company ID
1171            * @param name the name
1172            * @param primKey the prim key
1173            * @param roleId the role ID
1174            * @param actionIds the action IDs
1175            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1176            * @return the previous, current, and next resource permission
1177            * @throws com.liferay.portal.NoSuchResourcePermissionException if a resource permission with the primary key could not be found
1178            * @throws SystemException if a system exception occurred
1179            */
1180            public com.liferay.portal.model.ResourcePermission[] findByC_N_P_R_A_PrevAndNext(
1181                    long resourcePermissionId, long companyId, java.lang.String name,
1182                    java.lang.String primKey, long roleId, long actionIds,
1183                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1184                    throws com.liferay.portal.NoSuchResourcePermissionException,
1185                            com.liferay.portal.kernel.exception.SystemException;
1186    
1187            /**
1188            * Returns all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1189            *
1190            * @param companyId the company ID
1191            * @param name the name
1192            * @param scope the scope
1193            * @param primKey the prim key
1194            * @param roleId the role ID
1195            * @param actionIds the action IDs
1196            * @return the matching resource permissions
1197            * @throws SystemException if a system exception occurred
1198            */
1199            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P_R_A(
1200                    long companyId, java.lang.String name, int scope,
1201                    java.lang.String primKey, long roleId, long actionIds)
1202                    throws com.liferay.portal.kernel.exception.SystemException;
1203    
1204            /**
1205            * 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;.
1206            *
1207            * <p>
1208            * 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.
1209            * </p>
1210            *
1211            * @param companyId the company ID
1212            * @param name the name
1213            * @param scope the scope
1214            * @param primKey the prim key
1215            * @param roleId the role ID
1216            * @param actionIds the action IDs
1217            * @param start the lower bound of the range of resource permissions
1218            * @param end the upper bound of the range of resource permissions (not inclusive)
1219            * @return the range of matching resource permissions
1220            * @throws SystemException if a system exception occurred
1221            */
1222            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P_R_A(
1223                    long companyId, java.lang.String name, int scope,
1224                    java.lang.String primKey, long roleId, long actionIds, int start,
1225                    int end) throws com.liferay.portal.kernel.exception.SystemException;
1226    
1227            /**
1228            * 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;.
1229            *
1230            * <p>
1231            * 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.
1232            * </p>
1233            *
1234            * @param companyId the company ID
1235            * @param name the name
1236            * @param scope the scope
1237            * @param primKey the prim key
1238            * @param roleId the role ID
1239            * @param actionIds the action IDs
1240            * @param start the lower bound of the range of resource permissions
1241            * @param end the upper bound of the range of resource permissions (not inclusive)
1242            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1243            * @return the ordered range of matching resource permissions
1244            * @throws SystemException if a system exception occurred
1245            */
1246            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P_R_A(
1247                    long companyId, java.lang.String name, int scope,
1248                    java.lang.String primKey, long roleId, long actionIds, int start,
1249                    int end,
1250                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1251                    throws com.liferay.portal.kernel.exception.SystemException;
1252    
1253            /**
1254            * 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;.
1255            *
1256            * <p>
1257            * 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.
1258            * </p>
1259            *
1260            * @param companyId the company ID
1261            * @param name the name
1262            * @param scope the scope
1263            * @param primKey the prim key
1264            * @param roleId the role ID
1265            * @param actionIds the action IDs
1266            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1267            * @return the first matching resource permission
1268            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
1269            * @throws SystemException if a system exception occurred
1270            */
1271            public com.liferay.portal.model.ResourcePermission findByC_N_S_P_R_A_First(
1272                    long companyId, java.lang.String name, int scope,
1273                    java.lang.String primKey, long roleId, long actionIds,
1274                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1275                    throws com.liferay.portal.NoSuchResourcePermissionException,
1276                            com.liferay.portal.kernel.exception.SystemException;
1277    
1278            /**
1279            * 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;.
1280            *
1281            * <p>
1282            * 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.
1283            * </p>
1284            *
1285            * @param companyId the company ID
1286            * @param name the name
1287            * @param scope the scope
1288            * @param primKey the prim key
1289            * @param roleId the role ID
1290            * @param actionIds the action IDs
1291            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1292            * @return the last matching resource permission
1293            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
1294            * @throws SystemException if a system exception occurred
1295            */
1296            public com.liferay.portal.model.ResourcePermission findByC_N_S_P_R_A_Last(
1297                    long companyId, java.lang.String name, int scope,
1298                    java.lang.String primKey, long roleId, long actionIds,
1299                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1300                    throws com.liferay.portal.NoSuchResourcePermissionException,
1301                            com.liferay.portal.kernel.exception.SystemException;
1302    
1303            /**
1304            * 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;.
1305            *
1306            * <p>
1307            * 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.
1308            * </p>
1309            *
1310            * @param resourcePermissionId the primary key of the current resource permission
1311            * @param companyId the company ID
1312            * @param name the name
1313            * @param scope the scope
1314            * @param primKey the prim key
1315            * @param roleId the role ID
1316            * @param actionIds the action IDs
1317            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1318            * @return the previous, current, and next resource permission
1319            * @throws com.liferay.portal.NoSuchResourcePermissionException if a resource permission with the primary key could not be found
1320            * @throws SystemException if a system exception occurred
1321            */
1322            public com.liferay.portal.model.ResourcePermission[] findByC_N_S_P_R_A_PrevAndNext(
1323                    long resourcePermissionId, long companyId, java.lang.String name,
1324                    int scope, java.lang.String primKey, long roleId, long actionIds,
1325                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1326                    throws com.liferay.portal.NoSuchResourcePermissionException,
1327                            com.liferay.portal.kernel.exception.SystemException;
1328    
1329            /**
1330            * Returns all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = any &#63; and actionIds = &#63;.
1331            *
1332            * <p>
1333            * 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.
1334            * </p>
1335            *
1336            * @param companyId the company ID
1337            * @param name the name
1338            * @param scope the scope
1339            * @param primKey the prim key
1340            * @param roleIds the role IDs
1341            * @param actionIds the action IDs
1342            * @return the matching resource permissions
1343            * @throws SystemException if a system exception occurred
1344            */
1345            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P_R_A(
1346                    long companyId, java.lang.String name, int scope,
1347                    java.lang.String primKey, long[] roleIds, long actionIds)
1348                    throws com.liferay.portal.kernel.exception.SystemException;
1349    
1350            /**
1351            * 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;.
1352            *
1353            * <p>
1354            * 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.
1355            * </p>
1356            *
1357            * @param companyId the company ID
1358            * @param name the name
1359            * @param scope the scope
1360            * @param primKey the prim key
1361            * @param roleIds the role IDs
1362            * @param actionIds the action IDs
1363            * @param start the lower bound of the range of resource permissions
1364            * @param end the upper bound of the range of resource permissions (not inclusive)
1365            * @return the range of matching resource permissions
1366            * @throws SystemException if a system exception occurred
1367            */
1368            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P_R_A(
1369                    long companyId, java.lang.String name, int scope,
1370                    java.lang.String primKey, long[] roleIds, long actionIds, int start,
1371                    int end) throws com.liferay.portal.kernel.exception.SystemException;
1372    
1373            /**
1374            * 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;.
1375            *
1376            * <p>
1377            * 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.
1378            * </p>
1379            *
1380            * @param companyId the company ID
1381            * @param name the name
1382            * @param scope the scope
1383            * @param primKey the prim key
1384            * @param roleIds the role IDs
1385            * @param actionIds the action IDs
1386            * @param start the lower bound of the range of resource permissions
1387            * @param end the upper bound of the range of resource permissions (not inclusive)
1388            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1389            * @return the ordered range of matching resource permissions
1390            * @throws SystemException if a system exception occurred
1391            */
1392            public java.util.List<com.liferay.portal.model.ResourcePermission> findByC_N_S_P_R_A(
1393                    long companyId, java.lang.String name, int scope,
1394                    java.lang.String primKey, long[] roleIds, long actionIds, int start,
1395                    int end,
1396                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1397                    throws com.liferay.portal.kernel.exception.SystemException;
1398    
1399            /**
1400            * 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.
1401            *
1402            * @param companyId the company ID
1403            * @param name the name
1404            * @param scope the scope
1405            * @param primKey the prim key
1406            * @param roleId the role ID
1407            * @param ownerId the owner ID
1408            * @param actionIds the action IDs
1409            * @return the matching resource permission
1410            * @throws com.liferay.portal.NoSuchResourcePermissionException if a matching resource permission could not be found
1411            * @throws SystemException if a system exception occurred
1412            */
1413            public com.liferay.portal.model.ResourcePermission findByC_N_S_P_R_O_A(
1414                    long companyId, java.lang.String name, int scope,
1415                    java.lang.String primKey, long roleId, long ownerId, long actionIds)
1416                    throws com.liferay.portal.NoSuchResourcePermissionException,
1417                            com.liferay.portal.kernel.exception.SystemException;
1418    
1419            /**
1420            * 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.
1421            *
1422            * @param companyId the company ID
1423            * @param name the name
1424            * @param scope the scope
1425            * @param primKey the prim key
1426            * @param roleId the role ID
1427            * @param ownerId the owner ID
1428            * @param actionIds the action IDs
1429            * @return the matching resource permission, or <code>null</code> if a matching resource permission could not be found
1430            * @throws SystemException if a system exception occurred
1431            */
1432            public com.liferay.portal.model.ResourcePermission fetchByC_N_S_P_R_O_A(
1433                    long companyId, java.lang.String name, int scope,
1434                    java.lang.String primKey, long roleId, long ownerId, long actionIds)
1435                    throws com.liferay.portal.kernel.exception.SystemException;
1436    
1437            /**
1438            * 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.
1439            *
1440            * @param companyId the company ID
1441            * @param name the name
1442            * @param scope the scope
1443            * @param primKey the prim key
1444            * @param roleId the role ID
1445            * @param ownerId the owner ID
1446            * @param actionIds the action IDs
1447            * @param retrieveFromCache whether to use the finder cache
1448            * @return the matching resource permission, or <code>null</code> if a matching resource permission could not be found
1449            * @throws SystemException if a system exception occurred
1450            */
1451            public com.liferay.portal.model.ResourcePermission fetchByC_N_S_P_R_O_A(
1452                    long companyId, java.lang.String name, int scope,
1453                    java.lang.String primKey, long roleId, long ownerId, long actionIds,
1454                    boolean retrieveFromCache)
1455                    throws com.liferay.portal.kernel.exception.SystemException;
1456    
1457            /**
1458            * Returns all the resource permissions.
1459            *
1460            * @return the resource permissions
1461            * @throws SystemException if a system exception occurred
1462            */
1463            public java.util.List<com.liferay.portal.model.ResourcePermission> findAll()
1464                    throws com.liferay.portal.kernel.exception.SystemException;
1465    
1466            /**
1467            * Returns a range of all the resource permissions.
1468            *
1469            * <p>
1470            * 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.
1471            * </p>
1472            *
1473            * @param start the lower bound of the range of resource permissions
1474            * @param end the upper bound of the range of resource permissions (not inclusive)
1475            * @return the range of resource permissions
1476            * @throws SystemException if a system exception occurred
1477            */
1478            public java.util.List<com.liferay.portal.model.ResourcePermission> findAll(
1479                    int start, int end)
1480                    throws com.liferay.portal.kernel.exception.SystemException;
1481    
1482            /**
1483            * Returns an ordered range of all the resource permissions.
1484            *
1485            * <p>
1486            * 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.
1487            * </p>
1488            *
1489            * @param start the lower bound of the range of resource permissions
1490            * @param end the upper bound of the range of resource permissions (not inclusive)
1491            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1492            * @return the ordered range of resource permissions
1493            * @throws SystemException if a system exception occurred
1494            */
1495            public java.util.List<com.liferay.portal.model.ResourcePermission> findAll(
1496                    int start, int end,
1497                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1498                    throws com.liferay.portal.kernel.exception.SystemException;
1499    
1500            /**
1501            * Removes all the resource permissions where scope = &#63; from the database.
1502            *
1503            * @param scope the scope
1504            * @throws SystemException if a system exception occurred
1505            */
1506            public void removeByScope(int scope)
1507                    throws com.liferay.portal.kernel.exception.SystemException;
1508    
1509            /**
1510            * Removes all the resource permissions where roleId = &#63; from the database.
1511            *
1512            * @param roleId the role ID
1513            * @throws SystemException if a system exception occurred
1514            */
1515            public void removeByRoleId(long roleId)
1516                    throws com.liferay.portal.kernel.exception.SystemException;
1517    
1518            /**
1519            * Removes all the resource permissions where companyId = &#63; and primKey LIKE &#63; from the database.
1520            *
1521            * @param companyId the company ID
1522            * @param primKey the prim key
1523            * @throws SystemException if a system exception occurred
1524            */
1525            public void removeByC_P(long companyId, java.lang.String primKey)
1526                    throws com.liferay.portal.kernel.exception.SystemException;
1527    
1528            /**
1529            * Removes all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; from the database.
1530            *
1531            * @param companyId the company ID
1532            * @param name the name
1533            * @param scope the scope
1534            * @throws SystemException if a system exception occurred
1535            */
1536            public void removeByC_N_S(long companyId, java.lang.String name, int scope)
1537                    throws com.liferay.portal.kernel.exception.SystemException;
1538    
1539            /**
1540            * Removes all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; from the database.
1541            *
1542            * @param companyId the company ID
1543            * @param name the name
1544            * @param scope the scope
1545            * @param primKey the prim key
1546            * @throws SystemException if a system exception occurred
1547            */
1548            public void removeByC_N_S_P(long companyId, java.lang.String name,
1549                    int scope, java.lang.String primKey)
1550                    throws com.liferay.portal.kernel.exception.SystemException;
1551    
1552            /**
1553            * Removes all the resource permissions where companyId = &#63; and name = &#63; and primKey = &#63; and ownerId = &#63; from the database.
1554            *
1555            * @param companyId the company ID
1556            * @param name the name
1557            * @param primKey the prim key
1558            * @param ownerId the owner ID
1559            * @throws SystemException if a system exception occurred
1560            */
1561            public void removeByC_N_P_O(long companyId, java.lang.String name,
1562                    java.lang.String primKey, long ownerId)
1563                    throws com.liferay.portal.kernel.exception.SystemException;
1564    
1565            /**
1566            * Removes all the resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63; from the database.
1567            *
1568            * @param companyId the company ID
1569            * @param name the name
1570            * @param scope the scope
1571            * @param primKey the prim key
1572            * @param roleId the role ID
1573            * @throws SystemException if a system exception occurred
1574            */
1575            public void removeByC_N_S_P_R(long companyId, java.lang.String name,
1576                    int scope, java.lang.String primKey, long roleId)
1577                    throws com.liferay.portal.kernel.exception.SystemException;
1578    
1579            /**
1580            * Removes all the resource permissions where companyId = &#63; and name = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63; from the database.
1581            *
1582            * @param companyId the company ID
1583            * @param name the name
1584            * @param primKey the prim key
1585            * @param roleId the role ID
1586            * @param actionIds the action IDs
1587            * @throws SystemException if a system exception occurred
1588            */
1589            public void removeByC_N_P_R_A(long companyId, java.lang.String name,
1590                    java.lang.String primKey, long roleId, long actionIds)
1591                    throws com.liferay.portal.kernel.exception.SystemException;
1592    
1593            /**
1594            * 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.
1595            *
1596            * @param companyId the company ID
1597            * @param name the name
1598            * @param scope the scope
1599            * @param primKey the prim key
1600            * @param roleId the role ID
1601            * @param actionIds the action IDs
1602            * @throws SystemException if a system exception occurred
1603            */
1604            public void removeByC_N_S_P_R_A(long companyId, java.lang.String name,
1605                    int scope, java.lang.String primKey, long roleId, long actionIds)
1606                    throws com.liferay.portal.kernel.exception.SystemException;
1607    
1608            /**
1609            * 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.
1610            *
1611            * @param companyId the company ID
1612            * @param name the name
1613            * @param scope the scope
1614            * @param primKey the prim key
1615            * @param roleId the role ID
1616            * @param ownerId the owner ID
1617            * @param actionIds the action IDs
1618            * @throws SystemException if a system exception occurred
1619            */
1620            public void removeByC_N_S_P_R_O_A(long companyId, java.lang.String name,
1621                    int scope, java.lang.String primKey, long roleId, long ownerId,
1622                    long actionIds)
1623                    throws com.liferay.portal.NoSuchResourcePermissionException,
1624                            com.liferay.portal.kernel.exception.SystemException;
1625    
1626            /**
1627            * Removes all the resource permissions from the database.
1628            *
1629            * @throws SystemException if a system exception occurred
1630            */
1631            public void removeAll()
1632                    throws com.liferay.portal.kernel.exception.SystemException;
1633    
1634            /**
1635            * Returns the number of resource permissions where scope = &#63;.
1636            *
1637            * @param scope the scope
1638            * @return the number of matching resource permissions
1639            * @throws SystemException if a system exception occurred
1640            */
1641            public int countByScope(int scope)
1642                    throws com.liferay.portal.kernel.exception.SystemException;
1643    
1644            /**
1645            * Returns the number of resource permissions where scope = any &#63;.
1646            *
1647            * @param scopes the scopes
1648            * @return the number of matching resource permissions
1649            * @throws SystemException if a system exception occurred
1650            */
1651            public int countByScope(int[] scopes)
1652                    throws com.liferay.portal.kernel.exception.SystemException;
1653    
1654            /**
1655            * Returns the number of resource permissions where roleId = &#63;.
1656            *
1657            * @param roleId the role ID
1658            * @return the number of matching resource permissions
1659            * @throws SystemException if a system exception occurred
1660            */
1661            public int countByRoleId(long roleId)
1662                    throws com.liferay.portal.kernel.exception.SystemException;
1663    
1664            /**
1665            * Returns the number of resource permissions where companyId = &#63; and primKey LIKE &#63;.
1666            *
1667            * @param companyId the company ID
1668            * @param primKey the prim key
1669            * @return the number of matching resource permissions
1670            * @throws SystemException if a system exception occurred
1671            */
1672            public int countByC_P(long companyId, java.lang.String primKey)
1673                    throws com.liferay.portal.kernel.exception.SystemException;
1674    
1675            /**
1676            * Returns the number of resource permissions where companyId = &#63; and name = &#63; and scope = &#63;.
1677            *
1678            * @param companyId the company ID
1679            * @param name the name
1680            * @param scope the scope
1681            * @return the number of matching resource permissions
1682            * @throws SystemException if a system exception occurred
1683            */
1684            public int countByC_N_S(long companyId, java.lang.String name, int scope)
1685                    throws com.liferay.portal.kernel.exception.SystemException;
1686    
1687            /**
1688            * Returns the number of resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63;.
1689            *
1690            * @param companyId the company ID
1691            * @param name the name
1692            * @param scope the scope
1693            * @param primKey the prim key
1694            * @return the number of matching resource permissions
1695            * @throws SystemException if a system exception occurred
1696            */
1697            public int countByC_N_S_P(long companyId, java.lang.String name, int scope,
1698                    java.lang.String primKey)
1699                    throws com.liferay.portal.kernel.exception.SystemException;
1700    
1701            /**
1702            * Returns the number of resource permissions where companyId = &#63; and name = &#63; and primKey = &#63; and ownerId = &#63;.
1703            *
1704            * @param companyId the company ID
1705            * @param name the name
1706            * @param primKey the prim key
1707            * @param ownerId the owner ID
1708            * @return the number of matching resource permissions
1709            * @throws SystemException if a system exception occurred
1710            */
1711            public int countByC_N_P_O(long companyId, java.lang.String name,
1712                    java.lang.String primKey, long ownerId)
1713                    throws com.liferay.portal.kernel.exception.SystemException;
1714    
1715            /**
1716            * Returns the number of resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63;.
1717            *
1718            * @param companyId the company ID
1719            * @param name the name
1720            * @param scope the scope
1721            * @param primKey the prim key
1722            * @param roleId the role ID
1723            * @return the number of matching resource permissions
1724            * @throws SystemException if a system exception occurred
1725            */
1726            public int countByC_N_S_P_R(long companyId, java.lang.String name,
1727                    int scope, java.lang.String primKey, long roleId)
1728                    throws com.liferay.portal.kernel.exception.SystemException;
1729    
1730            /**
1731            * Returns the number of resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = any &#63;.
1732            *
1733            * @param companyId the company ID
1734            * @param name the name
1735            * @param scope the scope
1736            * @param primKey the prim key
1737            * @param roleIds the role IDs
1738            * @return the number of matching resource permissions
1739            * @throws SystemException if a system exception occurred
1740            */
1741            public int countByC_N_S_P_R(long companyId, java.lang.String name,
1742                    int scope, java.lang.String primKey, long[] roleIds)
1743                    throws com.liferay.portal.kernel.exception.SystemException;
1744    
1745            /**
1746            * Returns the number of resource permissions where companyId = &#63; and name = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1747            *
1748            * @param companyId the company ID
1749            * @param name the name
1750            * @param primKey the prim key
1751            * @param roleId the role ID
1752            * @param actionIds the action IDs
1753            * @return the number of matching resource permissions
1754            * @throws SystemException if a system exception occurred
1755            */
1756            public int countByC_N_P_R_A(long companyId, java.lang.String name,
1757                    java.lang.String primKey, long roleId, long actionIds)
1758                    throws com.liferay.portal.kernel.exception.SystemException;
1759    
1760            /**
1761            * Returns the number of resource permissions where companyId = &#63; and name = &#63; and scope = &#63; and primKey = &#63; and roleId = &#63; and actionIds = &#63;.
1762            *
1763            * @param companyId the company ID
1764            * @param name the name
1765            * @param scope the scope
1766            * @param primKey the prim key
1767            * @param roleId the role ID
1768            * @param actionIds the action IDs
1769            * @return the number of matching resource permissions
1770            * @throws SystemException if a system exception occurred
1771            */
1772            public int countByC_N_S_P_R_A(long companyId, java.lang.String name,
1773                    int scope, java.lang.String primKey, long roleId, long actionIds)
1774                    throws com.liferay.portal.kernel.exception.SystemException;
1775    
1776            /**
1777            * 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;.
1778            *
1779            * @param companyId the company ID
1780            * @param name the name
1781            * @param scope the scope
1782            * @param primKey the prim key
1783            * @param roleIds the role IDs
1784            * @param actionIds the action IDs
1785            * @return the number of matching resource permissions
1786            * @throws SystemException if a system exception occurred
1787            */
1788            public int countByC_N_S_P_R_A(long companyId, java.lang.String name,
1789                    int scope, java.lang.String primKey, long[] roleIds, long actionIds)
1790                    throws com.liferay.portal.kernel.exception.SystemException;
1791    
1792            /**
1793            * 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;.
1794            *
1795            * @param companyId the company ID
1796            * @param name the name
1797            * @param scope the scope
1798            * @param primKey the prim key
1799            * @param roleId the role ID
1800            * @param ownerId the owner ID
1801            * @param actionIds the action IDs
1802            * @return the number of matching resource permissions
1803            * @throws SystemException if a system exception occurred
1804            */
1805            public int countByC_N_S_P_R_O_A(long companyId, java.lang.String name,
1806                    int scope, java.lang.String primKey, long roleId, long ownerId,
1807                    long actionIds)
1808                    throws com.liferay.portal.kernel.exception.SystemException;
1809    
1810            /**
1811            * Returns the number of resource permissions.
1812            *
1813            * @return the number of resource permissions
1814            * @throws SystemException if a system exception occurred
1815            */
1816            public int countAll()
1817                    throws com.liferay.portal.kernel.exception.SystemException;
1818    }