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