1   /**
2    * Copyright (c) 2000-2010 Liferay, Inc. All rights reserved.
3    *
4    * This library is free software; you can redistribute it and/or modify it under
5    * the terms of the GNU Lesser General Public License as published by the Free
6    * Software Foundation; either version 2.1 of the License, or (at your option)
7    * any later version.
8    *
9    * This library is distributed in the hope that it will be useful, but WITHOUT
10   * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
11   * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
12   * details.
13   */
14  
15  package com.liferay.portal.service.persistence;
16  
17  import com.liferay.portal.model.Role;
18  
19  /**
20   * <a href="RolePersistence.java.html"><b><i>View Source</i></b></a>
21   *
22   * <p>
23   * ServiceBuilder generated this class. Modifications in this class will be
24   * overwritten the next time is generated.
25   * </p>
26   *
27   * @author    Brian Wing Shun Chan
28   * @see       RolePersistenceImpl
29   * @see       RoleUtil
30   * @generated
31   */
32  public interface RolePersistence extends BasePersistence<Role> {
33      public void cacheResult(com.liferay.portal.model.Role role);
34  
35      public void cacheResult(java.util.List<com.liferay.portal.model.Role> roles);
36  
37      public com.liferay.portal.model.Role create(long roleId);
38  
39      public com.liferay.portal.model.Role remove(long roleId)
40          throws com.liferay.portal.NoSuchRoleException,
41              com.liferay.portal.kernel.exception.SystemException;
42  
43      public com.liferay.portal.model.Role updateImpl(
44          com.liferay.portal.model.Role role, boolean merge)
45          throws com.liferay.portal.kernel.exception.SystemException;
46  
47      public com.liferay.portal.model.Role findByPrimaryKey(long roleId)
48          throws com.liferay.portal.NoSuchRoleException,
49              com.liferay.portal.kernel.exception.SystemException;
50  
51      public com.liferay.portal.model.Role fetchByPrimaryKey(long roleId)
52          throws com.liferay.portal.kernel.exception.SystemException;
53  
54      public java.util.List<com.liferay.portal.model.Role> findByCompanyId(
55          long companyId)
56          throws com.liferay.portal.kernel.exception.SystemException;
57  
58      public java.util.List<com.liferay.portal.model.Role> findByCompanyId(
59          long companyId, int start, int end)
60          throws com.liferay.portal.kernel.exception.SystemException;
61  
62      public java.util.List<com.liferay.portal.model.Role> findByCompanyId(
63          long companyId, int start, int end,
64          com.liferay.portal.kernel.util.OrderByComparator obc)
65          throws com.liferay.portal.kernel.exception.SystemException;
66  
67      public com.liferay.portal.model.Role findByCompanyId_First(long companyId,
68          com.liferay.portal.kernel.util.OrderByComparator obc)
69          throws com.liferay.portal.NoSuchRoleException,
70              com.liferay.portal.kernel.exception.SystemException;
71  
72      public com.liferay.portal.model.Role findByCompanyId_Last(long companyId,
73          com.liferay.portal.kernel.util.OrderByComparator obc)
74          throws com.liferay.portal.NoSuchRoleException,
75              com.liferay.portal.kernel.exception.SystemException;
76  
77      public com.liferay.portal.model.Role[] findByCompanyId_PrevAndNext(
78          long roleId, long companyId,
79          com.liferay.portal.kernel.util.OrderByComparator obc)
80          throws com.liferay.portal.NoSuchRoleException,
81              com.liferay.portal.kernel.exception.SystemException;
82  
83      public java.util.List<com.liferay.portal.model.Role> findBySubtype(
84          java.lang.String subtype)
85          throws com.liferay.portal.kernel.exception.SystemException;
86  
87      public java.util.List<com.liferay.portal.model.Role> findBySubtype(
88          java.lang.String subtype, int start, int end)
89          throws com.liferay.portal.kernel.exception.SystemException;
90  
91      public java.util.List<com.liferay.portal.model.Role> findBySubtype(
92          java.lang.String subtype, int start, int end,
93          com.liferay.portal.kernel.util.OrderByComparator obc)
94          throws com.liferay.portal.kernel.exception.SystemException;
95  
96      public com.liferay.portal.model.Role findBySubtype_First(
97          java.lang.String subtype,
98          com.liferay.portal.kernel.util.OrderByComparator obc)
99          throws com.liferay.portal.NoSuchRoleException,
100             com.liferay.portal.kernel.exception.SystemException;
101 
102     public com.liferay.portal.model.Role findBySubtype_Last(
103         java.lang.String subtype,
104         com.liferay.portal.kernel.util.OrderByComparator obc)
105         throws com.liferay.portal.NoSuchRoleException,
106             com.liferay.portal.kernel.exception.SystemException;
107 
108     public com.liferay.portal.model.Role[] findBySubtype_PrevAndNext(
109         long roleId, java.lang.String subtype,
110         com.liferay.portal.kernel.util.OrderByComparator obc)
111         throws com.liferay.portal.NoSuchRoleException,
112             com.liferay.portal.kernel.exception.SystemException;
113 
114     public com.liferay.portal.model.Role findByC_N(long companyId,
115         java.lang.String name)
116         throws com.liferay.portal.NoSuchRoleException,
117             com.liferay.portal.kernel.exception.SystemException;
118 
119     public com.liferay.portal.model.Role fetchByC_N(long companyId,
120         java.lang.String name)
121         throws com.liferay.portal.kernel.exception.SystemException;
122 
123     public com.liferay.portal.model.Role fetchByC_N(long companyId,
124         java.lang.String name, boolean retrieveFromCache)
125         throws com.liferay.portal.kernel.exception.SystemException;
126 
127     public java.util.List<com.liferay.portal.model.Role> findByT_S(int type,
128         java.lang.String subtype)
129         throws com.liferay.portal.kernel.exception.SystemException;
130 
131     public java.util.List<com.liferay.portal.model.Role> findByT_S(int type,
132         java.lang.String subtype, int start, int end)
133         throws com.liferay.portal.kernel.exception.SystemException;
134 
135     public java.util.List<com.liferay.portal.model.Role> findByT_S(int type,
136         java.lang.String subtype, int start, int end,
137         com.liferay.portal.kernel.util.OrderByComparator obc)
138         throws com.liferay.portal.kernel.exception.SystemException;
139 
140     public com.liferay.portal.model.Role findByT_S_First(int type,
141         java.lang.String subtype,
142         com.liferay.portal.kernel.util.OrderByComparator obc)
143         throws com.liferay.portal.NoSuchRoleException,
144             com.liferay.portal.kernel.exception.SystemException;
145 
146     public com.liferay.portal.model.Role findByT_S_Last(int type,
147         java.lang.String subtype,
148         com.liferay.portal.kernel.util.OrderByComparator obc)
149         throws com.liferay.portal.NoSuchRoleException,
150             com.liferay.portal.kernel.exception.SystemException;
151 
152     public com.liferay.portal.model.Role[] findByT_S_PrevAndNext(long roleId,
153         int type, java.lang.String subtype,
154         com.liferay.portal.kernel.util.OrderByComparator obc)
155         throws com.liferay.portal.NoSuchRoleException,
156             com.liferay.portal.kernel.exception.SystemException;
157 
158     public com.liferay.portal.model.Role findByC_C_C(long companyId,
159         long classNameId, long classPK)
160         throws com.liferay.portal.NoSuchRoleException,
161             com.liferay.portal.kernel.exception.SystemException;
162 
163     public com.liferay.portal.model.Role fetchByC_C_C(long companyId,
164         long classNameId, long classPK)
165         throws com.liferay.portal.kernel.exception.SystemException;
166 
167     public com.liferay.portal.model.Role fetchByC_C_C(long companyId,
168         long classNameId, long classPK, boolean retrieveFromCache)
169         throws com.liferay.portal.kernel.exception.SystemException;
170 
171     public java.util.List<com.liferay.portal.model.Role> findAll()
172         throws com.liferay.portal.kernel.exception.SystemException;
173 
174     public java.util.List<com.liferay.portal.model.Role> findAll(int start,
175         int end) throws com.liferay.portal.kernel.exception.SystemException;
176 
177     public java.util.List<com.liferay.portal.model.Role> findAll(int start,
178         int end, com.liferay.portal.kernel.util.OrderByComparator obc)
179         throws com.liferay.portal.kernel.exception.SystemException;
180 
181     public void removeByCompanyId(long companyId)
182         throws com.liferay.portal.kernel.exception.SystemException;
183 
184     public void removeBySubtype(java.lang.String subtype)
185         throws com.liferay.portal.kernel.exception.SystemException;
186 
187     public void removeByC_N(long companyId, java.lang.String name)
188         throws com.liferay.portal.NoSuchRoleException,
189             com.liferay.portal.kernel.exception.SystemException;
190 
191     public void removeByT_S(int type, java.lang.String subtype)
192         throws com.liferay.portal.kernel.exception.SystemException;
193 
194     public void removeByC_C_C(long companyId, long classNameId, long classPK)
195         throws com.liferay.portal.NoSuchRoleException,
196             com.liferay.portal.kernel.exception.SystemException;
197 
198     public void removeAll()
199         throws com.liferay.portal.kernel.exception.SystemException;
200 
201     public int countByCompanyId(long companyId)
202         throws com.liferay.portal.kernel.exception.SystemException;
203 
204     public int countBySubtype(java.lang.String subtype)
205         throws com.liferay.portal.kernel.exception.SystemException;
206 
207     public int countByC_N(long companyId, java.lang.String name)
208         throws com.liferay.portal.kernel.exception.SystemException;
209 
210     public int countByT_S(int type, java.lang.String subtype)
211         throws com.liferay.portal.kernel.exception.SystemException;
212 
213     public int countByC_C_C(long companyId, long classNameId, long classPK)
214         throws com.liferay.portal.kernel.exception.SystemException;
215 
216     public int countAll()
217         throws com.liferay.portal.kernel.exception.SystemException;
218 
219     public java.util.List<com.liferay.portal.model.Group> getGroups(long pk)
220         throws com.liferay.portal.kernel.exception.SystemException;
221 
222     public java.util.List<com.liferay.portal.model.Group> getGroups(long pk,
223         int start, int end)
224         throws com.liferay.portal.kernel.exception.SystemException;
225 
226     public java.util.List<com.liferay.portal.model.Group> getGroups(long pk,
227         int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
228         throws com.liferay.portal.kernel.exception.SystemException;
229 
230     public int getGroupsSize(long pk)
231         throws com.liferay.portal.kernel.exception.SystemException;
232 
233     public boolean containsGroup(long pk, long groupPK)
234         throws com.liferay.portal.kernel.exception.SystemException;
235 
236     public boolean containsGroups(long pk)
237         throws com.liferay.portal.kernel.exception.SystemException;
238 
239     public void addGroup(long pk, long groupPK)
240         throws com.liferay.portal.kernel.exception.SystemException;
241 
242     public void addGroup(long pk, com.liferay.portal.model.Group group)
243         throws com.liferay.portal.kernel.exception.SystemException;
244 
245     public void addGroups(long pk, long[] groupPKs)
246         throws com.liferay.portal.kernel.exception.SystemException;
247 
248     public void addGroups(long pk,
249         java.util.List<com.liferay.portal.model.Group> groups)
250         throws com.liferay.portal.kernel.exception.SystemException;
251 
252     public void clearGroups(long pk)
253         throws com.liferay.portal.kernel.exception.SystemException;
254 
255     public void removeGroup(long pk, long groupPK)
256         throws com.liferay.portal.kernel.exception.SystemException;
257 
258     public void removeGroup(long pk, com.liferay.portal.model.Group group)
259         throws com.liferay.portal.kernel.exception.SystemException;
260 
261     public void removeGroups(long pk, long[] groupPKs)
262         throws com.liferay.portal.kernel.exception.SystemException;
263 
264     public void removeGroups(long pk,
265         java.util.List<com.liferay.portal.model.Group> groups)
266         throws com.liferay.portal.kernel.exception.SystemException;
267 
268     public void setGroups(long pk, long[] groupPKs)
269         throws com.liferay.portal.kernel.exception.SystemException;
270 
271     public void setGroups(long pk,
272         java.util.List<com.liferay.portal.model.Group> groups)
273         throws com.liferay.portal.kernel.exception.SystemException;
274 
275     public java.util.List<com.liferay.portal.model.Permission> getPermissions(
276         long pk) throws com.liferay.portal.kernel.exception.SystemException;
277 
278     public java.util.List<com.liferay.portal.model.Permission> getPermissions(
279         long pk, int start, int end)
280         throws com.liferay.portal.kernel.exception.SystemException;
281 
282     public java.util.List<com.liferay.portal.model.Permission> getPermissions(
283         long pk, int start, int end,
284         com.liferay.portal.kernel.util.OrderByComparator obc)
285         throws com.liferay.portal.kernel.exception.SystemException;
286 
287     public int getPermissionsSize(long pk)
288         throws com.liferay.portal.kernel.exception.SystemException;
289 
290     public boolean containsPermission(long pk, long permissionPK)
291         throws com.liferay.portal.kernel.exception.SystemException;
292 
293     public boolean containsPermissions(long pk)
294         throws com.liferay.portal.kernel.exception.SystemException;
295 
296     public void addPermission(long pk, long permissionPK)
297         throws com.liferay.portal.kernel.exception.SystemException;
298 
299     public void addPermission(long pk,
300         com.liferay.portal.model.Permission permission)
301         throws com.liferay.portal.kernel.exception.SystemException;
302 
303     public void addPermissions(long pk, long[] permissionPKs)
304         throws com.liferay.portal.kernel.exception.SystemException;
305 
306     public void addPermissions(long pk,
307         java.util.List<com.liferay.portal.model.Permission> permissions)
308         throws com.liferay.portal.kernel.exception.SystemException;
309 
310     public void clearPermissions(long pk)
311         throws com.liferay.portal.kernel.exception.SystemException;
312 
313     public void removePermission(long pk, long permissionPK)
314         throws com.liferay.portal.kernel.exception.SystemException;
315 
316     public void removePermission(long pk,
317         com.liferay.portal.model.Permission permission)
318         throws com.liferay.portal.kernel.exception.SystemException;
319 
320     public void removePermissions(long pk, long[] permissionPKs)
321         throws com.liferay.portal.kernel.exception.SystemException;
322 
323     public void removePermissions(long pk,
324         java.util.List<com.liferay.portal.model.Permission> permissions)
325         throws com.liferay.portal.kernel.exception.SystemException;
326 
327     public void setPermissions(long pk, long[] permissionPKs)
328         throws com.liferay.portal.kernel.exception.SystemException;
329 
330     public void setPermissions(long pk,
331         java.util.List<com.liferay.portal.model.Permission> permissions)
332         throws com.liferay.portal.kernel.exception.SystemException;
333 
334     public java.util.List<com.liferay.portal.model.User> getUsers(long pk)
335         throws com.liferay.portal.kernel.exception.SystemException;
336 
337     public java.util.List<com.liferay.portal.model.User> getUsers(long pk,
338         int start, int end)
339         throws com.liferay.portal.kernel.exception.SystemException;
340 
341     public java.util.List<com.liferay.portal.model.User> getUsers(long pk,
342         int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
343         throws com.liferay.portal.kernel.exception.SystemException;
344 
345     public int getUsersSize(long pk)
346         throws com.liferay.portal.kernel.exception.SystemException;
347 
348     public boolean containsUser(long pk, long userPK)
349         throws com.liferay.portal.kernel.exception.SystemException;
350 
351     public boolean containsUsers(long pk)
352         throws com.liferay.portal.kernel.exception.SystemException;
353 
354     public void addUser(long pk, long userPK)
355         throws com.liferay.portal.kernel.exception.SystemException;
356 
357     public void addUser(long pk, com.liferay.portal.model.User user)
358         throws com.liferay.portal.kernel.exception.SystemException;
359 
360     public void addUsers(long pk, long[] userPKs)
361         throws com.liferay.portal.kernel.exception.SystemException;
362 
363     public void addUsers(long pk,
364         java.util.List<com.liferay.portal.model.User> users)
365         throws com.liferay.portal.kernel.exception.SystemException;
366 
367     public void clearUsers(long pk)
368         throws com.liferay.portal.kernel.exception.SystemException;
369 
370     public void removeUser(long pk, long userPK)
371         throws com.liferay.portal.kernel.exception.SystemException;
372 
373     public void removeUser(long pk, com.liferay.portal.model.User user)
374         throws com.liferay.portal.kernel.exception.SystemException;
375 
376     public void removeUsers(long pk, long[] userPKs)
377         throws com.liferay.portal.kernel.exception.SystemException;
378 
379     public void removeUsers(long pk,
380         java.util.List<com.liferay.portal.model.User> users)
381         throws com.liferay.portal.kernel.exception.SystemException;
382 
383     public void setUsers(long pk, long[] userPKs)
384         throws com.liferay.portal.kernel.exception.SystemException;
385 
386     public void setUsers(long pk,
387         java.util.List<com.liferay.portal.model.User> users)
388         throws com.liferay.portal.kernel.exception.SystemException;
389 }