001    /**
002     * Copyright (c) 2000-2011 Liferay, Inc. All rights reserved.
003     *
004     * The contents of this file are subject to the terms of the Liferay Enterprise
005     * Subscription License ("License"). You may not use this file except in
006     * compliance with the License. You can obtain a copy of the License by
007     * contacting Liferay, Inc. See the License for the specific language governing
008     * permissions and limitations under the License, including but not limited to
009     * distribution rights of the Software.
010     *
011     *
012     *
013     */
014    
015    package com.liferay.portal.service.persistence;
016    
017    import com.liferay.portal.kernel.exception.SystemException;
018    import com.liferay.portal.model.Group;
019    
020    /**
021     * The persistence interface for the group service.
022     *
023     * <p>
024     * Caching information and settings can be found in <code>portal.properties</code>
025     * </p>
026     *
027     * @author Brian Wing Shun Chan
028     * @see GroupPersistenceImpl
029     * @see GroupUtil
030     * @generated
031     */
032    public interface GroupPersistence extends BasePersistence<Group> {
033            /*
034             * NOTE FOR DEVELOPERS:
035             *
036             * Never modify or reference this interface directly. Always use {@link GroupUtil} to access the group persistence. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this interface.
037             */
038    
039            /**
040            * Caches the group in the entity cache if it is enabled.
041            *
042            * @param group the group to cache
043            */
044            public void cacheResult(com.liferay.portal.model.Group group);
045    
046            /**
047            * Caches the groups in the entity cache if it is enabled.
048            *
049            * @param groups the groups to cache
050            */
051            public void cacheResult(
052                    java.util.List<com.liferay.portal.model.Group> groups);
053    
054            /**
055            * Creates a new group with the primary key. Does not add the group to the database.
056            *
057            * @param groupId the primary key for the new group
058            * @return the new group
059            */
060            public com.liferay.portal.model.Group create(long groupId);
061    
062            /**
063            * Removes the group with the primary key from the database. Also notifies the appropriate model listeners.
064            *
065            * @param groupId the primary key of the group to remove
066            * @return the group that was removed
067            * @throws com.liferay.portal.NoSuchGroupException if a group with the primary key could not be found
068            * @throws SystemException if a system exception occurred
069            */
070            public com.liferay.portal.model.Group remove(long groupId)
071                    throws com.liferay.portal.NoSuchGroupException,
072                            com.liferay.portal.kernel.exception.SystemException;
073    
074            public com.liferay.portal.model.Group updateImpl(
075                    com.liferay.portal.model.Group group, boolean merge)
076                    throws com.liferay.portal.kernel.exception.SystemException;
077    
078            /**
079            * Finds the group with the primary key or throws a {@link com.liferay.portal.NoSuchGroupException} if it could not be found.
080            *
081            * @param groupId the primary key of the group to find
082            * @return the group
083            * @throws com.liferay.portal.NoSuchGroupException if a group with the primary key could not be found
084            * @throws SystemException if a system exception occurred
085            */
086            public com.liferay.portal.model.Group findByPrimaryKey(long groupId)
087                    throws com.liferay.portal.NoSuchGroupException,
088                            com.liferay.portal.kernel.exception.SystemException;
089    
090            /**
091            * Finds the group with the primary key or returns <code>null</code> if it could not be found.
092            *
093            * @param groupId the primary key of the group to find
094            * @return the group, or <code>null</code> if a group with the primary key could not be found
095            * @throws SystemException if a system exception occurred
096            */
097            public com.liferay.portal.model.Group fetchByPrimaryKey(long groupId)
098                    throws com.liferay.portal.kernel.exception.SystemException;
099    
100            /**
101            * Finds all the groups where companyId = &#63;.
102            *
103            * @param companyId the company ID to search with
104            * @return the matching groups
105            * @throws SystemException if a system exception occurred
106            */
107            public java.util.List<com.liferay.portal.model.Group> findByCompanyId(
108                    long companyId)
109                    throws com.liferay.portal.kernel.exception.SystemException;
110    
111            /**
112            * Finds a range of all the groups where companyId = &#63;.
113            *
114            * <p>
115            * 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.
116            * </p>
117            *
118            * @param companyId the company ID to search with
119            * @param start the lower bound of the range of groups to return
120            * @param end the upper bound of the range of groups to return (not inclusive)
121            * @return the range of matching groups
122            * @throws SystemException if a system exception occurred
123            */
124            public java.util.List<com.liferay.portal.model.Group> findByCompanyId(
125                    long companyId, int start, int end)
126                    throws com.liferay.portal.kernel.exception.SystemException;
127    
128            /**
129            * Finds an ordered range of all the groups where companyId = &#63;.
130            *
131            * <p>
132            * 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.
133            * </p>
134            *
135            * @param companyId the company ID to search with
136            * @param start the lower bound of the range of groups to return
137            * @param end the upper bound of the range of groups to return (not inclusive)
138            * @param orderByComparator the comparator to order the results by
139            * @return the ordered range of matching groups
140            * @throws SystemException if a system exception occurred
141            */
142            public java.util.List<com.liferay.portal.model.Group> findByCompanyId(
143                    long companyId, int start, int end,
144                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
145                    throws com.liferay.portal.kernel.exception.SystemException;
146    
147            /**
148            * Finds the first group in the ordered set where companyId = &#63;.
149            *
150            * <p>
151            * 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.
152            * </p>
153            *
154            * @param companyId the company ID to search with
155            * @param orderByComparator the comparator to order the set by
156            * @return the first matching group
157            * @throws com.liferay.portal.NoSuchGroupException if a matching group could not be found
158            * @throws SystemException if a system exception occurred
159            */
160            public com.liferay.portal.model.Group findByCompanyId_First(
161                    long companyId,
162                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
163                    throws com.liferay.portal.NoSuchGroupException,
164                            com.liferay.portal.kernel.exception.SystemException;
165    
166            /**
167            * Finds the last group in the ordered set where companyId = &#63;.
168            *
169            * <p>
170            * 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.
171            * </p>
172            *
173            * @param companyId the company ID to search with
174            * @param orderByComparator the comparator to order the set by
175            * @return the last matching group
176            * @throws com.liferay.portal.NoSuchGroupException if a matching group could not be found
177            * @throws SystemException if a system exception occurred
178            */
179            public com.liferay.portal.model.Group findByCompanyId_Last(long companyId,
180                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
181                    throws com.liferay.portal.NoSuchGroupException,
182                            com.liferay.portal.kernel.exception.SystemException;
183    
184            /**
185            * Finds the groups before and after the current group in the ordered set where companyId = &#63;.
186            *
187            * <p>
188            * 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.
189            * </p>
190            *
191            * @param groupId the primary key of the current group
192            * @param companyId the company ID to search with
193            * @param orderByComparator the comparator to order the set by
194            * @return the previous, current, and next group
195            * @throws com.liferay.portal.NoSuchGroupException if a group with the primary key could not be found
196            * @throws SystemException if a system exception occurred
197            */
198            public com.liferay.portal.model.Group[] findByCompanyId_PrevAndNext(
199                    long groupId, long companyId,
200                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
201                    throws com.liferay.portal.NoSuchGroupException,
202                            com.liferay.portal.kernel.exception.SystemException;
203    
204            /**
205            * Finds the group where liveGroupId = &#63; or throws a {@link com.liferay.portal.NoSuchGroupException} if it could not be found.
206            *
207            * @param liveGroupId the live group ID to search with
208            * @return the matching group
209            * @throws com.liferay.portal.NoSuchGroupException if a matching group could not be found
210            * @throws SystemException if a system exception occurred
211            */
212            public com.liferay.portal.model.Group findByLiveGroupId(long liveGroupId)
213                    throws com.liferay.portal.NoSuchGroupException,
214                            com.liferay.portal.kernel.exception.SystemException;
215    
216            /**
217            * Finds the group where liveGroupId = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
218            *
219            * @param liveGroupId the live group ID to search with
220            * @return the matching group, or <code>null</code> if a matching group could not be found
221            * @throws SystemException if a system exception occurred
222            */
223            public com.liferay.portal.model.Group fetchByLiveGroupId(long liveGroupId)
224                    throws com.liferay.portal.kernel.exception.SystemException;
225    
226            /**
227            * Finds the group where liveGroupId = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
228            *
229            * @param liveGroupId the live group ID to search with
230            * @return the matching group, or <code>null</code> if a matching group could not be found
231            * @throws SystemException if a system exception occurred
232            */
233            public com.liferay.portal.model.Group fetchByLiveGroupId(long liveGroupId,
234                    boolean retrieveFromCache)
235                    throws com.liferay.portal.kernel.exception.SystemException;
236    
237            /**
238            * Finds the group where companyId = &#63; and name = &#63; or throws a {@link com.liferay.portal.NoSuchGroupException} if it could not be found.
239            *
240            * @param companyId the company ID to search with
241            * @param name the name to search with
242            * @return the matching group
243            * @throws com.liferay.portal.NoSuchGroupException if a matching group could not be found
244            * @throws SystemException if a system exception occurred
245            */
246            public com.liferay.portal.model.Group findByC_N(long companyId,
247                    java.lang.String name)
248                    throws com.liferay.portal.NoSuchGroupException,
249                            com.liferay.portal.kernel.exception.SystemException;
250    
251            /**
252            * Finds the group where companyId = &#63; and name = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
253            *
254            * @param companyId the company ID to search with
255            * @param name the name to search with
256            * @return the matching group, or <code>null</code> if a matching group could not be found
257            * @throws SystemException if a system exception occurred
258            */
259            public com.liferay.portal.model.Group fetchByC_N(long companyId,
260                    java.lang.String name)
261                    throws com.liferay.portal.kernel.exception.SystemException;
262    
263            /**
264            * Finds the group where companyId = &#63; and name = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
265            *
266            * @param companyId the company ID to search with
267            * @param name the name to search with
268            * @return the matching group, or <code>null</code> if a matching group could not be found
269            * @throws SystemException if a system exception occurred
270            */
271            public com.liferay.portal.model.Group fetchByC_N(long companyId,
272                    java.lang.String name, boolean retrieveFromCache)
273                    throws com.liferay.portal.kernel.exception.SystemException;
274    
275            /**
276            * Finds the group where companyId = &#63; and friendlyURL = &#63; or throws a {@link com.liferay.portal.NoSuchGroupException} if it could not be found.
277            *
278            * @param companyId the company ID to search with
279            * @param friendlyURL the friendly u r l to search with
280            * @return the matching group
281            * @throws com.liferay.portal.NoSuchGroupException if a matching group could not be found
282            * @throws SystemException if a system exception occurred
283            */
284            public com.liferay.portal.model.Group findByC_F(long companyId,
285                    java.lang.String friendlyURL)
286                    throws com.liferay.portal.NoSuchGroupException,
287                            com.liferay.portal.kernel.exception.SystemException;
288    
289            /**
290            * Finds the group where companyId = &#63; and friendlyURL = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
291            *
292            * @param companyId the company ID to search with
293            * @param friendlyURL the friendly u r l to search with
294            * @return the matching group, or <code>null</code> if a matching group could not be found
295            * @throws SystemException if a system exception occurred
296            */
297            public com.liferay.portal.model.Group fetchByC_F(long companyId,
298                    java.lang.String friendlyURL)
299                    throws com.liferay.portal.kernel.exception.SystemException;
300    
301            /**
302            * Finds the group where companyId = &#63; and friendlyURL = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
303            *
304            * @param companyId the company ID to search with
305            * @param friendlyURL the friendly u r l to search with
306            * @return the matching group, or <code>null</code> if a matching group could not be found
307            * @throws SystemException if a system exception occurred
308            */
309            public com.liferay.portal.model.Group fetchByC_F(long companyId,
310                    java.lang.String friendlyURL, boolean retrieveFromCache)
311                    throws com.liferay.portal.kernel.exception.SystemException;
312    
313            /**
314            * Finds all the groups where type = &#63; and active = &#63;.
315            *
316            * @param type the type to search with
317            * @param active the active to search with
318            * @return the matching groups
319            * @throws SystemException if a system exception occurred
320            */
321            public java.util.List<com.liferay.portal.model.Group> findByT_A(int type,
322                    boolean active)
323                    throws com.liferay.portal.kernel.exception.SystemException;
324    
325            /**
326            * Finds a range of all the groups where type = &#63; and active = &#63;.
327            *
328            * <p>
329            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
330            * </p>
331            *
332            * @param type the type to search with
333            * @param active the active to search with
334            * @param start the lower bound of the range of groups to return
335            * @param end the upper bound of the range of groups to return (not inclusive)
336            * @return the range of matching groups
337            * @throws SystemException if a system exception occurred
338            */
339            public java.util.List<com.liferay.portal.model.Group> findByT_A(int type,
340                    boolean active, int start, int end)
341                    throws com.liferay.portal.kernel.exception.SystemException;
342    
343            /**
344            * Finds an ordered range of all the groups where type = &#63; and active = &#63;.
345            *
346            * <p>
347            * 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.
348            * </p>
349            *
350            * @param type the type to search with
351            * @param active the active to search with
352            * @param start the lower bound of the range of groups to return
353            * @param end the upper bound of the range of groups to return (not inclusive)
354            * @param orderByComparator the comparator to order the results by
355            * @return the ordered range of matching groups
356            * @throws SystemException if a system exception occurred
357            */
358            public java.util.List<com.liferay.portal.model.Group> findByT_A(int type,
359                    boolean active, int start, int end,
360                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
361                    throws com.liferay.portal.kernel.exception.SystemException;
362    
363            /**
364            * Finds the first group in the ordered set where type = &#63; and active = &#63;.
365            *
366            * <p>
367            * 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.
368            * </p>
369            *
370            * @param type the type to search with
371            * @param active the active to search with
372            * @param orderByComparator the comparator to order the set by
373            * @return the first matching group
374            * @throws com.liferay.portal.NoSuchGroupException if a matching group could not be found
375            * @throws SystemException if a system exception occurred
376            */
377            public com.liferay.portal.model.Group findByT_A_First(int type,
378                    boolean active,
379                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
380                    throws com.liferay.portal.NoSuchGroupException,
381                            com.liferay.portal.kernel.exception.SystemException;
382    
383            /**
384            * Finds the last group in the ordered set where type = &#63; and active = &#63;.
385            *
386            * <p>
387            * 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.
388            * </p>
389            *
390            * @param type the type to search with
391            * @param active the active to search with
392            * @param orderByComparator the comparator to order the set by
393            * @return the last matching group
394            * @throws com.liferay.portal.NoSuchGroupException if a matching group could not be found
395            * @throws SystemException if a system exception occurred
396            */
397            public com.liferay.portal.model.Group findByT_A_Last(int type,
398                    boolean active,
399                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
400                    throws com.liferay.portal.NoSuchGroupException,
401                            com.liferay.portal.kernel.exception.SystemException;
402    
403            /**
404            * Finds the groups before and after the current group in the ordered set where type = &#63; and active = &#63;.
405            *
406            * <p>
407            * 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.
408            * </p>
409            *
410            * @param groupId the primary key of the current group
411            * @param type the type to search with
412            * @param active the active to search with
413            * @param orderByComparator the comparator to order the set by
414            * @return the previous, current, and next group
415            * @throws com.liferay.portal.NoSuchGroupException if a group with the primary key could not be found
416            * @throws SystemException if a system exception occurred
417            */
418            public com.liferay.portal.model.Group[] findByT_A_PrevAndNext(
419                    long groupId, int type, boolean active,
420                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
421                    throws com.liferay.portal.NoSuchGroupException,
422                            com.liferay.portal.kernel.exception.SystemException;
423    
424            /**
425            * Finds the group where companyId = &#63; and classNameId = &#63; and classPK = &#63; or throws a {@link com.liferay.portal.NoSuchGroupException} if it could not be found.
426            *
427            * @param companyId the company ID to search with
428            * @param classNameId the class name ID to search with
429            * @param classPK the class p k to search with
430            * @return the matching group
431            * @throws com.liferay.portal.NoSuchGroupException if a matching group could not be found
432            * @throws SystemException if a system exception occurred
433            */
434            public com.liferay.portal.model.Group findByC_C_C(long companyId,
435                    long classNameId, long classPK)
436                    throws com.liferay.portal.NoSuchGroupException,
437                            com.liferay.portal.kernel.exception.SystemException;
438    
439            /**
440            * Finds the group where companyId = &#63; and classNameId = &#63; and classPK = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
441            *
442            * @param companyId the company ID to search with
443            * @param classNameId the class name ID to search with
444            * @param classPK the class p k to search with
445            * @return the matching group, or <code>null</code> if a matching group could not be found
446            * @throws SystemException if a system exception occurred
447            */
448            public com.liferay.portal.model.Group fetchByC_C_C(long companyId,
449                    long classNameId, long classPK)
450                    throws com.liferay.portal.kernel.exception.SystemException;
451    
452            /**
453            * Finds the group 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.
454            *
455            * @param companyId the company ID to search with
456            * @param classNameId the class name ID to search with
457            * @param classPK the class p k to search with
458            * @return the matching group, or <code>null</code> if a matching group could not be found
459            * @throws SystemException if a system exception occurred
460            */
461            public com.liferay.portal.model.Group fetchByC_C_C(long companyId,
462                    long classNameId, long classPK, boolean retrieveFromCache)
463                    throws com.liferay.portal.kernel.exception.SystemException;
464    
465            /**
466            * Finds the group where companyId = &#63; and liveGroupId = &#63; and name = &#63; or throws a {@link com.liferay.portal.NoSuchGroupException} if it could not be found.
467            *
468            * @param companyId the company ID to search with
469            * @param liveGroupId the live group ID to search with
470            * @param name the name to search with
471            * @return the matching group
472            * @throws com.liferay.portal.NoSuchGroupException if a matching group could not be found
473            * @throws SystemException if a system exception occurred
474            */
475            public com.liferay.portal.model.Group findByC_L_N(long companyId,
476                    long liveGroupId, java.lang.String name)
477                    throws com.liferay.portal.NoSuchGroupException,
478                            com.liferay.portal.kernel.exception.SystemException;
479    
480            /**
481            * Finds the group where companyId = &#63; and liveGroupId = &#63; and name = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
482            *
483            * @param companyId the company ID to search with
484            * @param liveGroupId the live group ID to search with
485            * @param name the name to search with
486            * @return the matching group, or <code>null</code> if a matching group could not be found
487            * @throws SystemException if a system exception occurred
488            */
489            public com.liferay.portal.model.Group fetchByC_L_N(long companyId,
490                    long liveGroupId, java.lang.String name)
491                    throws com.liferay.portal.kernel.exception.SystemException;
492    
493            /**
494            * Finds the group where companyId = &#63; and liveGroupId = &#63; and name = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
495            *
496            * @param companyId the company ID to search with
497            * @param liveGroupId the live group ID to search with
498            * @param name the name to search with
499            * @return the matching group, or <code>null</code> if a matching group could not be found
500            * @throws SystemException if a system exception occurred
501            */
502            public com.liferay.portal.model.Group fetchByC_L_N(long companyId,
503                    long liveGroupId, java.lang.String name, boolean retrieveFromCache)
504                    throws com.liferay.portal.kernel.exception.SystemException;
505    
506            /**
507            * Finds the group where companyId = &#63; and classNameId = &#63; and liveGroupId = &#63; and name = &#63; or throws a {@link com.liferay.portal.NoSuchGroupException} if it could not be found.
508            *
509            * @param companyId the company ID to search with
510            * @param classNameId the class name ID to search with
511            * @param liveGroupId the live group ID to search with
512            * @param name the name to search with
513            * @return the matching group
514            * @throws com.liferay.portal.NoSuchGroupException if a matching group could not be found
515            * @throws SystemException if a system exception occurred
516            */
517            public com.liferay.portal.model.Group findByC_C_L_N(long companyId,
518                    long classNameId, long liveGroupId, java.lang.String name)
519                    throws com.liferay.portal.NoSuchGroupException,
520                            com.liferay.portal.kernel.exception.SystemException;
521    
522            /**
523            * Finds the group where companyId = &#63; and classNameId = &#63; and liveGroupId = &#63; and name = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
524            *
525            * @param companyId the company ID to search with
526            * @param classNameId the class name ID to search with
527            * @param liveGroupId the live group ID to search with
528            * @param name the name to search with
529            * @return the matching group, or <code>null</code> if a matching group could not be found
530            * @throws SystemException if a system exception occurred
531            */
532            public com.liferay.portal.model.Group fetchByC_C_L_N(long companyId,
533                    long classNameId, long liveGroupId, java.lang.String name)
534                    throws com.liferay.portal.kernel.exception.SystemException;
535    
536            /**
537            * Finds the group where companyId = &#63; and classNameId = &#63; and liveGroupId = &#63; and name = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
538            *
539            * @param companyId the company ID to search with
540            * @param classNameId the class name ID to search with
541            * @param liveGroupId the live group ID to search with
542            * @param name the name to search with
543            * @return the matching group, or <code>null</code> if a matching group could not be found
544            * @throws SystemException if a system exception occurred
545            */
546            public com.liferay.portal.model.Group fetchByC_C_L_N(long companyId,
547                    long classNameId, long liveGroupId, java.lang.String name,
548                    boolean retrieveFromCache)
549                    throws com.liferay.portal.kernel.exception.SystemException;
550    
551            /**
552            * Finds all the groups.
553            *
554            * @return the groups
555            * @throws SystemException if a system exception occurred
556            */
557            public java.util.List<com.liferay.portal.model.Group> findAll()
558                    throws com.liferay.portal.kernel.exception.SystemException;
559    
560            /**
561            * Finds a range of all the groups.
562            *
563            * <p>
564            * 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.
565            * </p>
566            *
567            * @param start the lower bound of the range of groups to return
568            * @param end the upper bound of the range of groups to return (not inclusive)
569            * @return the range of groups
570            * @throws SystemException if a system exception occurred
571            */
572            public java.util.List<com.liferay.portal.model.Group> findAll(int start,
573                    int end) throws com.liferay.portal.kernel.exception.SystemException;
574    
575            /**
576            * Finds an ordered range of all the groups.
577            *
578            * <p>
579            * 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.
580            * </p>
581            *
582            * @param start the lower bound of the range of groups to return
583            * @param end the upper bound of the range of groups to return (not inclusive)
584            * @param orderByComparator the comparator to order the results by
585            * @return the ordered range of groups
586            * @throws SystemException if a system exception occurred
587            */
588            public java.util.List<com.liferay.portal.model.Group> findAll(int start,
589                    int end,
590                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
591                    throws com.liferay.portal.kernel.exception.SystemException;
592    
593            /**
594            * Removes all the groups where companyId = &#63; from the database.
595            *
596            * @param companyId the company ID to search with
597            * @throws SystemException if a system exception occurred
598            */
599            public void removeByCompanyId(long companyId)
600                    throws com.liferay.portal.kernel.exception.SystemException;
601    
602            /**
603            * Removes the group where liveGroupId = &#63; from the database.
604            *
605            * @param liveGroupId the live group ID to search with
606            * @throws SystemException if a system exception occurred
607            */
608            public void removeByLiveGroupId(long liveGroupId)
609                    throws com.liferay.portal.NoSuchGroupException,
610                            com.liferay.portal.kernel.exception.SystemException;
611    
612            /**
613            * Removes the group where companyId = &#63; and name = &#63; from the database.
614            *
615            * @param companyId the company ID to search with
616            * @param name the name to search with
617            * @throws SystemException if a system exception occurred
618            */
619            public void removeByC_N(long companyId, java.lang.String name)
620                    throws com.liferay.portal.NoSuchGroupException,
621                            com.liferay.portal.kernel.exception.SystemException;
622    
623            /**
624            * Removes the group where companyId = &#63; and friendlyURL = &#63; from the database.
625            *
626            * @param companyId the company ID to search with
627            * @param friendlyURL the friendly u r l to search with
628            * @throws SystemException if a system exception occurred
629            */
630            public void removeByC_F(long companyId, java.lang.String friendlyURL)
631                    throws com.liferay.portal.NoSuchGroupException,
632                            com.liferay.portal.kernel.exception.SystemException;
633    
634            /**
635            * Removes all the groups where type = &#63; and active = &#63; from the database.
636            *
637            * @param type the type to search with
638            * @param active the active to search with
639            * @throws SystemException if a system exception occurred
640            */
641            public void removeByT_A(int type, boolean active)
642                    throws com.liferay.portal.kernel.exception.SystemException;
643    
644            /**
645            * Removes the group where companyId = &#63; and classNameId = &#63; and classPK = &#63; from the database.
646            *
647            * @param companyId the company ID to search with
648            * @param classNameId the class name ID to search with
649            * @param classPK the class p k to search with
650            * @throws SystemException if a system exception occurred
651            */
652            public void removeByC_C_C(long companyId, long classNameId, long classPK)
653                    throws com.liferay.portal.NoSuchGroupException,
654                            com.liferay.portal.kernel.exception.SystemException;
655    
656            /**
657            * Removes the group where companyId = &#63; and liveGroupId = &#63; and name = &#63; from the database.
658            *
659            * @param companyId the company ID to search with
660            * @param liveGroupId the live group ID to search with
661            * @param name the name to search with
662            * @throws SystemException if a system exception occurred
663            */
664            public void removeByC_L_N(long companyId, long liveGroupId,
665                    java.lang.String name)
666                    throws com.liferay.portal.NoSuchGroupException,
667                            com.liferay.portal.kernel.exception.SystemException;
668    
669            /**
670            * Removes the group where companyId = &#63; and classNameId = &#63; and liveGroupId = &#63; and name = &#63; from the database.
671            *
672            * @param companyId the company ID to search with
673            * @param classNameId the class name ID to search with
674            * @param liveGroupId the live group ID to search with
675            * @param name the name to search with
676            * @throws SystemException if a system exception occurred
677            */
678            public void removeByC_C_L_N(long companyId, long classNameId,
679                    long liveGroupId, java.lang.String name)
680                    throws com.liferay.portal.NoSuchGroupException,
681                            com.liferay.portal.kernel.exception.SystemException;
682    
683            /**
684            * Removes all the groups from the database.
685            *
686            * @throws SystemException if a system exception occurred
687            */
688            public void removeAll()
689                    throws com.liferay.portal.kernel.exception.SystemException;
690    
691            /**
692            * Counts all the groups where companyId = &#63;.
693            *
694            * @param companyId the company ID to search with
695            * @return the number of matching groups
696            * @throws SystemException if a system exception occurred
697            */
698            public int countByCompanyId(long companyId)
699                    throws com.liferay.portal.kernel.exception.SystemException;
700    
701            /**
702            * Counts all the groups where liveGroupId = &#63;.
703            *
704            * @param liveGroupId the live group ID to search with
705            * @return the number of matching groups
706            * @throws SystemException if a system exception occurred
707            */
708            public int countByLiveGroupId(long liveGroupId)
709                    throws com.liferay.portal.kernel.exception.SystemException;
710    
711            /**
712            * Counts all the groups where companyId = &#63; and name = &#63;.
713            *
714            * @param companyId the company ID to search with
715            * @param name the name to search with
716            * @return the number of matching groups
717            * @throws SystemException if a system exception occurred
718            */
719            public int countByC_N(long companyId, java.lang.String name)
720                    throws com.liferay.portal.kernel.exception.SystemException;
721    
722            /**
723            * Counts all the groups where companyId = &#63; and friendlyURL = &#63;.
724            *
725            * @param companyId the company ID to search with
726            * @param friendlyURL the friendly u r l to search with
727            * @return the number of matching groups
728            * @throws SystemException if a system exception occurred
729            */
730            public int countByC_F(long companyId, java.lang.String friendlyURL)
731                    throws com.liferay.portal.kernel.exception.SystemException;
732    
733            /**
734            * Counts all the groups where type = &#63; and active = &#63;.
735            *
736            * @param type the type to search with
737            * @param active the active to search with
738            * @return the number of matching groups
739            * @throws SystemException if a system exception occurred
740            */
741            public int countByT_A(int type, boolean active)
742                    throws com.liferay.portal.kernel.exception.SystemException;
743    
744            /**
745            * Counts all the groups where companyId = &#63; and classNameId = &#63; and classPK = &#63;.
746            *
747            * @param companyId the company ID to search with
748            * @param classNameId the class name ID to search with
749            * @param classPK the class p k to search with
750            * @return the number of matching groups
751            * @throws SystemException if a system exception occurred
752            */
753            public int countByC_C_C(long companyId, long classNameId, long classPK)
754                    throws com.liferay.portal.kernel.exception.SystemException;
755    
756            /**
757            * Counts all the groups where companyId = &#63; and liveGroupId = &#63; and name = &#63;.
758            *
759            * @param companyId the company ID to search with
760            * @param liveGroupId the live group ID to search with
761            * @param name the name to search with
762            * @return the number of matching groups
763            * @throws SystemException if a system exception occurred
764            */
765            public int countByC_L_N(long companyId, long liveGroupId,
766                    java.lang.String name)
767                    throws com.liferay.portal.kernel.exception.SystemException;
768    
769            /**
770            * Counts all the groups where companyId = &#63; and classNameId = &#63; and liveGroupId = &#63; and name = &#63;.
771            *
772            * @param companyId the company ID to search with
773            * @param classNameId the class name ID to search with
774            * @param liveGroupId the live group ID to search with
775            * @param name the name to search with
776            * @return the number of matching groups
777            * @throws SystemException if a system exception occurred
778            */
779            public int countByC_C_L_N(long companyId, long classNameId,
780                    long liveGroupId, java.lang.String name)
781                    throws com.liferay.portal.kernel.exception.SystemException;
782    
783            /**
784            * Counts all the groups.
785            *
786            * @return the number of groups
787            * @throws SystemException if a system exception occurred
788            */
789            public int countAll()
790                    throws com.liferay.portal.kernel.exception.SystemException;
791    
792            /**
793            * Gets all the organizations associated with the group.
794            *
795            * @param pk the primary key of the group to get the associated organizations for
796            * @return the organizations associated with the group
797            * @throws SystemException if a system exception occurred
798            */
799            public java.util.List<com.liferay.portal.model.Organization> getOrganizations(
800                    long pk) throws com.liferay.portal.kernel.exception.SystemException;
801    
802            /**
803            * Gets a range of all the organizations associated with the group.
804            *
805            * <p>
806            * 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.
807            * </p>
808            *
809            * @param pk the primary key of the group to get the associated organizations for
810            * @param start the lower bound of the range of groups to return
811            * @param end the upper bound of the range of groups to return (not inclusive)
812            * @return the range of organizations associated with the group
813            * @throws SystemException if a system exception occurred
814            */
815            public java.util.List<com.liferay.portal.model.Organization> getOrganizations(
816                    long pk, int start, int end)
817                    throws com.liferay.portal.kernel.exception.SystemException;
818    
819            /**
820            * Gets an ordered range of all the organizations associated with the group.
821            *
822            * <p>
823            * 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.
824            * </p>
825            *
826            * @param pk the primary key of the group to get the associated organizations for
827            * @param start the lower bound of the range of groups to return
828            * @param end the upper bound of the range of groups to return (not inclusive)
829            * @param orderByComparator the comparator to order the results by
830            * @return the ordered range of organizations associated with the group
831            * @throws SystemException if a system exception occurred
832            */
833            public java.util.List<com.liferay.portal.model.Organization> getOrganizations(
834                    long pk, int start, int end,
835                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
836                    throws com.liferay.portal.kernel.exception.SystemException;
837    
838            /**
839            * Gets the number of organizations associated with the group.
840            *
841            * @param pk the primary key of the group to get the number of associated organizations for
842            * @return the number of organizations associated with the group
843            * @throws SystemException if a system exception occurred
844            */
845            public int getOrganizationsSize(long pk)
846                    throws com.liferay.portal.kernel.exception.SystemException;
847    
848            /**
849            * Determines if the organization is associated with the group.
850            *
851            * @param pk the primary key of the group
852            * @param organizationPK the primary key of the organization
853            * @return <code>true</code> if the organization is associated with the group; <code>false</code> otherwise
854            * @throws SystemException if a system exception occurred
855            */
856            public boolean containsOrganization(long pk, long organizationPK)
857                    throws com.liferay.portal.kernel.exception.SystemException;
858    
859            /**
860            * Determines if the group has any organizations associated with it.
861            *
862            * @param pk the primary key of the group to check for associations with organizations
863            * @return <code>true</code> if the group has any organizations associated with it; <code>false</code> otherwise
864            * @throws SystemException if a system exception occurred
865            */
866            public boolean containsOrganizations(long pk)
867                    throws com.liferay.portal.kernel.exception.SystemException;
868    
869            /**
870            * Adds an association between the group and the organization. Also notifies the appropriate model listeners and clears the mapping table finder cache.
871            *
872            * @param pk the primary key of the group
873            * @param organizationPK the primary key of the organization
874            * @throws SystemException if a system exception occurred
875            */
876            public void addOrganization(long pk, long organizationPK)
877                    throws com.liferay.portal.kernel.exception.SystemException;
878    
879            /**
880            * Adds an association between the group and the organization. Also notifies the appropriate model listeners and clears the mapping table finder cache.
881            *
882            * @param pk the primary key of the group
883            * @param organization the organization
884            * @throws SystemException if a system exception occurred
885            */
886            public void addOrganization(long pk,
887                    com.liferay.portal.model.Organization organization)
888                    throws com.liferay.portal.kernel.exception.SystemException;
889    
890            /**
891            * Adds an association between the group and the organizations. Also notifies the appropriate model listeners and clears the mapping table finder cache.
892            *
893            * @param pk the primary key of the group
894            * @param organizationPKs the primary keys of the organizations
895            * @throws SystemException if a system exception occurred
896            */
897            public void addOrganizations(long pk, long[] organizationPKs)
898                    throws com.liferay.portal.kernel.exception.SystemException;
899    
900            /**
901            * Adds an association between the group and the organizations. Also notifies the appropriate model listeners and clears the mapping table finder cache.
902            *
903            * @param pk the primary key of the group
904            * @param organizations the organizations
905            * @throws SystemException if a system exception occurred
906            */
907            public void addOrganizations(long pk,
908                    java.util.List<com.liferay.portal.model.Organization> organizations)
909                    throws com.liferay.portal.kernel.exception.SystemException;
910    
911            /**
912            * Clears all associations between the group and its organizations. Also notifies the appropriate model listeners and clears the mapping table finder cache.
913            *
914            * @param pk the primary key of the group to clear the associated organizations from
915            * @throws SystemException if a system exception occurred
916            */
917            public void clearOrganizations(long pk)
918                    throws com.liferay.portal.kernel.exception.SystemException;
919    
920            /**
921            * Removes the association between the group and the organization. Also notifies the appropriate model listeners and clears the mapping table finder cache.
922            *
923            * @param pk the primary key of the group
924            * @param organizationPK the primary key of the organization
925            * @throws SystemException if a system exception occurred
926            */
927            public void removeOrganization(long pk, long organizationPK)
928                    throws com.liferay.portal.kernel.exception.SystemException;
929    
930            /**
931            * Removes the association between the group and the organization. Also notifies the appropriate model listeners and clears the mapping table finder cache.
932            *
933            * @param pk the primary key of the group
934            * @param organization the organization
935            * @throws SystemException if a system exception occurred
936            */
937            public void removeOrganization(long pk,
938                    com.liferay.portal.model.Organization organization)
939                    throws com.liferay.portal.kernel.exception.SystemException;
940    
941            /**
942            * Removes the association between the group and the organizations. Also notifies the appropriate model listeners and clears the mapping table finder cache.
943            *
944            * @param pk the primary key of the group
945            * @param organizationPKs the primary keys of the organizations
946            * @throws SystemException if a system exception occurred
947            */
948            public void removeOrganizations(long pk, long[] organizationPKs)
949                    throws com.liferay.portal.kernel.exception.SystemException;
950    
951            /**
952            * Removes the association between the group and the organizations. Also notifies the appropriate model listeners and clears the mapping table finder cache.
953            *
954            * @param pk the primary key of the group
955            * @param organizations the organizations
956            * @throws SystemException if a system exception occurred
957            */
958            public void removeOrganizations(long pk,
959                    java.util.List<com.liferay.portal.model.Organization> organizations)
960                    throws com.liferay.portal.kernel.exception.SystemException;
961    
962            /**
963            * Sets the organizations associated with the group, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
964            *
965            * @param pk the primary key of the group to set the associations for
966            * @param organizationPKs the primary keys of the organizations to be associated with the group
967            * @throws SystemException if a system exception occurred
968            */
969            public void setOrganizations(long pk, long[] organizationPKs)
970                    throws com.liferay.portal.kernel.exception.SystemException;
971    
972            /**
973            * Sets the organizations associated with the group, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
974            *
975            * @param pk the primary key of the group to set the associations for
976            * @param organizations the organizations to be associated with the group
977            * @throws SystemException if a system exception occurred
978            */
979            public void setOrganizations(long pk,
980                    java.util.List<com.liferay.portal.model.Organization> organizations)
981                    throws com.liferay.portal.kernel.exception.SystemException;
982    
983            /**
984            * Gets all the permissions associated with the group.
985            *
986            * @param pk the primary key of the group to get the associated permissions for
987            * @return the permissions associated with the group
988            * @throws SystemException if a system exception occurred
989            */
990            public java.util.List<com.liferay.portal.model.Permission> getPermissions(
991                    long pk) throws com.liferay.portal.kernel.exception.SystemException;
992    
993            /**
994            * Gets a range of all the permissions associated with the group.
995            *
996            * <p>
997            * 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.
998            * </p>
999            *
1000            * @param pk the primary key of the group to get the associated permissions for
1001            * @param start the lower bound of the range of groups to return
1002            * @param end the upper bound of the range of groups to return (not inclusive)
1003            * @return the range of permissions associated with the group
1004            * @throws SystemException if a system exception occurred
1005            */
1006            public java.util.List<com.liferay.portal.model.Permission> getPermissions(
1007                    long pk, int start, int end)
1008                    throws com.liferay.portal.kernel.exception.SystemException;
1009    
1010            /**
1011            * Gets an ordered range of all the permissions associated with the group.
1012            *
1013            * <p>
1014            * 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.
1015            * </p>
1016            *
1017            * @param pk the primary key of the group to get the associated permissions for
1018            * @param start the lower bound of the range of groups to return
1019            * @param end the upper bound of the range of groups to return (not inclusive)
1020            * @param orderByComparator the comparator to order the results by
1021            * @return the ordered range of permissions associated with the group
1022            * @throws SystemException if a system exception occurred
1023            */
1024            public java.util.List<com.liferay.portal.model.Permission> getPermissions(
1025                    long pk, int start, int end,
1026                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1027                    throws com.liferay.portal.kernel.exception.SystemException;
1028    
1029            /**
1030            * Gets the number of permissions associated with the group.
1031            *
1032            * @param pk the primary key of the group to get the number of associated permissions for
1033            * @return the number of permissions associated with the group
1034            * @throws SystemException if a system exception occurred
1035            */
1036            public int getPermissionsSize(long pk)
1037                    throws com.liferay.portal.kernel.exception.SystemException;
1038    
1039            /**
1040            * Determines if the permission is associated with the group.
1041            *
1042            * @param pk the primary key of the group
1043            * @param permissionPK the primary key of the permission
1044            * @return <code>true</code> if the permission is associated with the group; <code>false</code> otherwise
1045            * @throws SystemException if a system exception occurred
1046            */
1047            public boolean containsPermission(long pk, long permissionPK)
1048                    throws com.liferay.portal.kernel.exception.SystemException;
1049    
1050            /**
1051            * Determines if the group has any permissions associated with it.
1052            *
1053            * @param pk the primary key of the group to check for associations with permissions
1054            * @return <code>true</code> if the group has any permissions associated with it; <code>false</code> otherwise
1055            * @throws SystemException if a system exception occurred
1056            */
1057            public boolean containsPermissions(long pk)
1058                    throws com.liferay.portal.kernel.exception.SystemException;
1059    
1060            /**
1061            * Adds an association between the group and the permission. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1062            *
1063            * @param pk the primary key of the group
1064            * @param permissionPK the primary key of the permission
1065            * @throws SystemException if a system exception occurred
1066            */
1067            public void addPermission(long pk, long permissionPK)
1068                    throws com.liferay.portal.kernel.exception.SystemException;
1069    
1070            /**
1071            * Adds an association between the group and the permission. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1072            *
1073            * @param pk the primary key of the group
1074            * @param permission the permission
1075            * @throws SystemException if a system exception occurred
1076            */
1077            public void addPermission(long pk,
1078                    com.liferay.portal.model.Permission permission)
1079                    throws com.liferay.portal.kernel.exception.SystemException;
1080    
1081            /**
1082            * Adds an association between the group and the permissions. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1083            *
1084            * @param pk the primary key of the group
1085            * @param permissionPKs the primary keys of the permissions
1086            * @throws SystemException if a system exception occurred
1087            */
1088            public void addPermissions(long pk, long[] permissionPKs)
1089                    throws com.liferay.portal.kernel.exception.SystemException;
1090    
1091            /**
1092            * Adds an association between the group and the permissions. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1093            *
1094            * @param pk the primary key of the group
1095            * @param permissions the permissions
1096            * @throws SystemException if a system exception occurred
1097            */
1098            public void addPermissions(long pk,
1099                    java.util.List<com.liferay.portal.model.Permission> permissions)
1100                    throws com.liferay.portal.kernel.exception.SystemException;
1101    
1102            /**
1103            * Clears all associations between the group and its permissions. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1104            *
1105            * @param pk the primary key of the group to clear the associated permissions from
1106            * @throws SystemException if a system exception occurred
1107            */
1108            public void clearPermissions(long pk)
1109                    throws com.liferay.portal.kernel.exception.SystemException;
1110    
1111            /**
1112            * Removes the association between the group and the permission. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1113            *
1114            * @param pk the primary key of the group
1115            * @param permissionPK the primary key of the permission
1116            * @throws SystemException if a system exception occurred
1117            */
1118            public void removePermission(long pk, long permissionPK)
1119                    throws com.liferay.portal.kernel.exception.SystemException;
1120    
1121            /**
1122            * Removes the association between the group and the permission. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1123            *
1124            * @param pk the primary key of the group
1125            * @param permission the permission
1126            * @throws SystemException if a system exception occurred
1127            */
1128            public void removePermission(long pk,
1129                    com.liferay.portal.model.Permission permission)
1130                    throws com.liferay.portal.kernel.exception.SystemException;
1131    
1132            /**
1133            * Removes the association between the group and the permissions. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1134            *
1135            * @param pk the primary key of the group
1136            * @param permissionPKs the primary keys of the permissions
1137            * @throws SystemException if a system exception occurred
1138            */
1139            public void removePermissions(long pk, long[] permissionPKs)
1140                    throws com.liferay.portal.kernel.exception.SystemException;
1141    
1142            /**
1143            * Removes the association between the group and the permissions. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1144            *
1145            * @param pk the primary key of the group
1146            * @param permissions the permissions
1147            * @throws SystemException if a system exception occurred
1148            */
1149            public void removePermissions(long pk,
1150                    java.util.List<com.liferay.portal.model.Permission> permissions)
1151                    throws com.liferay.portal.kernel.exception.SystemException;
1152    
1153            /**
1154            * Sets the permissions associated with the group, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1155            *
1156            * @param pk the primary key of the group to set the associations for
1157            * @param permissionPKs the primary keys of the permissions to be associated with the group
1158            * @throws SystemException if a system exception occurred
1159            */
1160            public void setPermissions(long pk, long[] permissionPKs)
1161                    throws com.liferay.portal.kernel.exception.SystemException;
1162    
1163            /**
1164            * Sets the permissions associated with the group, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1165            *
1166            * @param pk the primary key of the group to set the associations for
1167            * @param permissions the permissions to be associated with the group
1168            * @throws SystemException if a system exception occurred
1169            */
1170            public void setPermissions(long pk,
1171                    java.util.List<com.liferay.portal.model.Permission> permissions)
1172                    throws com.liferay.portal.kernel.exception.SystemException;
1173    
1174            /**
1175            * Gets all the roles associated with the group.
1176            *
1177            * @param pk the primary key of the group to get the associated roles for
1178            * @return the roles associated with the group
1179            * @throws SystemException if a system exception occurred
1180            */
1181            public java.util.List<com.liferay.portal.model.Role> getRoles(long pk)
1182                    throws com.liferay.portal.kernel.exception.SystemException;
1183    
1184            /**
1185            * Gets a range of all the roles associated with the group.
1186            *
1187            * <p>
1188            * 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.
1189            * </p>
1190            *
1191            * @param pk the primary key of the group to get the associated roles for
1192            * @param start the lower bound of the range of groups to return
1193            * @param end the upper bound of the range of groups to return (not inclusive)
1194            * @return the range of roles associated with the group
1195            * @throws SystemException if a system exception occurred
1196            */
1197            public java.util.List<com.liferay.portal.model.Role> getRoles(long pk,
1198                    int start, int end)
1199                    throws com.liferay.portal.kernel.exception.SystemException;
1200    
1201            /**
1202            * Gets an ordered range of all the roles associated with the group.
1203            *
1204            * <p>
1205            * 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.
1206            * </p>
1207            *
1208            * @param pk the primary key of the group to get the associated roles for
1209            * @param start the lower bound of the range of groups to return
1210            * @param end the upper bound of the range of groups to return (not inclusive)
1211            * @param orderByComparator the comparator to order the results by
1212            * @return the ordered range of roles associated with the group
1213            * @throws SystemException if a system exception occurred
1214            */
1215            public java.util.List<com.liferay.portal.model.Role> getRoles(long pk,
1216                    int start, int end,
1217                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1218                    throws com.liferay.portal.kernel.exception.SystemException;
1219    
1220            /**
1221            * Gets the number of roles associated with the group.
1222            *
1223            * @param pk the primary key of the group to get the number of associated roles for
1224            * @return the number of roles associated with the group
1225            * @throws SystemException if a system exception occurred
1226            */
1227            public int getRolesSize(long pk)
1228                    throws com.liferay.portal.kernel.exception.SystemException;
1229    
1230            /**
1231            * Determines if the role is associated with the group.
1232            *
1233            * @param pk the primary key of the group
1234            * @param rolePK the primary key of the role
1235            * @return <code>true</code> if the role is associated with the group; <code>false</code> otherwise
1236            * @throws SystemException if a system exception occurred
1237            */
1238            public boolean containsRole(long pk, long rolePK)
1239                    throws com.liferay.portal.kernel.exception.SystemException;
1240    
1241            /**
1242            * Determines if the group has any roles associated with it.
1243            *
1244            * @param pk the primary key of the group to check for associations with roles
1245            * @return <code>true</code> if the group has any roles associated with it; <code>false</code> otherwise
1246            * @throws SystemException if a system exception occurred
1247            */
1248            public boolean containsRoles(long pk)
1249                    throws com.liferay.portal.kernel.exception.SystemException;
1250    
1251            /**
1252            * Adds an association between the group and the role. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1253            *
1254            * @param pk the primary key of the group
1255            * @param rolePK the primary key of the role
1256            * @throws SystemException if a system exception occurred
1257            */
1258            public void addRole(long pk, long rolePK)
1259                    throws com.liferay.portal.kernel.exception.SystemException;
1260    
1261            /**
1262            * Adds an association between the group and the role. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1263            *
1264            * @param pk the primary key of the group
1265            * @param role the role
1266            * @throws SystemException if a system exception occurred
1267            */
1268            public void addRole(long pk, com.liferay.portal.model.Role role)
1269                    throws com.liferay.portal.kernel.exception.SystemException;
1270    
1271            /**
1272            * Adds an association between the group and the roles. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1273            *
1274            * @param pk the primary key of the group
1275            * @param rolePKs the primary keys of the roles
1276            * @throws SystemException if a system exception occurred
1277            */
1278            public void addRoles(long pk, long[] rolePKs)
1279                    throws com.liferay.portal.kernel.exception.SystemException;
1280    
1281            /**
1282            * Adds an association between the group and the roles. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1283            *
1284            * @param pk the primary key of the group
1285            * @param roles the roles
1286            * @throws SystemException if a system exception occurred
1287            */
1288            public void addRoles(long pk,
1289                    java.util.List<com.liferay.portal.model.Role> roles)
1290                    throws com.liferay.portal.kernel.exception.SystemException;
1291    
1292            /**
1293            * Clears all associations between the group and its roles. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1294            *
1295            * @param pk the primary key of the group to clear the associated roles from
1296            * @throws SystemException if a system exception occurred
1297            */
1298            public void clearRoles(long pk)
1299                    throws com.liferay.portal.kernel.exception.SystemException;
1300    
1301            /**
1302            * Removes the association between the group and the role. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1303            *
1304            * @param pk the primary key of the group
1305            * @param rolePK the primary key of the role
1306            * @throws SystemException if a system exception occurred
1307            */
1308            public void removeRole(long pk, long rolePK)
1309                    throws com.liferay.portal.kernel.exception.SystemException;
1310    
1311            /**
1312            * Removes the association between the group and the role. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1313            *
1314            * @param pk the primary key of the group
1315            * @param role the role
1316            * @throws SystemException if a system exception occurred
1317            */
1318            public void removeRole(long pk, com.liferay.portal.model.Role role)
1319                    throws com.liferay.portal.kernel.exception.SystemException;
1320    
1321            /**
1322            * Removes the association between the group and the roles. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1323            *
1324            * @param pk the primary key of the group
1325            * @param rolePKs the primary keys of the roles
1326            * @throws SystemException if a system exception occurred
1327            */
1328            public void removeRoles(long pk, long[] rolePKs)
1329                    throws com.liferay.portal.kernel.exception.SystemException;
1330    
1331            /**
1332            * Removes the association between the group and the roles. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1333            *
1334            * @param pk the primary key of the group
1335            * @param roles the roles
1336            * @throws SystemException if a system exception occurred
1337            */
1338            public void removeRoles(long pk,
1339                    java.util.List<com.liferay.portal.model.Role> roles)
1340                    throws com.liferay.portal.kernel.exception.SystemException;
1341    
1342            /**
1343            * Sets the roles associated with the group, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1344            *
1345            * @param pk the primary key of the group to set the associations for
1346            * @param rolePKs the primary keys of the roles to be associated with the group
1347            * @throws SystemException if a system exception occurred
1348            */
1349            public void setRoles(long pk, long[] rolePKs)
1350                    throws com.liferay.portal.kernel.exception.SystemException;
1351    
1352            /**
1353            * Sets the roles associated with the group, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1354            *
1355            * @param pk the primary key of the group to set the associations for
1356            * @param roles the roles to be associated with the group
1357            * @throws SystemException if a system exception occurred
1358            */
1359            public void setRoles(long pk,
1360                    java.util.List<com.liferay.portal.model.Role> roles)
1361                    throws com.liferay.portal.kernel.exception.SystemException;
1362    
1363            /**
1364            * Gets all the user groups associated with the group.
1365            *
1366            * @param pk the primary key of the group to get the associated user groups for
1367            * @return the user groups associated with the group
1368            * @throws SystemException if a system exception occurred
1369            */
1370            public java.util.List<com.liferay.portal.model.UserGroup> getUserGroups(
1371                    long pk) throws com.liferay.portal.kernel.exception.SystemException;
1372    
1373            /**
1374            * Gets a range of all the user groups associated with the group.
1375            *
1376            * <p>
1377            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
1378            * </p>
1379            *
1380            * @param pk the primary key of the group to get the associated user groups for
1381            * @param start the lower bound of the range of groups to return
1382            * @param end the upper bound of the range of groups to return (not inclusive)
1383            * @return the range of user groups associated with the group
1384            * @throws SystemException if a system exception occurred
1385            */
1386            public java.util.List<com.liferay.portal.model.UserGroup> getUserGroups(
1387                    long pk, int start, int end)
1388                    throws com.liferay.portal.kernel.exception.SystemException;
1389    
1390            /**
1391            * Gets an ordered range of all the user groups associated with the group.
1392            *
1393            * <p>
1394            * 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.
1395            * </p>
1396            *
1397            * @param pk the primary key of the group to get the associated user groups for
1398            * @param start the lower bound of the range of groups to return
1399            * @param end the upper bound of the range of groups to return (not inclusive)
1400            * @param orderByComparator the comparator to order the results by
1401            * @return the ordered range of user groups associated with the group
1402            * @throws SystemException if a system exception occurred
1403            */
1404            public java.util.List<com.liferay.portal.model.UserGroup> getUserGroups(
1405                    long pk, int start, int end,
1406                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1407                    throws com.liferay.portal.kernel.exception.SystemException;
1408    
1409            /**
1410            * Gets the number of user groups associated with the group.
1411            *
1412            * @param pk the primary key of the group to get the number of associated user groups for
1413            * @return the number of user groups associated with the group
1414            * @throws SystemException if a system exception occurred
1415            */
1416            public int getUserGroupsSize(long pk)
1417                    throws com.liferay.portal.kernel.exception.SystemException;
1418    
1419            /**
1420            * Determines if the user group is associated with the group.
1421            *
1422            * @param pk the primary key of the group
1423            * @param userGroupPK the primary key of the user group
1424            * @return <code>true</code> if the user group is associated with the group; <code>false</code> otherwise
1425            * @throws SystemException if a system exception occurred
1426            */
1427            public boolean containsUserGroup(long pk, long userGroupPK)
1428                    throws com.liferay.portal.kernel.exception.SystemException;
1429    
1430            /**
1431            * Determines if the group has any user groups associated with it.
1432            *
1433            * @param pk the primary key of the group to check for associations with user groups
1434            * @return <code>true</code> if the group has any user groups associated with it; <code>false</code> otherwise
1435            * @throws SystemException if a system exception occurred
1436            */
1437            public boolean containsUserGroups(long pk)
1438                    throws com.liferay.portal.kernel.exception.SystemException;
1439    
1440            /**
1441            * Adds an association between the group and the user group. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1442            *
1443            * @param pk the primary key of the group
1444            * @param userGroupPK the primary key of the user group
1445            * @throws SystemException if a system exception occurred
1446            */
1447            public void addUserGroup(long pk, long userGroupPK)
1448                    throws com.liferay.portal.kernel.exception.SystemException;
1449    
1450            /**
1451            * Adds an association between the group and the user group. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1452            *
1453            * @param pk the primary key of the group
1454            * @param userGroup the user group
1455            * @throws SystemException if a system exception occurred
1456            */
1457            public void addUserGroup(long pk,
1458                    com.liferay.portal.model.UserGroup userGroup)
1459                    throws com.liferay.portal.kernel.exception.SystemException;
1460    
1461            /**
1462            * Adds an association between the group and the user groups. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1463            *
1464            * @param pk the primary key of the group
1465            * @param userGroupPKs the primary keys of the user groups
1466            * @throws SystemException if a system exception occurred
1467            */
1468            public void addUserGroups(long pk, long[] userGroupPKs)
1469                    throws com.liferay.portal.kernel.exception.SystemException;
1470    
1471            /**
1472            * Adds an association between the group and the user groups. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1473            *
1474            * @param pk the primary key of the group
1475            * @param userGroups the user groups
1476            * @throws SystemException if a system exception occurred
1477            */
1478            public void addUserGroups(long pk,
1479                    java.util.List<com.liferay.portal.model.UserGroup> userGroups)
1480                    throws com.liferay.portal.kernel.exception.SystemException;
1481    
1482            /**
1483            * Clears all associations between the group and its user groups. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1484            *
1485            * @param pk the primary key of the group to clear the associated user groups from
1486            * @throws SystemException if a system exception occurred
1487            */
1488            public void clearUserGroups(long pk)
1489                    throws com.liferay.portal.kernel.exception.SystemException;
1490    
1491            /**
1492            * Removes the association between the group and the user group. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1493            *
1494            * @param pk the primary key of the group
1495            * @param userGroupPK the primary key of the user group
1496            * @throws SystemException if a system exception occurred
1497            */
1498            public void removeUserGroup(long pk, long userGroupPK)
1499                    throws com.liferay.portal.kernel.exception.SystemException;
1500    
1501            /**
1502            * Removes the association between the group and the user group. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1503            *
1504            * @param pk the primary key of the group
1505            * @param userGroup the user group
1506            * @throws SystemException if a system exception occurred
1507            */
1508            public void removeUserGroup(long pk,
1509                    com.liferay.portal.model.UserGroup userGroup)
1510                    throws com.liferay.portal.kernel.exception.SystemException;
1511    
1512            /**
1513            * Removes the association between the group and the user groups. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1514            *
1515            * @param pk the primary key of the group
1516            * @param userGroupPKs the primary keys of the user groups
1517            * @throws SystemException if a system exception occurred
1518            */
1519            public void removeUserGroups(long pk, long[] userGroupPKs)
1520                    throws com.liferay.portal.kernel.exception.SystemException;
1521    
1522            /**
1523            * Removes the association between the group and the user groups. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1524            *
1525            * @param pk the primary key of the group
1526            * @param userGroups the user groups
1527            * @throws SystemException if a system exception occurred
1528            */
1529            public void removeUserGroups(long pk,
1530                    java.util.List<com.liferay.portal.model.UserGroup> userGroups)
1531                    throws com.liferay.portal.kernel.exception.SystemException;
1532    
1533            /**
1534            * Sets the user groups associated with the group, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1535            *
1536            * @param pk the primary key of the group to set the associations for
1537            * @param userGroupPKs the primary keys of the user groups to be associated with the group
1538            * @throws SystemException if a system exception occurred
1539            */
1540            public void setUserGroups(long pk, long[] userGroupPKs)
1541                    throws com.liferay.portal.kernel.exception.SystemException;
1542    
1543            /**
1544            * Sets the user groups associated with the group, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1545            *
1546            * @param pk the primary key of the group to set the associations for
1547            * @param userGroups the user groups to be associated with the group
1548            * @throws SystemException if a system exception occurred
1549            */
1550            public void setUserGroups(long pk,
1551                    java.util.List<com.liferay.portal.model.UserGroup> userGroups)
1552                    throws com.liferay.portal.kernel.exception.SystemException;
1553    
1554            /**
1555            * Gets all the users associated with the group.
1556            *
1557            * @param pk the primary key of the group to get the associated users for
1558            * @return the users associated with the group
1559            * @throws SystemException if a system exception occurred
1560            */
1561            public java.util.List<com.liferay.portal.model.User> getUsers(long pk)
1562                    throws com.liferay.portal.kernel.exception.SystemException;
1563    
1564            /**
1565            * Gets a range of all the users associated with the group.
1566            *
1567            * <p>
1568            * 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.
1569            * </p>
1570            *
1571            * @param pk the primary key of the group to get the associated users for
1572            * @param start the lower bound of the range of groups to return
1573            * @param end the upper bound of the range of groups to return (not inclusive)
1574            * @return the range of users associated with the group
1575            * @throws SystemException if a system exception occurred
1576            */
1577            public java.util.List<com.liferay.portal.model.User> getUsers(long pk,
1578                    int start, int end)
1579                    throws com.liferay.portal.kernel.exception.SystemException;
1580    
1581            /**
1582            * Gets an ordered range of all the users associated with the group.
1583            *
1584            * <p>
1585            * 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.
1586            * </p>
1587            *
1588            * @param pk the primary key of the group to get the associated users for
1589            * @param start the lower bound of the range of groups to return
1590            * @param end the upper bound of the range of groups to return (not inclusive)
1591            * @param orderByComparator the comparator to order the results by
1592            * @return the ordered range of users associated with the group
1593            * @throws SystemException if a system exception occurred
1594            */
1595            public java.util.List<com.liferay.portal.model.User> getUsers(long pk,
1596                    int start, int end,
1597                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
1598                    throws com.liferay.portal.kernel.exception.SystemException;
1599    
1600            /**
1601            * Gets the number of users associated with the group.
1602            *
1603            * @param pk the primary key of the group to get the number of associated users for
1604            * @return the number of users associated with the group
1605            * @throws SystemException if a system exception occurred
1606            */
1607            public int getUsersSize(long pk)
1608                    throws com.liferay.portal.kernel.exception.SystemException;
1609    
1610            /**
1611            * Determines if the user is associated with the group.
1612            *
1613            * @param pk the primary key of the group
1614            * @param userPK the primary key of the user
1615            * @return <code>true</code> if the user is associated with the group; <code>false</code> otherwise
1616            * @throws SystemException if a system exception occurred
1617            */
1618            public boolean containsUser(long pk, long userPK)
1619                    throws com.liferay.portal.kernel.exception.SystemException;
1620    
1621            /**
1622            * Determines if the group has any users associated with it.
1623            *
1624            * @param pk the primary key of the group to check for associations with users
1625            * @return <code>true</code> if the group has any users associated with it; <code>false</code> otherwise
1626            * @throws SystemException if a system exception occurred
1627            */
1628            public boolean containsUsers(long pk)
1629                    throws com.liferay.portal.kernel.exception.SystemException;
1630    
1631            /**
1632            * Adds an association between the group and the user. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1633            *
1634            * @param pk the primary key of the group
1635            * @param userPK the primary key of the user
1636            * @throws SystemException if a system exception occurred
1637            */
1638            public void addUser(long pk, long userPK)
1639                    throws com.liferay.portal.kernel.exception.SystemException;
1640    
1641            /**
1642            * Adds an association between the group and the user. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1643            *
1644            * @param pk the primary key of the group
1645            * @param user the user
1646            * @throws SystemException if a system exception occurred
1647            */
1648            public void addUser(long pk, com.liferay.portal.model.User user)
1649                    throws com.liferay.portal.kernel.exception.SystemException;
1650    
1651            /**
1652            * Adds an association between the group and the users. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1653            *
1654            * @param pk the primary key of the group
1655            * @param userPKs the primary keys of the users
1656            * @throws SystemException if a system exception occurred
1657            */
1658            public void addUsers(long pk, long[] userPKs)
1659                    throws com.liferay.portal.kernel.exception.SystemException;
1660    
1661            /**
1662            * Adds an association between the group and the users. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1663            *
1664            * @param pk the primary key of the group
1665            * @param users the users
1666            * @throws SystemException if a system exception occurred
1667            */
1668            public void addUsers(long pk,
1669                    java.util.List<com.liferay.portal.model.User> users)
1670                    throws com.liferay.portal.kernel.exception.SystemException;
1671    
1672            /**
1673            * Clears all associations between the group and its users. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1674            *
1675            * @param pk the primary key of the group to clear the associated users from
1676            * @throws SystemException if a system exception occurred
1677            */
1678            public void clearUsers(long pk)
1679                    throws com.liferay.portal.kernel.exception.SystemException;
1680    
1681            /**
1682            * Removes the association between the group and the user. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1683            *
1684            * @param pk the primary key of the group
1685            * @param userPK the primary key of the user
1686            * @throws SystemException if a system exception occurred
1687            */
1688            public void removeUser(long pk, long userPK)
1689                    throws com.liferay.portal.kernel.exception.SystemException;
1690    
1691            /**
1692            * Removes the association between the group and the user. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1693            *
1694            * @param pk the primary key of the group
1695            * @param user the user
1696            * @throws SystemException if a system exception occurred
1697            */
1698            public void removeUser(long pk, com.liferay.portal.model.User user)
1699                    throws com.liferay.portal.kernel.exception.SystemException;
1700    
1701            /**
1702            * Removes the association between the group and the users. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1703            *
1704            * @param pk the primary key of the group
1705            * @param userPKs the primary keys of the users
1706            * @throws SystemException if a system exception occurred
1707            */
1708            public void removeUsers(long pk, long[] userPKs)
1709                    throws com.liferay.portal.kernel.exception.SystemException;
1710    
1711            /**
1712            * Removes the association between the group and the users. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1713            *
1714            * @param pk the primary key of the group
1715            * @param users the users
1716            * @throws SystemException if a system exception occurred
1717            */
1718            public void removeUsers(long pk,
1719                    java.util.List<com.liferay.portal.model.User> users)
1720                    throws com.liferay.portal.kernel.exception.SystemException;
1721    
1722            /**
1723            * Sets the users associated with the group, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1724            *
1725            * @param pk the primary key of the group to set the associations for
1726            * @param userPKs the primary keys of the users to be associated with the group
1727            * @throws SystemException if a system exception occurred
1728            */
1729            public void setUsers(long pk, long[] userPKs)
1730                    throws com.liferay.portal.kernel.exception.SystemException;
1731    
1732            /**
1733            * Sets the users associated with the group, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1734            *
1735            * @param pk the primary key of the group to set the associations for
1736            * @param users the users to be associated with the group
1737            * @throws SystemException if a system exception occurred
1738            */
1739            public void setUsers(long pk,
1740                    java.util.List<com.liferay.portal.model.User> users)
1741                    throws com.liferay.portal.kernel.exception.SystemException;
1742    
1743            public Group remove(Group group) throws SystemException;
1744    }