001    /**
002     * Copyright (c) 2000-2013 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.ResourceTypePermission;
018    
019    /**
020     * The persistence interface for the resource type 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 ResourceTypePermissionPersistenceImpl
028     * @see ResourceTypePermissionUtil
029     * @generated
030     */
031    public interface ResourceTypePermissionPersistence extends BasePersistence<ResourceTypePermission> {
032            /*
033             * NOTE FOR DEVELOPERS:
034             *
035             * Never modify or reference this interface directly. Always use {@link ResourceTypePermissionUtil} to access the resource type permission persistence. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this interface.
036             */
037    
038            /**
039            * Returns all the resource type permissions where roleId = &#63;.
040            *
041            * @param roleId the role ID
042            * @return the matching resource type permissions
043            * @throws SystemException if a system exception occurred
044            */
045            public java.util.List<com.liferay.portal.model.ResourceTypePermission> findByRoleId(
046                    long roleId) throws com.liferay.portal.kernel.exception.SystemException;
047    
048            /**
049            * Returns a range of all the resource type permissions where roleId = &#63;.
050            *
051            * <p>
052            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.ResourceTypePermissionModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
053            * </p>
054            *
055            * @param roleId the role ID
056            * @param start the lower bound of the range of resource type permissions
057            * @param end the upper bound of the range of resource type permissions (not inclusive)
058            * @return the range of matching resource type permissions
059            * @throws SystemException if a system exception occurred
060            */
061            public java.util.List<com.liferay.portal.model.ResourceTypePermission> findByRoleId(
062                    long roleId, int start, int end)
063                    throws com.liferay.portal.kernel.exception.SystemException;
064    
065            /**
066            * Returns an ordered range of all the resource type permissions where roleId = &#63;.
067            *
068            * <p>
069            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.ResourceTypePermissionModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
070            * </p>
071            *
072            * @param roleId the role ID
073            * @param start the lower bound of the range of resource type permissions
074            * @param end the upper bound of the range of resource type permissions (not inclusive)
075            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
076            * @return the ordered range of matching resource type permissions
077            * @throws SystemException if a system exception occurred
078            */
079            public java.util.List<com.liferay.portal.model.ResourceTypePermission> findByRoleId(
080                    long roleId, int start, int end,
081                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
082                    throws com.liferay.portal.kernel.exception.SystemException;
083    
084            /**
085            * Returns the first resource type permission in the ordered set where roleId = &#63;.
086            *
087            * @param roleId the role ID
088            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
089            * @return the first matching resource type permission
090            * @throws com.liferay.portal.NoSuchResourceTypePermissionException if a matching resource type permission could not be found
091            * @throws SystemException if a system exception occurred
092            */
093            public com.liferay.portal.model.ResourceTypePermission findByRoleId_First(
094                    long roleId,
095                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
096                    throws com.liferay.portal.NoSuchResourceTypePermissionException,
097                            com.liferay.portal.kernel.exception.SystemException;
098    
099            /**
100            * Returns the first resource type permission in the ordered set where roleId = &#63;.
101            *
102            * @param roleId the role ID
103            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
104            * @return the first matching resource type permission, or <code>null</code> if a matching resource type permission could not be found
105            * @throws SystemException if a system exception occurred
106            */
107            public com.liferay.portal.model.ResourceTypePermission fetchByRoleId_First(
108                    long roleId,
109                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
110                    throws com.liferay.portal.kernel.exception.SystemException;
111    
112            /**
113            * Returns the last resource type permission in the ordered set where roleId = &#63;.
114            *
115            * @param roleId the role ID
116            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
117            * @return the last matching resource type permission
118            * @throws com.liferay.portal.NoSuchResourceTypePermissionException if a matching resource type permission could not be found
119            * @throws SystemException if a system exception occurred
120            */
121            public com.liferay.portal.model.ResourceTypePermission findByRoleId_Last(
122                    long roleId,
123                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
124                    throws com.liferay.portal.NoSuchResourceTypePermissionException,
125                            com.liferay.portal.kernel.exception.SystemException;
126    
127            /**
128            * Returns the last resource type permission in the ordered set where roleId = &#63;.
129            *
130            * @param roleId the role ID
131            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
132            * @return the last matching resource type permission, or <code>null</code> if a matching resource type permission could not be found
133            * @throws SystemException if a system exception occurred
134            */
135            public com.liferay.portal.model.ResourceTypePermission fetchByRoleId_Last(
136                    long roleId,
137                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
138                    throws com.liferay.portal.kernel.exception.SystemException;
139    
140            /**
141            * Returns the resource type permissions before and after the current resource type permission in the ordered set where roleId = &#63;.
142            *
143            * @param resourceTypePermissionId the primary key of the current resource type permission
144            * @param roleId the role ID
145            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
146            * @return the previous, current, and next resource type permission
147            * @throws com.liferay.portal.NoSuchResourceTypePermissionException if a resource type permission with the primary key could not be found
148            * @throws SystemException if a system exception occurred
149            */
150            public com.liferay.portal.model.ResourceTypePermission[] findByRoleId_PrevAndNext(
151                    long resourceTypePermissionId, long roleId,
152                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
153                    throws com.liferay.portal.NoSuchResourceTypePermissionException,
154                            com.liferay.portal.kernel.exception.SystemException;
155    
156            /**
157            * Removes all the resource type permissions where roleId = &#63; from the database.
158            *
159            * @param roleId the role ID
160            * @throws SystemException if a system exception occurred
161            */
162            public void removeByRoleId(long roleId)
163                    throws com.liferay.portal.kernel.exception.SystemException;
164    
165            /**
166            * Returns the number of resource type permissions where roleId = &#63;.
167            *
168            * @param roleId the role ID
169            * @return the number of matching resource type permissions
170            * @throws SystemException if a system exception occurred
171            */
172            public int countByRoleId(long roleId)
173                    throws com.liferay.portal.kernel.exception.SystemException;
174    
175            /**
176            * Returns all the resource type permissions where companyId = &#63; and name = &#63; and roleId = &#63;.
177            *
178            * @param companyId the company ID
179            * @param name the name
180            * @param roleId the role ID
181            * @return the matching resource type permissions
182            * @throws SystemException if a system exception occurred
183            */
184            public java.util.List<com.liferay.portal.model.ResourceTypePermission> findByC_N_R(
185                    long companyId, java.lang.String name, long roleId)
186                    throws com.liferay.portal.kernel.exception.SystemException;
187    
188            /**
189            * Returns a range of all the resource type permissions where companyId = &#63; and name = &#63; and roleId = &#63;.
190            *
191            * <p>
192            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.ResourceTypePermissionModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
193            * </p>
194            *
195            * @param companyId the company ID
196            * @param name the name
197            * @param roleId the role ID
198            * @param start the lower bound of the range of resource type permissions
199            * @param end the upper bound of the range of resource type permissions (not inclusive)
200            * @return the range of matching resource type permissions
201            * @throws SystemException if a system exception occurred
202            */
203            public java.util.List<com.liferay.portal.model.ResourceTypePermission> findByC_N_R(
204                    long companyId, java.lang.String name, long roleId, int start, int end)
205                    throws com.liferay.portal.kernel.exception.SystemException;
206    
207            /**
208            * Returns an ordered range of all the resource type permissions where companyId = &#63; and name = &#63; and roleId = &#63;.
209            *
210            * <p>
211            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.ResourceTypePermissionModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
212            * </p>
213            *
214            * @param companyId the company ID
215            * @param name the name
216            * @param roleId the role ID
217            * @param start the lower bound of the range of resource type permissions
218            * @param end the upper bound of the range of resource type permissions (not inclusive)
219            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
220            * @return the ordered range of matching resource type permissions
221            * @throws SystemException if a system exception occurred
222            */
223            public java.util.List<com.liferay.portal.model.ResourceTypePermission> findByC_N_R(
224                    long companyId, java.lang.String name, long roleId, int start, int end,
225                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
226                    throws com.liferay.portal.kernel.exception.SystemException;
227    
228            /**
229            * Returns the first resource type permission in the ordered set where companyId = &#63; and name = &#63; and roleId = &#63;.
230            *
231            * @param companyId the company ID
232            * @param name the name
233            * @param roleId the role ID
234            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
235            * @return the first matching resource type permission
236            * @throws com.liferay.portal.NoSuchResourceTypePermissionException if a matching resource type permission could not be found
237            * @throws SystemException if a system exception occurred
238            */
239            public com.liferay.portal.model.ResourceTypePermission findByC_N_R_First(
240                    long companyId, java.lang.String name, long roleId,
241                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
242                    throws com.liferay.portal.NoSuchResourceTypePermissionException,
243                            com.liferay.portal.kernel.exception.SystemException;
244    
245            /**
246            * Returns the first resource type permission in the ordered set where companyId = &#63; and name = &#63; and roleId = &#63;.
247            *
248            * @param companyId the company ID
249            * @param name the name
250            * @param roleId the role ID
251            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
252            * @return the first matching resource type permission, or <code>null</code> if a matching resource type permission could not be found
253            * @throws SystemException if a system exception occurred
254            */
255            public com.liferay.portal.model.ResourceTypePermission fetchByC_N_R_First(
256                    long companyId, java.lang.String name, long roleId,
257                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
258                    throws com.liferay.portal.kernel.exception.SystemException;
259    
260            /**
261            * Returns the last resource type permission in the ordered set where companyId = &#63; and name = &#63; and roleId = &#63;.
262            *
263            * @param companyId the company ID
264            * @param name the name
265            * @param roleId the role ID
266            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
267            * @return the last matching resource type permission
268            * @throws com.liferay.portal.NoSuchResourceTypePermissionException if a matching resource type permission could not be found
269            * @throws SystemException if a system exception occurred
270            */
271            public com.liferay.portal.model.ResourceTypePermission findByC_N_R_Last(
272                    long companyId, java.lang.String name, long roleId,
273                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
274                    throws com.liferay.portal.NoSuchResourceTypePermissionException,
275                            com.liferay.portal.kernel.exception.SystemException;
276    
277            /**
278            * Returns the last resource type permission in the ordered set where companyId = &#63; and name = &#63; and roleId = &#63;.
279            *
280            * @param companyId the company ID
281            * @param name the name
282            * @param roleId the role ID
283            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
284            * @return the last matching resource type permission, or <code>null</code> if a matching resource type permission could not be found
285            * @throws SystemException if a system exception occurred
286            */
287            public com.liferay.portal.model.ResourceTypePermission fetchByC_N_R_Last(
288                    long companyId, java.lang.String name, long roleId,
289                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
290                    throws com.liferay.portal.kernel.exception.SystemException;
291    
292            /**
293            * Returns the resource type permissions before and after the current resource type permission in the ordered set where companyId = &#63; and name = &#63; and roleId = &#63;.
294            *
295            * @param resourceTypePermissionId the primary key of the current resource type permission
296            * @param companyId the company ID
297            * @param name the name
298            * @param roleId the role ID
299            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
300            * @return the previous, current, and next resource type permission
301            * @throws com.liferay.portal.NoSuchResourceTypePermissionException if a resource type permission with the primary key could not be found
302            * @throws SystemException if a system exception occurred
303            */
304            public com.liferay.portal.model.ResourceTypePermission[] findByC_N_R_PrevAndNext(
305                    long resourceTypePermissionId, long companyId, java.lang.String name,
306                    long roleId,
307                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
308                    throws com.liferay.portal.NoSuchResourceTypePermissionException,
309                            com.liferay.portal.kernel.exception.SystemException;
310    
311            /**
312            * Removes all the resource type permissions where companyId = &#63; and name = &#63; and roleId = &#63; from the database.
313            *
314            * @param companyId the company ID
315            * @param name the name
316            * @param roleId the role ID
317            * @throws SystemException if a system exception occurred
318            */
319            public void removeByC_N_R(long companyId, java.lang.String name, long roleId)
320                    throws com.liferay.portal.kernel.exception.SystemException;
321    
322            /**
323            * Returns the number of resource type permissions where companyId = &#63; and name = &#63; and roleId = &#63;.
324            *
325            * @param companyId the company ID
326            * @param name the name
327            * @param roleId the role ID
328            * @return the number of matching resource type permissions
329            * @throws SystemException if a system exception occurred
330            */
331            public int countByC_N_R(long companyId, java.lang.String name, long roleId)
332                    throws com.liferay.portal.kernel.exception.SystemException;
333    
334            /**
335            * Returns the resource type permission where companyId = &#63; and groupId = &#63; and name = &#63; and roleId = &#63; or throws a {@link com.liferay.portal.NoSuchResourceTypePermissionException} if it could not be found.
336            *
337            * @param companyId the company ID
338            * @param groupId the group ID
339            * @param name the name
340            * @param roleId the role ID
341            * @return the matching resource type permission
342            * @throws com.liferay.portal.NoSuchResourceTypePermissionException if a matching resource type permission could not be found
343            * @throws SystemException if a system exception occurred
344            */
345            public com.liferay.portal.model.ResourceTypePermission findByC_G_N_R(
346                    long companyId, long groupId, java.lang.String name, long roleId)
347                    throws com.liferay.portal.NoSuchResourceTypePermissionException,
348                            com.liferay.portal.kernel.exception.SystemException;
349    
350            /**
351            * Returns the resource type permission where companyId = &#63; and groupId = &#63; and name = &#63; and roleId = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
352            *
353            * @param companyId the company ID
354            * @param groupId the group ID
355            * @param name the name
356            * @param roleId the role ID
357            * @return the matching resource type permission, or <code>null</code> if a matching resource type permission could not be found
358            * @throws SystemException if a system exception occurred
359            */
360            public com.liferay.portal.model.ResourceTypePermission fetchByC_G_N_R(
361                    long companyId, long groupId, java.lang.String name, long roleId)
362                    throws com.liferay.portal.kernel.exception.SystemException;
363    
364            /**
365            * Returns the resource type permission where companyId = &#63; and groupId = &#63; and name = &#63; and roleId = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
366            *
367            * @param companyId the company ID
368            * @param groupId the group ID
369            * @param name the name
370            * @param roleId the role ID
371            * @param retrieveFromCache whether to use the finder cache
372            * @return the matching resource type permission, or <code>null</code> if a matching resource type permission could not be found
373            * @throws SystemException if a system exception occurred
374            */
375            public com.liferay.portal.model.ResourceTypePermission fetchByC_G_N_R(
376                    long companyId, long groupId, java.lang.String name, long roleId,
377                    boolean retrieveFromCache)
378                    throws com.liferay.portal.kernel.exception.SystemException;
379    
380            /**
381            * Removes the resource type permission where companyId = &#63; and groupId = &#63; and name = &#63; and roleId = &#63; from the database.
382            *
383            * @param companyId the company ID
384            * @param groupId the group ID
385            * @param name the name
386            * @param roleId the role ID
387            * @return the resource type permission that was removed
388            * @throws SystemException if a system exception occurred
389            */
390            public com.liferay.portal.model.ResourceTypePermission removeByC_G_N_R(
391                    long companyId, long groupId, java.lang.String name, long roleId)
392                    throws com.liferay.portal.NoSuchResourceTypePermissionException,
393                            com.liferay.portal.kernel.exception.SystemException;
394    
395            /**
396            * Returns the number of resource type permissions where companyId = &#63; and groupId = &#63; and name = &#63; and roleId = &#63;.
397            *
398            * @param companyId the company ID
399            * @param groupId the group ID
400            * @param name the name
401            * @param roleId the role ID
402            * @return the number of matching resource type permissions
403            * @throws SystemException if a system exception occurred
404            */
405            public int countByC_G_N_R(long companyId, long groupId,
406                    java.lang.String name, long roleId)
407                    throws com.liferay.portal.kernel.exception.SystemException;
408    
409            /**
410            * Caches the resource type permission in the entity cache if it is enabled.
411            *
412            * @param resourceTypePermission the resource type permission
413            */
414            public void cacheResult(
415                    com.liferay.portal.model.ResourceTypePermission resourceTypePermission);
416    
417            /**
418            * Caches the resource type permissions in the entity cache if it is enabled.
419            *
420            * @param resourceTypePermissions the resource type permissions
421            */
422            public void cacheResult(
423                    java.util.List<com.liferay.portal.model.ResourceTypePermission> resourceTypePermissions);
424    
425            /**
426            * Creates a new resource type permission with the primary key. Does not add the resource type permission to the database.
427            *
428            * @param resourceTypePermissionId the primary key for the new resource type permission
429            * @return the new resource type permission
430            */
431            public com.liferay.portal.model.ResourceTypePermission create(
432                    long resourceTypePermissionId);
433    
434            /**
435            * Removes the resource type permission with the primary key from the database. Also notifies the appropriate model listeners.
436            *
437            * @param resourceTypePermissionId the primary key of the resource type permission
438            * @return the resource type permission that was removed
439            * @throws com.liferay.portal.NoSuchResourceTypePermissionException if a resource type permission with the primary key could not be found
440            * @throws SystemException if a system exception occurred
441            */
442            public com.liferay.portal.model.ResourceTypePermission remove(
443                    long resourceTypePermissionId)
444                    throws com.liferay.portal.NoSuchResourceTypePermissionException,
445                            com.liferay.portal.kernel.exception.SystemException;
446    
447            public com.liferay.portal.model.ResourceTypePermission updateImpl(
448                    com.liferay.portal.model.ResourceTypePermission resourceTypePermission)
449                    throws com.liferay.portal.kernel.exception.SystemException;
450    
451            /**
452            * Returns the resource type permission with the primary key or throws a {@link com.liferay.portal.NoSuchResourceTypePermissionException} if it could not be found.
453            *
454            * @param resourceTypePermissionId the primary key of the resource type permission
455            * @return the resource type permission
456            * @throws com.liferay.portal.NoSuchResourceTypePermissionException if a resource type permission with the primary key could not be found
457            * @throws SystemException if a system exception occurred
458            */
459            public com.liferay.portal.model.ResourceTypePermission findByPrimaryKey(
460                    long resourceTypePermissionId)
461                    throws com.liferay.portal.NoSuchResourceTypePermissionException,
462                            com.liferay.portal.kernel.exception.SystemException;
463    
464            /**
465            * Returns the resource type permission with the primary key or returns <code>null</code> if it could not be found.
466            *
467            * @param resourceTypePermissionId the primary key of the resource type permission
468            * @return the resource type permission, or <code>null</code> if a resource type permission with the primary key could not be found
469            * @throws SystemException if a system exception occurred
470            */
471            public com.liferay.portal.model.ResourceTypePermission fetchByPrimaryKey(
472                    long resourceTypePermissionId)
473                    throws com.liferay.portal.kernel.exception.SystemException;
474    
475            /**
476            * Returns all the resource type permissions.
477            *
478            * @return the resource type permissions
479            * @throws SystemException if a system exception occurred
480            */
481            public java.util.List<com.liferay.portal.model.ResourceTypePermission> findAll()
482                    throws com.liferay.portal.kernel.exception.SystemException;
483    
484            /**
485            * Returns a range of all the resource type permissions.
486            *
487            * <p>
488            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.ResourceTypePermissionModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
489            * </p>
490            *
491            * @param start the lower bound of the range of resource type permissions
492            * @param end the upper bound of the range of resource type permissions (not inclusive)
493            * @return the range of resource type permissions
494            * @throws SystemException if a system exception occurred
495            */
496            public java.util.List<com.liferay.portal.model.ResourceTypePermission> findAll(
497                    int start, int end)
498                    throws com.liferay.portal.kernel.exception.SystemException;
499    
500            /**
501            * Returns an ordered range of all the resource type permissions.
502            *
503            * <p>
504            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.ResourceTypePermissionModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
505            * </p>
506            *
507            * @param start the lower bound of the range of resource type permissions
508            * @param end the upper bound of the range of resource type permissions (not inclusive)
509            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
510            * @return the ordered range of resource type permissions
511            * @throws SystemException if a system exception occurred
512            */
513            public java.util.List<com.liferay.portal.model.ResourceTypePermission> findAll(
514                    int start, int end,
515                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
516                    throws com.liferay.portal.kernel.exception.SystemException;
517    
518            /**
519            * Removes all the resource type permissions from the database.
520            *
521            * @throws SystemException if a system exception occurred
522            */
523            public void removeAll()
524                    throws com.liferay.portal.kernel.exception.SystemException;
525    
526            /**
527            * Returns the number of resource type permissions.
528            *
529            * @return the number of resource type permissions
530            * @throws SystemException if a system exception occurred
531            */
532            public int countAll()
533                    throws com.liferay.portal.kernel.exception.SystemException;
534    }