001    /**
002     * Copyright (c) 2000-2013 Liferay, Inc. All rights reserved.
003     *
004     * This library is free software; you can redistribute it and/or modify it under
005     * the terms of the GNU Lesser General Public License as published by the Free
006     * Software Foundation; either version 2.1 of the License, or (at your option)
007     * any later version.
008     *
009     * This library is distributed in the hope that it will be useful, but WITHOUT
010     * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
011     * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
012     * details.
013     */
014    
015    package com.liferay.portlet.social.service.persistence;
016    
017    import com.liferay.portal.service.persistence.BasePersistence;
018    
019    import com.liferay.portlet.social.model.SocialActivityAchievement;
020    
021    /**
022     * The persistence interface for the social activity achievement service.
023     *
024     * <p>
025     * Caching information and settings can be found in <code>portal.properties</code>
026     * </p>
027     *
028     * @author Brian Wing Shun Chan
029     * @see SocialActivityAchievementPersistenceImpl
030     * @see SocialActivityAchievementUtil
031     * @generated
032     */
033    public interface SocialActivityAchievementPersistence extends BasePersistence<SocialActivityAchievement> {
034            /*
035             * NOTE FOR DEVELOPERS:
036             *
037             * Never modify or reference this interface directly. Always use {@link SocialActivityAchievementUtil} to access the social activity achievement persistence. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this interface.
038             */
039    
040            /**
041            * Caches the social activity achievement in the entity cache if it is enabled.
042            *
043            * @param socialActivityAchievement the social activity achievement
044            */
045            public void cacheResult(
046                    com.liferay.portlet.social.model.SocialActivityAchievement socialActivityAchievement);
047    
048            /**
049            * Caches the social activity achievements in the entity cache if it is enabled.
050            *
051            * @param socialActivityAchievements the social activity achievements
052            */
053            public void cacheResult(
054                    java.util.List<com.liferay.portlet.social.model.SocialActivityAchievement> socialActivityAchievements);
055    
056            /**
057            * Creates a new social activity achievement with the primary key. Does not add the social activity achievement to the database.
058            *
059            * @param activityAchievementId the primary key for the new social activity achievement
060            * @return the new social activity achievement
061            */
062            public com.liferay.portlet.social.model.SocialActivityAchievement create(
063                    long activityAchievementId);
064    
065            /**
066            * Removes the social activity achievement with the primary key from the database. Also notifies the appropriate model listeners.
067            *
068            * @param activityAchievementId the primary key of the social activity achievement
069            * @return the social activity achievement that was removed
070            * @throws com.liferay.portlet.social.NoSuchActivityAchievementException if a social activity achievement with the primary key could not be found
071            * @throws SystemException if a system exception occurred
072            */
073            public com.liferay.portlet.social.model.SocialActivityAchievement remove(
074                    long activityAchievementId)
075                    throws com.liferay.portal.kernel.exception.SystemException,
076                            com.liferay.portlet.social.NoSuchActivityAchievementException;
077    
078            public com.liferay.portlet.social.model.SocialActivityAchievement updateImpl(
079                    com.liferay.portlet.social.model.SocialActivityAchievement socialActivityAchievement,
080                    boolean merge)
081                    throws com.liferay.portal.kernel.exception.SystemException;
082    
083            /**
084            * Returns the social activity achievement with the primary key or throws a {@link com.liferay.portlet.social.NoSuchActivityAchievementException} if it could not be found.
085            *
086            * @param activityAchievementId the primary key of the social activity achievement
087            * @return the social activity achievement
088            * @throws com.liferay.portlet.social.NoSuchActivityAchievementException if a social activity achievement with the primary key could not be found
089            * @throws SystemException if a system exception occurred
090            */
091            public com.liferay.portlet.social.model.SocialActivityAchievement findByPrimaryKey(
092                    long activityAchievementId)
093                    throws com.liferay.portal.kernel.exception.SystemException,
094                            com.liferay.portlet.social.NoSuchActivityAchievementException;
095    
096            /**
097            * Returns the social activity achievement with the primary key or returns <code>null</code> if it could not be found.
098            *
099            * @param activityAchievementId the primary key of the social activity achievement
100            * @return the social activity achievement, or <code>null</code> if a social activity achievement with the primary key could not be found
101            * @throws SystemException if a system exception occurred
102            */
103            public com.liferay.portlet.social.model.SocialActivityAchievement fetchByPrimaryKey(
104                    long activityAchievementId)
105                    throws com.liferay.portal.kernel.exception.SystemException;
106    
107            /**
108            * Returns all the social activity achievements where groupId = &#63;.
109            *
110            * @param groupId the group ID
111            * @return the matching social activity achievements
112            * @throws SystemException if a system exception occurred
113            */
114            public java.util.List<com.liferay.portlet.social.model.SocialActivityAchievement> findByGroupId(
115                    long groupId)
116                    throws com.liferay.portal.kernel.exception.SystemException;
117    
118            /**
119            * Returns a range of all the social activity achievements where groupId = &#63;.
120            *
121            * <p>
122            * 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.
123            * </p>
124            *
125            * @param groupId the group ID
126            * @param start the lower bound of the range of social activity achievements
127            * @param end the upper bound of the range of social activity achievements (not inclusive)
128            * @return the range of matching social activity achievements
129            * @throws SystemException if a system exception occurred
130            */
131            public java.util.List<com.liferay.portlet.social.model.SocialActivityAchievement> findByGroupId(
132                    long groupId, int start, int end)
133                    throws com.liferay.portal.kernel.exception.SystemException;
134    
135            /**
136            * Returns an ordered range of all the social activity achievements where groupId = &#63;.
137            *
138            * <p>
139            * 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.
140            * </p>
141            *
142            * @param groupId the group ID
143            * @param start the lower bound of the range of social activity achievements
144            * @param end the upper bound of the range of social activity achievements (not inclusive)
145            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
146            * @return the ordered range of matching social activity achievements
147            * @throws SystemException if a system exception occurred
148            */
149            public java.util.List<com.liferay.portlet.social.model.SocialActivityAchievement> findByGroupId(
150                    long groupId, int start, int end,
151                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
152                    throws com.liferay.portal.kernel.exception.SystemException;
153    
154            /**
155            * Returns the first social activity achievement in the ordered set where groupId = &#63;.
156            *
157            * @param groupId the group ID
158            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
159            * @return the first matching social activity achievement
160            * @throws com.liferay.portlet.social.NoSuchActivityAchievementException if a matching social activity achievement could not be found
161            * @throws SystemException if a system exception occurred
162            */
163            public com.liferay.portlet.social.model.SocialActivityAchievement findByGroupId_First(
164                    long groupId,
165                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
166                    throws com.liferay.portal.kernel.exception.SystemException,
167                            com.liferay.portlet.social.NoSuchActivityAchievementException;
168    
169            /**
170            * Returns the first social activity achievement in the ordered set where groupId = &#63;.
171            *
172            * @param groupId the group ID
173            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
174            * @return the first matching social activity achievement, or <code>null</code> if a matching social activity achievement could not be found
175            * @throws SystemException if a system exception occurred
176            */
177            public com.liferay.portlet.social.model.SocialActivityAchievement fetchByGroupId_First(
178                    long groupId,
179                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
180                    throws com.liferay.portal.kernel.exception.SystemException;
181    
182            /**
183            * Returns the last social activity achievement in the ordered set where groupId = &#63;.
184            *
185            * @param groupId the group ID
186            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
187            * @return the last matching social activity achievement
188            * @throws com.liferay.portlet.social.NoSuchActivityAchievementException if a matching social activity achievement could not be found
189            * @throws SystemException if a system exception occurred
190            */
191            public com.liferay.portlet.social.model.SocialActivityAchievement findByGroupId_Last(
192                    long groupId,
193                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
194                    throws com.liferay.portal.kernel.exception.SystemException,
195                            com.liferay.portlet.social.NoSuchActivityAchievementException;
196    
197            /**
198            * Returns the last social activity achievement in the ordered set where groupId = &#63;.
199            *
200            * @param groupId the group ID
201            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
202            * @return the last matching social activity achievement, or <code>null</code> if a matching social activity achievement could not be found
203            * @throws SystemException if a system exception occurred
204            */
205            public com.liferay.portlet.social.model.SocialActivityAchievement fetchByGroupId_Last(
206                    long groupId,
207                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
208                    throws com.liferay.portal.kernel.exception.SystemException;
209    
210            /**
211            * Returns the social activity achievements before and after the current social activity achievement in the ordered set where groupId = &#63;.
212            *
213            * @param activityAchievementId the primary key of the current social activity achievement
214            * @param groupId the group ID
215            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
216            * @return the previous, current, and next social activity achievement
217            * @throws com.liferay.portlet.social.NoSuchActivityAchievementException if a social activity achievement with the primary key could not be found
218            * @throws SystemException if a system exception occurred
219            */
220            public com.liferay.portlet.social.model.SocialActivityAchievement[] findByGroupId_PrevAndNext(
221                    long activityAchievementId, long groupId,
222                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
223                    throws com.liferay.portal.kernel.exception.SystemException,
224                            com.liferay.portlet.social.NoSuchActivityAchievementException;
225    
226            /**
227            * Returns all the social activity achievements where groupId = &#63; and userId = &#63;.
228            *
229            * @param groupId the group ID
230            * @param userId the user ID
231            * @return the matching social activity achievements
232            * @throws SystemException if a system exception occurred
233            */
234            public java.util.List<com.liferay.portlet.social.model.SocialActivityAchievement> findByG_U(
235                    long groupId, long userId)
236                    throws com.liferay.portal.kernel.exception.SystemException;
237    
238            /**
239            * Returns a range of all the social activity achievements where groupId = &#63; and userId = &#63;.
240            *
241            * <p>
242            * 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.
243            * </p>
244            *
245            * @param groupId the group ID
246            * @param userId the user ID
247            * @param start the lower bound of the range of social activity achievements
248            * @param end the upper bound of the range of social activity achievements (not inclusive)
249            * @return the range of matching social activity achievements
250            * @throws SystemException if a system exception occurred
251            */
252            public java.util.List<com.liferay.portlet.social.model.SocialActivityAchievement> findByG_U(
253                    long groupId, long userId, int start, int end)
254                    throws com.liferay.portal.kernel.exception.SystemException;
255    
256            /**
257            * Returns an ordered range of all the social activity achievements where groupId = &#63; and userId = &#63;.
258            *
259            * <p>
260            * 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.
261            * </p>
262            *
263            * @param groupId the group ID
264            * @param userId the user ID
265            * @param start the lower bound of the range of social activity achievements
266            * @param end the upper bound of the range of social activity achievements (not inclusive)
267            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
268            * @return the ordered range of matching social activity achievements
269            * @throws SystemException if a system exception occurred
270            */
271            public java.util.List<com.liferay.portlet.social.model.SocialActivityAchievement> findByG_U(
272                    long groupId, long userId, int start, int end,
273                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
274                    throws com.liferay.portal.kernel.exception.SystemException;
275    
276            /**
277            * Returns the first social activity achievement in the ordered set where groupId = &#63; and userId = &#63;.
278            *
279            * @param groupId the group ID
280            * @param userId the user ID
281            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
282            * @return the first matching social activity achievement
283            * @throws com.liferay.portlet.social.NoSuchActivityAchievementException if a matching social activity achievement could not be found
284            * @throws SystemException if a system exception occurred
285            */
286            public com.liferay.portlet.social.model.SocialActivityAchievement findByG_U_First(
287                    long groupId, long userId,
288                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
289                    throws com.liferay.portal.kernel.exception.SystemException,
290                            com.liferay.portlet.social.NoSuchActivityAchievementException;
291    
292            /**
293            * Returns the first social activity achievement in the ordered set where groupId = &#63; and userId = &#63;.
294            *
295            * @param groupId the group ID
296            * @param userId the user ID
297            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
298            * @return the first matching social activity achievement, or <code>null</code> if a matching social activity achievement could not be found
299            * @throws SystemException if a system exception occurred
300            */
301            public com.liferay.portlet.social.model.SocialActivityAchievement fetchByG_U_First(
302                    long groupId, long userId,
303                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
304                    throws com.liferay.portal.kernel.exception.SystemException;
305    
306            /**
307            * Returns the last social activity achievement in the ordered set where groupId = &#63; and userId = &#63;.
308            *
309            * @param groupId the group ID
310            * @param userId the user ID
311            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
312            * @return the last matching social activity achievement
313            * @throws com.liferay.portlet.social.NoSuchActivityAchievementException if a matching social activity achievement could not be found
314            * @throws SystemException if a system exception occurred
315            */
316            public com.liferay.portlet.social.model.SocialActivityAchievement findByG_U_Last(
317                    long groupId, long userId,
318                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
319                    throws com.liferay.portal.kernel.exception.SystemException,
320                            com.liferay.portlet.social.NoSuchActivityAchievementException;
321    
322            /**
323            * Returns the last social activity achievement in the ordered set where groupId = &#63; and userId = &#63;.
324            *
325            * @param groupId the group ID
326            * @param userId the user ID
327            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
328            * @return the last matching social activity achievement, or <code>null</code> if a matching social activity achievement could not be found
329            * @throws SystemException if a system exception occurred
330            */
331            public com.liferay.portlet.social.model.SocialActivityAchievement fetchByG_U_Last(
332                    long groupId, long userId,
333                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
334                    throws com.liferay.portal.kernel.exception.SystemException;
335    
336            /**
337            * Returns the social activity achievements before and after the current social activity achievement in the ordered set where groupId = &#63; and userId = &#63;.
338            *
339            * @param activityAchievementId the primary key of the current social activity achievement
340            * @param groupId the group ID
341            * @param userId the user ID
342            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
343            * @return the previous, current, and next social activity achievement
344            * @throws com.liferay.portlet.social.NoSuchActivityAchievementException if a social activity achievement with the primary key could not be found
345            * @throws SystemException if a system exception occurred
346            */
347            public com.liferay.portlet.social.model.SocialActivityAchievement[] findByG_U_PrevAndNext(
348                    long activityAchievementId, long groupId, long userId,
349                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
350                    throws com.liferay.portal.kernel.exception.SystemException,
351                            com.liferay.portlet.social.NoSuchActivityAchievementException;
352    
353            /**
354            * Returns all the social activity achievements where groupId = &#63; and name = &#63;.
355            *
356            * @param groupId the group ID
357            * @param name the name
358            * @return the matching social activity achievements
359            * @throws SystemException if a system exception occurred
360            */
361            public java.util.List<com.liferay.portlet.social.model.SocialActivityAchievement> findByG_N(
362                    long groupId, java.lang.String name)
363                    throws com.liferay.portal.kernel.exception.SystemException;
364    
365            /**
366            * Returns a range of all the social activity achievements where groupId = &#63; and name = &#63;.
367            *
368            * <p>
369            * 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.
370            * </p>
371            *
372            * @param groupId the group ID
373            * @param name the name
374            * @param start the lower bound of the range of social activity achievements
375            * @param end the upper bound of the range of social activity achievements (not inclusive)
376            * @return the range of matching social activity achievements
377            * @throws SystemException if a system exception occurred
378            */
379            public java.util.List<com.liferay.portlet.social.model.SocialActivityAchievement> findByG_N(
380                    long groupId, java.lang.String name, int start, int end)
381                    throws com.liferay.portal.kernel.exception.SystemException;
382    
383            /**
384            * Returns an ordered range of all the social activity achievements where groupId = &#63; and name = &#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 groupId the group ID
391            * @param name the name
392            * @param start the lower bound of the range of social activity achievements
393            * @param end the upper bound of the range of social activity achievements (not inclusive)
394            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
395            * @return the ordered range of matching social activity achievements
396            * @throws SystemException if a system exception occurred
397            */
398            public java.util.List<com.liferay.portlet.social.model.SocialActivityAchievement> findByG_N(
399                    long groupId, java.lang.String name, int start, int end,
400                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
401                    throws com.liferay.portal.kernel.exception.SystemException;
402    
403            /**
404            * Returns the first social activity achievement in the ordered set where groupId = &#63; and name = &#63;.
405            *
406            * @param groupId the group ID
407            * @param name the name
408            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
409            * @return the first matching social activity achievement
410            * @throws com.liferay.portlet.social.NoSuchActivityAchievementException if a matching social activity achievement could not be found
411            * @throws SystemException if a system exception occurred
412            */
413            public com.liferay.portlet.social.model.SocialActivityAchievement findByG_N_First(
414                    long groupId, java.lang.String name,
415                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
416                    throws com.liferay.portal.kernel.exception.SystemException,
417                            com.liferay.portlet.social.NoSuchActivityAchievementException;
418    
419            /**
420            * Returns the first social activity achievement in the ordered set where groupId = &#63; and name = &#63;.
421            *
422            * @param groupId the group ID
423            * @param name the name
424            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
425            * @return the first matching social activity achievement, or <code>null</code> if a matching social activity achievement could not be found
426            * @throws SystemException if a system exception occurred
427            */
428            public com.liferay.portlet.social.model.SocialActivityAchievement fetchByG_N_First(
429                    long groupId, java.lang.String name,
430                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
431                    throws com.liferay.portal.kernel.exception.SystemException;
432    
433            /**
434            * Returns the last social activity achievement in the ordered set where groupId = &#63; and name = &#63;.
435            *
436            * @param groupId the group ID
437            * @param name the name
438            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
439            * @return the last matching social activity achievement
440            * @throws com.liferay.portlet.social.NoSuchActivityAchievementException if a matching social activity achievement could not be found
441            * @throws SystemException if a system exception occurred
442            */
443            public com.liferay.portlet.social.model.SocialActivityAchievement findByG_N_Last(
444                    long groupId, java.lang.String name,
445                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
446                    throws com.liferay.portal.kernel.exception.SystemException,
447                            com.liferay.portlet.social.NoSuchActivityAchievementException;
448    
449            /**
450            * Returns the last social activity achievement in the ordered set where groupId = &#63; and name = &#63;.
451            *
452            * @param groupId the group ID
453            * @param name the name
454            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
455            * @return the last matching social activity achievement, or <code>null</code> if a matching social activity achievement could not be found
456            * @throws SystemException if a system exception occurred
457            */
458            public com.liferay.portlet.social.model.SocialActivityAchievement fetchByG_N_Last(
459                    long groupId, java.lang.String name,
460                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
461                    throws com.liferay.portal.kernel.exception.SystemException;
462    
463            /**
464            * Returns the social activity achievements before and after the current social activity achievement in the ordered set where groupId = &#63; and name = &#63;.
465            *
466            * @param activityAchievementId the primary key of the current social activity achievement
467            * @param groupId the group ID
468            * @param name the name
469            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
470            * @return the previous, current, and next social activity achievement
471            * @throws com.liferay.portlet.social.NoSuchActivityAchievementException if a social activity achievement with the primary key could not be found
472            * @throws SystemException if a system exception occurred
473            */
474            public com.liferay.portlet.social.model.SocialActivityAchievement[] findByG_N_PrevAndNext(
475                    long activityAchievementId, long groupId, java.lang.String name,
476                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
477                    throws com.liferay.portal.kernel.exception.SystemException,
478                            com.liferay.portlet.social.NoSuchActivityAchievementException;
479    
480            /**
481            * Returns all the social activity achievements where groupId = &#63; and firstInGroup = &#63;.
482            *
483            * @param groupId the group ID
484            * @param firstInGroup the first in group
485            * @return the matching social activity achievements
486            * @throws SystemException if a system exception occurred
487            */
488            public java.util.List<com.liferay.portlet.social.model.SocialActivityAchievement> findByG_F(
489                    long groupId, boolean firstInGroup)
490                    throws com.liferay.portal.kernel.exception.SystemException;
491    
492            /**
493            * Returns a range of all the social activity achievements where groupId = &#63; and firstInGroup = &#63;.
494            *
495            * <p>
496            * 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.
497            * </p>
498            *
499            * @param groupId the group ID
500            * @param firstInGroup the first in group
501            * @param start the lower bound of the range of social activity achievements
502            * @param end the upper bound of the range of social activity achievements (not inclusive)
503            * @return the range of matching social activity achievements
504            * @throws SystemException if a system exception occurred
505            */
506            public java.util.List<com.liferay.portlet.social.model.SocialActivityAchievement> findByG_F(
507                    long groupId, boolean firstInGroup, int start, int end)
508                    throws com.liferay.portal.kernel.exception.SystemException;
509    
510            /**
511            * Returns an ordered range of all the social activity achievements where groupId = &#63; and firstInGroup = &#63;.
512            *
513            * <p>
514            * 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.
515            * </p>
516            *
517            * @param groupId the group ID
518            * @param firstInGroup the first in group
519            * @param start the lower bound of the range of social activity achievements
520            * @param end the upper bound of the range of social activity achievements (not inclusive)
521            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
522            * @return the ordered range of matching social activity achievements
523            * @throws SystemException if a system exception occurred
524            */
525            public java.util.List<com.liferay.portlet.social.model.SocialActivityAchievement> findByG_F(
526                    long groupId, boolean firstInGroup, int start, int end,
527                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
528                    throws com.liferay.portal.kernel.exception.SystemException;
529    
530            /**
531            * Returns the first social activity achievement in the ordered set where groupId = &#63; and firstInGroup = &#63;.
532            *
533            * @param groupId the group ID
534            * @param firstInGroup the first in group
535            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
536            * @return the first matching social activity achievement
537            * @throws com.liferay.portlet.social.NoSuchActivityAchievementException if a matching social activity achievement could not be found
538            * @throws SystemException if a system exception occurred
539            */
540            public com.liferay.portlet.social.model.SocialActivityAchievement findByG_F_First(
541                    long groupId, boolean firstInGroup,
542                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
543                    throws com.liferay.portal.kernel.exception.SystemException,
544                            com.liferay.portlet.social.NoSuchActivityAchievementException;
545    
546            /**
547            * Returns the first social activity achievement in the ordered set where groupId = &#63; and firstInGroup = &#63;.
548            *
549            * @param groupId the group ID
550            * @param firstInGroup the first in group
551            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
552            * @return the first matching social activity achievement, or <code>null</code> if a matching social activity achievement could not be found
553            * @throws SystemException if a system exception occurred
554            */
555            public com.liferay.portlet.social.model.SocialActivityAchievement fetchByG_F_First(
556                    long groupId, boolean firstInGroup,
557                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
558                    throws com.liferay.portal.kernel.exception.SystemException;
559    
560            /**
561            * Returns the last social activity achievement in the ordered set where groupId = &#63; and firstInGroup = &#63;.
562            *
563            * @param groupId the group ID
564            * @param firstInGroup the first in group
565            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
566            * @return the last matching social activity achievement
567            * @throws com.liferay.portlet.social.NoSuchActivityAchievementException if a matching social activity achievement could not be found
568            * @throws SystemException if a system exception occurred
569            */
570            public com.liferay.portlet.social.model.SocialActivityAchievement findByG_F_Last(
571                    long groupId, boolean firstInGroup,
572                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
573                    throws com.liferay.portal.kernel.exception.SystemException,
574                            com.liferay.portlet.social.NoSuchActivityAchievementException;
575    
576            /**
577            * Returns the last social activity achievement in the ordered set where groupId = &#63; and firstInGroup = &#63;.
578            *
579            * @param groupId the group ID
580            * @param firstInGroup the first in group
581            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
582            * @return the last matching social activity achievement, or <code>null</code> if a matching social activity achievement could not be found
583            * @throws SystemException if a system exception occurred
584            */
585            public com.liferay.portlet.social.model.SocialActivityAchievement fetchByG_F_Last(
586                    long groupId, boolean firstInGroup,
587                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
588                    throws com.liferay.portal.kernel.exception.SystemException;
589    
590            /**
591            * Returns the social activity achievements before and after the current social activity achievement in the ordered set where groupId = &#63; and firstInGroup = &#63;.
592            *
593            * @param activityAchievementId the primary key of the current social activity achievement
594            * @param groupId the group ID
595            * @param firstInGroup the first in group
596            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
597            * @return the previous, current, and next social activity achievement
598            * @throws com.liferay.portlet.social.NoSuchActivityAchievementException if a social activity achievement with the primary key could not be found
599            * @throws SystemException if a system exception occurred
600            */
601            public com.liferay.portlet.social.model.SocialActivityAchievement[] findByG_F_PrevAndNext(
602                    long activityAchievementId, long groupId, boolean firstInGroup,
603                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
604                    throws com.liferay.portal.kernel.exception.SystemException,
605                            com.liferay.portlet.social.NoSuchActivityAchievementException;
606    
607            /**
608            * Returns the social activity achievement where groupId = &#63; and userId = &#63; and name = &#63; or throws a {@link com.liferay.portlet.social.NoSuchActivityAchievementException} if it could not be found.
609            *
610            * @param groupId the group ID
611            * @param userId the user ID
612            * @param name the name
613            * @return the matching social activity achievement
614            * @throws com.liferay.portlet.social.NoSuchActivityAchievementException if a matching social activity achievement could not be found
615            * @throws SystemException if a system exception occurred
616            */
617            public com.liferay.portlet.social.model.SocialActivityAchievement findByG_U_N(
618                    long groupId, long userId, java.lang.String name)
619                    throws com.liferay.portal.kernel.exception.SystemException,
620                            com.liferay.portlet.social.NoSuchActivityAchievementException;
621    
622            /**
623            * Returns the social activity achievement where groupId = &#63; and userId = &#63; and name = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
624            *
625            * @param groupId the group ID
626            * @param userId the user ID
627            * @param name the name
628            * @return the matching social activity achievement, or <code>null</code> if a matching social activity achievement could not be found
629            * @throws SystemException if a system exception occurred
630            */
631            public com.liferay.portlet.social.model.SocialActivityAchievement fetchByG_U_N(
632                    long groupId, long userId, java.lang.String name)
633                    throws com.liferay.portal.kernel.exception.SystemException;
634    
635            /**
636            * Returns the social activity achievement where groupId = &#63; and userId = &#63; and name = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
637            *
638            * @param groupId the group ID
639            * @param userId the user ID
640            * @param name the name
641            * @param retrieveFromCache whether to use the finder cache
642            * @return the matching social activity achievement, or <code>null</code> if a matching social activity achievement could not be found
643            * @throws SystemException if a system exception occurred
644            */
645            public com.liferay.portlet.social.model.SocialActivityAchievement fetchByG_U_N(
646                    long groupId, long userId, java.lang.String name,
647                    boolean retrieveFromCache)
648                    throws com.liferay.portal.kernel.exception.SystemException;
649    
650            /**
651            * Returns all the social activity achievements where groupId = &#63; and userId = &#63; and firstInGroup = &#63;.
652            *
653            * @param groupId the group ID
654            * @param userId the user ID
655            * @param firstInGroup the first in group
656            * @return the matching social activity achievements
657            * @throws SystemException if a system exception occurred
658            */
659            public java.util.List<com.liferay.portlet.social.model.SocialActivityAchievement> findByG_U_F(
660                    long groupId, long userId, boolean firstInGroup)
661                    throws com.liferay.portal.kernel.exception.SystemException;
662    
663            /**
664            * Returns a range of all the social activity achievements where groupId = &#63; and userId = &#63; and firstInGroup = &#63;.
665            *
666            * <p>
667            * 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.
668            * </p>
669            *
670            * @param groupId the group ID
671            * @param userId the user ID
672            * @param firstInGroup the first in group
673            * @param start the lower bound of the range of social activity achievements
674            * @param end the upper bound of the range of social activity achievements (not inclusive)
675            * @return the range of matching social activity achievements
676            * @throws SystemException if a system exception occurred
677            */
678            public java.util.List<com.liferay.portlet.social.model.SocialActivityAchievement> findByG_U_F(
679                    long groupId, long userId, boolean firstInGroup, int start, int end)
680                    throws com.liferay.portal.kernel.exception.SystemException;
681    
682            /**
683            * Returns an ordered range of all the social activity achievements where groupId = &#63; and userId = &#63; and firstInGroup = &#63;.
684            *
685            * <p>
686            * 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.
687            * </p>
688            *
689            * @param groupId the group ID
690            * @param userId the user ID
691            * @param firstInGroup the first in group
692            * @param start the lower bound of the range of social activity achievements
693            * @param end the upper bound of the range of social activity achievements (not inclusive)
694            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
695            * @return the ordered range of matching social activity achievements
696            * @throws SystemException if a system exception occurred
697            */
698            public java.util.List<com.liferay.portlet.social.model.SocialActivityAchievement> findByG_U_F(
699                    long groupId, long userId, boolean firstInGroup, int start, int end,
700                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
701                    throws com.liferay.portal.kernel.exception.SystemException;
702    
703            /**
704            * Returns the first social activity achievement in the ordered set where groupId = &#63; and userId = &#63; and firstInGroup = &#63;.
705            *
706            * @param groupId the group ID
707            * @param userId the user ID
708            * @param firstInGroup the first in group
709            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
710            * @return the first matching social activity achievement
711            * @throws com.liferay.portlet.social.NoSuchActivityAchievementException if a matching social activity achievement could not be found
712            * @throws SystemException if a system exception occurred
713            */
714            public com.liferay.portlet.social.model.SocialActivityAchievement findByG_U_F_First(
715                    long groupId, long userId, boolean firstInGroup,
716                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
717                    throws com.liferay.portal.kernel.exception.SystemException,
718                            com.liferay.portlet.social.NoSuchActivityAchievementException;
719    
720            /**
721            * Returns the first social activity achievement in the ordered set where groupId = &#63; and userId = &#63; and firstInGroup = &#63;.
722            *
723            * @param groupId the group ID
724            * @param userId the user ID
725            * @param firstInGroup the first in group
726            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
727            * @return the first matching social activity achievement, or <code>null</code> if a matching social activity achievement could not be found
728            * @throws SystemException if a system exception occurred
729            */
730            public com.liferay.portlet.social.model.SocialActivityAchievement fetchByG_U_F_First(
731                    long groupId, long userId, boolean firstInGroup,
732                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
733                    throws com.liferay.portal.kernel.exception.SystemException;
734    
735            /**
736            * Returns the last social activity achievement in the ordered set where groupId = &#63; and userId = &#63; and firstInGroup = &#63;.
737            *
738            * @param groupId the group ID
739            * @param userId the user ID
740            * @param firstInGroup the first in group
741            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
742            * @return the last matching social activity achievement
743            * @throws com.liferay.portlet.social.NoSuchActivityAchievementException if a matching social activity achievement could not be found
744            * @throws SystemException if a system exception occurred
745            */
746            public com.liferay.portlet.social.model.SocialActivityAchievement findByG_U_F_Last(
747                    long groupId, long userId, boolean firstInGroup,
748                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
749                    throws com.liferay.portal.kernel.exception.SystemException,
750                            com.liferay.portlet.social.NoSuchActivityAchievementException;
751    
752            /**
753            * Returns the last social activity achievement in the ordered set where groupId = &#63; and userId = &#63; and firstInGroup = &#63;.
754            *
755            * @param groupId the group ID
756            * @param userId the user ID
757            * @param firstInGroup the first in group
758            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
759            * @return the last matching social activity achievement, or <code>null</code> if a matching social activity achievement could not be found
760            * @throws SystemException if a system exception occurred
761            */
762            public com.liferay.portlet.social.model.SocialActivityAchievement fetchByG_U_F_Last(
763                    long groupId, long userId, boolean firstInGroup,
764                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
765                    throws com.liferay.portal.kernel.exception.SystemException;
766    
767            /**
768            * Returns the social activity achievements before and after the current social activity achievement in the ordered set where groupId = &#63; and userId = &#63; and firstInGroup = &#63;.
769            *
770            * @param activityAchievementId the primary key of the current social activity achievement
771            * @param groupId the group ID
772            * @param userId the user ID
773            * @param firstInGroup the first in group
774            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
775            * @return the previous, current, and next social activity achievement
776            * @throws com.liferay.portlet.social.NoSuchActivityAchievementException if a social activity achievement with the primary key could not be found
777            * @throws SystemException if a system exception occurred
778            */
779            public com.liferay.portlet.social.model.SocialActivityAchievement[] findByG_U_F_PrevAndNext(
780                    long activityAchievementId, long groupId, long userId,
781                    boolean firstInGroup,
782                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
783                    throws com.liferay.portal.kernel.exception.SystemException,
784                            com.liferay.portlet.social.NoSuchActivityAchievementException;
785    
786            /**
787            * Returns all the social activity achievements.
788            *
789            * @return the social activity achievements
790            * @throws SystemException if a system exception occurred
791            */
792            public java.util.List<com.liferay.portlet.social.model.SocialActivityAchievement> findAll()
793                    throws com.liferay.portal.kernel.exception.SystemException;
794    
795            /**
796            * Returns a range of all the social activity achievements.
797            *
798            * <p>
799            * 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.
800            * </p>
801            *
802            * @param start the lower bound of the range of social activity achievements
803            * @param end the upper bound of the range of social activity achievements (not inclusive)
804            * @return the range of social activity achievements
805            * @throws SystemException if a system exception occurred
806            */
807            public java.util.List<com.liferay.portlet.social.model.SocialActivityAchievement> findAll(
808                    int start, int end)
809                    throws com.liferay.portal.kernel.exception.SystemException;
810    
811            /**
812            * Returns an ordered range of all the social activity achievements.
813            *
814            * <p>
815            * 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.
816            * </p>
817            *
818            * @param start the lower bound of the range of social activity achievements
819            * @param end the upper bound of the range of social activity achievements (not inclusive)
820            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
821            * @return the ordered range of social activity achievements
822            * @throws SystemException if a system exception occurred
823            */
824            public java.util.List<com.liferay.portlet.social.model.SocialActivityAchievement> findAll(
825                    int start, int end,
826                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
827                    throws com.liferay.portal.kernel.exception.SystemException;
828    
829            /**
830            * Removes all the social activity achievements where groupId = &#63; from the database.
831            *
832            * @param groupId the group ID
833            * @throws SystemException if a system exception occurred
834            */
835            public void removeByGroupId(long groupId)
836                    throws com.liferay.portal.kernel.exception.SystemException;
837    
838            /**
839            * Removes all the social activity achievements where groupId = &#63; and userId = &#63; from the database.
840            *
841            * @param groupId the group ID
842            * @param userId the user ID
843            * @throws SystemException if a system exception occurred
844            */
845            public void removeByG_U(long groupId, long userId)
846                    throws com.liferay.portal.kernel.exception.SystemException;
847    
848            /**
849            * Removes all the social activity achievements where groupId = &#63; and name = &#63; from the database.
850            *
851            * @param groupId the group ID
852            * @param name the name
853            * @throws SystemException if a system exception occurred
854            */
855            public void removeByG_N(long groupId, java.lang.String name)
856                    throws com.liferay.portal.kernel.exception.SystemException;
857    
858            /**
859            * Removes all the social activity achievements where groupId = &#63; and firstInGroup = &#63; from the database.
860            *
861            * @param groupId the group ID
862            * @param firstInGroup the first in group
863            * @throws SystemException if a system exception occurred
864            */
865            public void removeByG_F(long groupId, boolean firstInGroup)
866                    throws com.liferay.portal.kernel.exception.SystemException;
867    
868            /**
869            * Removes the social activity achievement where groupId = &#63; and userId = &#63; and name = &#63; from the database.
870            *
871            * @param groupId the group ID
872            * @param userId the user ID
873            * @param name the name
874            * @return the social activity achievement that was removed
875            * @throws SystemException if a system exception occurred
876            */
877            public com.liferay.portlet.social.model.SocialActivityAchievement removeByG_U_N(
878                    long groupId, long userId, java.lang.String name)
879                    throws com.liferay.portal.kernel.exception.SystemException,
880                            com.liferay.portlet.social.NoSuchActivityAchievementException;
881    
882            /**
883            * Removes all the social activity achievements where groupId = &#63; and userId = &#63; and firstInGroup = &#63; from the database.
884            *
885            * @param groupId the group ID
886            * @param userId the user ID
887            * @param firstInGroup the first in group
888            * @throws SystemException if a system exception occurred
889            */
890            public void removeByG_U_F(long groupId, long userId, boolean firstInGroup)
891                    throws com.liferay.portal.kernel.exception.SystemException;
892    
893            /**
894            * Removes all the social activity achievements from the database.
895            *
896            * @throws SystemException if a system exception occurred
897            */
898            public void removeAll()
899                    throws com.liferay.portal.kernel.exception.SystemException;
900    
901            /**
902            * Returns the number of social activity achievements where groupId = &#63;.
903            *
904            * @param groupId the group ID
905            * @return the number of matching social activity achievements
906            * @throws SystemException if a system exception occurred
907            */
908            public int countByGroupId(long groupId)
909                    throws com.liferay.portal.kernel.exception.SystemException;
910    
911            /**
912            * Returns the number of social activity achievements where groupId = &#63; and userId = &#63;.
913            *
914            * @param groupId the group ID
915            * @param userId the user ID
916            * @return the number of matching social activity achievements
917            * @throws SystemException if a system exception occurred
918            */
919            public int countByG_U(long groupId, long userId)
920                    throws com.liferay.portal.kernel.exception.SystemException;
921    
922            /**
923            * Returns the number of social activity achievements where groupId = &#63; and name = &#63;.
924            *
925            * @param groupId the group ID
926            * @param name the name
927            * @return the number of matching social activity achievements
928            * @throws SystemException if a system exception occurred
929            */
930            public int countByG_N(long groupId, java.lang.String name)
931                    throws com.liferay.portal.kernel.exception.SystemException;
932    
933            /**
934            * Returns the number of social activity achievements where groupId = &#63; and firstInGroup = &#63;.
935            *
936            * @param groupId the group ID
937            * @param firstInGroup the first in group
938            * @return the number of matching social activity achievements
939            * @throws SystemException if a system exception occurred
940            */
941            public int countByG_F(long groupId, boolean firstInGroup)
942                    throws com.liferay.portal.kernel.exception.SystemException;
943    
944            /**
945            * Returns the number of social activity achievements where groupId = &#63; and userId = &#63; and name = &#63;.
946            *
947            * @param groupId the group ID
948            * @param userId the user ID
949            * @param name the name
950            * @return the number of matching social activity achievements
951            * @throws SystemException if a system exception occurred
952            */
953            public int countByG_U_N(long groupId, long userId, java.lang.String name)
954                    throws com.liferay.portal.kernel.exception.SystemException;
955    
956            /**
957            * Returns the number of social activity achievements where groupId = &#63; and userId = &#63; and firstInGroup = &#63;.
958            *
959            * @param groupId the group ID
960            * @param userId the user ID
961            * @param firstInGroup the first in group
962            * @return the number of matching social activity achievements
963            * @throws SystemException if a system exception occurred
964            */
965            public int countByG_U_F(long groupId, long userId, boolean firstInGroup)
966                    throws com.liferay.portal.kernel.exception.SystemException;
967    
968            /**
969            * Returns the number of social activity achievements.
970            *
971            * @return the number of social activity achievements
972            * @throws SystemException if a system exception occurred
973            */
974            public int countAll()
975                    throws com.liferay.portal.kernel.exception.SystemException;
976    }