1
22
23 package com.liferay.portal.service.persistence;
24
25 import com.liferay.portal.PortalException;
26 import com.liferay.portal.SystemException;
27 import com.liferay.portal.kernel.annotation.Propagation;
28 import com.liferay.portal.kernel.annotation.Transactional;
29
30
36 @Transactional(rollbackFor = {
37 PortalException.class, SystemException.class})
38 public interface RolePersistence extends BasePersistence {
39 public com.liferay.portal.model.Role create(long roleId);
40
41 public com.liferay.portal.model.Role remove(long roleId)
42 throws com.liferay.portal.NoSuchRoleException,
43 com.liferay.portal.SystemException;
44
45 public com.liferay.portal.model.Role remove(
46 com.liferay.portal.model.Role role)
47 throws com.liferay.portal.SystemException;
48
49
52 public com.liferay.portal.model.Role update(
53 com.liferay.portal.model.Role role)
54 throws com.liferay.portal.SystemException;
55
56
69 public com.liferay.portal.model.Role update(
70 com.liferay.portal.model.Role role, boolean merge)
71 throws com.liferay.portal.SystemException;
72
73 public com.liferay.portal.model.Role updateImpl(
74 com.liferay.portal.model.Role role, boolean merge)
75 throws com.liferay.portal.SystemException;
76
77 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
78 public com.liferay.portal.model.Role findByPrimaryKey(long roleId)
79 throws com.liferay.portal.NoSuchRoleException,
80 com.liferay.portal.SystemException;
81
82 public com.liferay.portal.model.Role fetchByPrimaryKey(long roleId)
83 throws com.liferay.portal.SystemException;
84
85 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
86 public java.util.List<com.liferay.portal.model.Role> findByCompanyId(
87 long companyId) throws com.liferay.portal.SystemException;
88
89 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
90 public java.util.List<com.liferay.portal.model.Role> findByCompanyId(
91 long companyId, int start, int end)
92 throws com.liferay.portal.SystemException;
93
94 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
95 public java.util.List<com.liferay.portal.model.Role> findByCompanyId(
96 long companyId, int start, int end,
97 com.liferay.portal.kernel.util.OrderByComparator obc)
98 throws com.liferay.portal.SystemException;
99
100 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
101 public com.liferay.portal.model.Role findByCompanyId_First(long companyId,
102 com.liferay.portal.kernel.util.OrderByComparator obc)
103 throws com.liferay.portal.NoSuchRoleException,
104 com.liferay.portal.SystemException;
105
106 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
107 public com.liferay.portal.model.Role findByCompanyId_Last(long companyId,
108 com.liferay.portal.kernel.util.OrderByComparator obc)
109 throws com.liferay.portal.NoSuchRoleException,
110 com.liferay.portal.SystemException;
111
112 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
113 public com.liferay.portal.model.Role[] findByCompanyId_PrevAndNext(
114 long roleId, long companyId,
115 com.liferay.portal.kernel.util.OrderByComparator obc)
116 throws com.liferay.portal.NoSuchRoleException,
117 com.liferay.portal.SystemException;
118
119 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
120 public com.liferay.portal.model.Role findByC_N(long companyId,
121 java.lang.String name)
122 throws com.liferay.portal.NoSuchRoleException,
123 com.liferay.portal.SystemException;
124
125 public com.liferay.portal.model.Role fetchByC_N(long companyId,
126 java.lang.String name) throws com.liferay.portal.SystemException;
127
128 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
129 public com.liferay.portal.model.Role findByC_C_C(long companyId,
130 long classNameId, long classPK)
131 throws com.liferay.portal.NoSuchRoleException,
132 com.liferay.portal.SystemException;
133
134 public com.liferay.portal.model.Role fetchByC_C_C(long companyId,
135 long classNameId, long classPK)
136 throws com.liferay.portal.SystemException;
137
138 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
139 public java.util.List<Object> findWithDynamicQuery(
140 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
141 throws com.liferay.portal.SystemException;
142
143 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
144 public java.util.List<Object> findWithDynamicQuery(
145 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
146 int end) throws com.liferay.portal.SystemException;
147
148 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
149 public java.util.List<com.liferay.portal.model.Role> findAll()
150 throws com.liferay.portal.SystemException;
151
152 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
153 public java.util.List<com.liferay.portal.model.Role> findAll(int start,
154 int end) throws com.liferay.portal.SystemException;
155
156 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
157 public java.util.List<com.liferay.portal.model.Role> findAll(int start,
158 int end, com.liferay.portal.kernel.util.OrderByComparator obc)
159 throws com.liferay.portal.SystemException;
160
161 public void removeByCompanyId(long companyId)
162 throws com.liferay.portal.SystemException;
163
164 public void removeByC_N(long companyId, java.lang.String name)
165 throws com.liferay.portal.NoSuchRoleException,
166 com.liferay.portal.SystemException;
167
168 public void removeByC_C_C(long companyId, long classNameId, long classPK)
169 throws com.liferay.portal.NoSuchRoleException,
170 com.liferay.portal.SystemException;
171
172 public void removeAll() throws com.liferay.portal.SystemException;
173
174 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
175 public int countByCompanyId(long companyId)
176 throws com.liferay.portal.SystemException;
177
178 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
179 public int countByC_N(long companyId, java.lang.String name)
180 throws com.liferay.portal.SystemException;
181
182 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
183 public int countByC_C_C(long companyId, long classNameId, long classPK)
184 throws com.liferay.portal.SystemException;
185
186 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
187 public int countAll() throws com.liferay.portal.SystemException;
188
189 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
190 public java.util.List<com.liferay.portal.model.Group> getGroups(long pk)
191 throws com.liferay.portal.SystemException;
192
193 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
194 public java.util.List<com.liferay.portal.model.Group> getGroups(long pk,
195 int start, int end) throws com.liferay.portal.SystemException;
196
197 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
198 public java.util.List<com.liferay.portal.model.Group> getGroups(long pk,
199 int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
200 throws com.liferay.portal.SystemException;
201
202 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
203 public int getGroupsSize(long pk) throws com.liferay.portal.SystemException;
204
205 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
206 public boolean containsGroup(long pk, long groupPK)
207 throws com.liferay.portal.SystemException;
208
209 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
210 public boolean containsGroups(long pk)
211 throws com.liferay.portal.SystemException;
212
213 public void addGroup(long pk, long groupPK)
214 throws com.liferay.portal.SystemException;
215
216 public void addGroup(long pk, com.liferay.portal.model.Group group)
217 throws com.liferay.portal.SystemException;
218
219 public void addGroups(long pk, long[] groupPKs)
220 throws com.liferay.portal.SystemException;
221
222 public void addGroups(long pk,
223 java.util.List<com.liferay.portal.model.Group> groups)
224 throws com.liferay.portal.SystemException;
225
226 public void clearGroups(long pk) throws com.liferay.portal.SystemException;
227
228 public void removeGroup(long pk, long groupPK)
229 throws com.liferay.portal.SystemException;
230
231 public void removeGroup(long pk, com.liferay.portal.model.Group group)
232 throws com.liferay.portal.SystemException;
233
234 public void removeGroups(long pk, long[] groupPKs)
235 throws com.liferay.portal.SystemException;
236
237 public void removeGroups(long pk,
238 java.util.List<com.liferay.portal.model.Group> groups)
239 throws com.liferay.portal.SystemException;
240
241 public void setGroups(long pk, long[] groupPKs)
242 throws com.liferay.portal.SystemException;
243
244 public void setGroups(long pk,
245 java.util.List<com.liferay.portal.model.Group> groups)
246 throws com.liferay.portal.SystemException;
247
248 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
249 public java.util.List<com.liferay.portal.model.Permission> getPermissions(
250 long pk) throws com.liferay.portal.SystemException;
251
252 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
253 public java.util.List<com.liferay.portal.model.Permission> getPermissions(
254 long pk, int start, int end) throws com.liferay.portal.SystemException;
255
256 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
257 public java.util.List<com.liferay.portal.model.Permission> getPermissions(
258 long pk, int start, int end,
259 com.liferay.portal.kernel.util.OrderByComparator obc)
260 throws com.liferay.portal.SystemException;
261
262 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
263 public int getPermissionsSize(long pk)
264 throws com.liferay.portal.SystemException;
265
266 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
267 public boolean containsPermission(long pk, long permissionPK)
268 throws com.liferay.portal.SystemException;
269
270 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
271 public boolean containsPermissions(long pk)
272 throws com.liferay.portal.SystemException;
273
274 public void addPermission(long pk, long permissionPK)
275 throws com.liferay.portal.SystemException;
276
277 public void addPermission(long pk,
278 com.liferay.portal.model.Permission permission)
279 throws com.liferay.portal.SystemException;
280
281 public void addPermissions(long pk, long[] permissionPKs)
282 throws com.liferay.portal.SystemException;
283
284 public void addPermissions(long pk,
285 java.util.List<com.liferay.portal.model.Permission> permissions)
286 throws com.liferay.portal.SystemException;
287
288 public void clearPermissions(long pk)
289 throws com.liferay.portal.SystemException;
290
291 public void removePermission(long pk, long permissionPK)
292 throws com.liferay.portal.SystemException;
293
294 public void removePermission(long pk,
295 com.liferay.portal.model.Permission permission)
296 throws com.liferay.portal.SystemException;
297
298 public void removePermissions(long pk, long[] permissionPKs)
299 throws com.liferay.portal.SystemException;
300
301 public void removePermissions(long pk,
302 java.util.List<com.liferay.portal.model.Permission> permissions)
303 throws com.liferay.portal.SystemException;
304
305 public void setPermissions(long pk, long[] permissionPKs)
306 throws com.liferay.portal.SystemException;
307
308 public void setPermissions(long pk,
309 java.util.List<com.liferay.portal.model.Permission> permissions)
310 throws com.liferay.portal.SystemException;
311
312 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
313 public java.util.List<com.liferay.portal.model.User> getUsers(long pk)
314 throws com.liferay.portal.SystemException;
315
316 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
317 public java.util.List<com.liferay.portal.model.User> getUsers(long pk,
318 int start, int end) throws com.liferay.portal.SystemException;
319
320 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
321 public java.util.List<com.liferay.portal.model.User> getUsers(long pk,
322 int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
323 throws com.liferay.portal.SystemException;
324
325 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
326 public int getUsersSize(long pk) throws com.liferay.portal.SystemException;
327
328 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
329 public boolean containsUser(long pk, long userPK)
330 throws com.liferay.portal.SystemException;
331
332 @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
333 public boolean containsUsers(long pk)
334 throws com.liferay.portal.SystemException;
335
336 public void addUser(long pk, long userPK)
337 throws com.liferay.portal.SystemException;
338
339 public void addUser(long pk, com.liferay.portal.model.User user)
340 throws com.liferay.portal.SystemException;
341
342 public void addUsers(long pk, long[] userPKs)
343 throws com.liferay.portal.SystemException;
344
345 public void addUsers(long pk,
346 java.util.List<com.liferay.portal.model.User> users)
347 throws com.liferay.portal.SystemException;
348
349 public void clearUsers(long pk) throws com.liferay.portal.SystemException;
350
351 public void removeUser(long pk, long userPK)
352 throws com.liferay.portal.SystemException;
353
354 public void removeUser(long pk, com.liferay.portal.model.User user)
355 throws com.liferay.portal.SystemException;
356
357 public void removeUsers(long pk, long[] userPKs)
358 throws com.liferay.portal.SystemException;
359
360 public void removeUsers(long pk,
361 java.util.List<com.liferay.portal.model.User> users)
362 throws com.liferay.portal.SystemException;
363
364 public void setUsers(long pk, long[] userPKs)
365 throws com.liferay.portal.SystemException;
366
367 public void setUsers(long pk,
368 java.util.List<com.liferay.portal.model.User> users)
369 throws com.liferay.portal.SystemException;
370 }