001    /**
002     * Copyright (c) 2000-2012 Liferay, Inc. All rights reserved.
003     *
004     * This library is free software; you can redistribute it and/or modify it under
005     * the terms of the GNU Lesser General Public License as published by the Free
006     * Software Foundation; either version 2.1 of the License, or (at your option)
007     * any later version.
008     *
009     * This library is distributed in the hope that it will be useful, but WITHOUT
010     * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
011     * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
012     * details.
013     */
014    
015    package com.liferay.portal.service.persistence;
016    
017    import com.liferay.portal.model.MembershipRequest;
018    
019    /**
020     * The persistence interface for the membership request service.
021     *
022     * <p>
023     * Caching information and settings can be found in <code>portal.properties</code>
024     * </p>
025     *
026     * @author Brian Wing Shun Chan
027     * @see MembershipRequestPersistenceImpl
028     * @see MembershipRequestUtil
029     * @generated
030     */
031    public interface MembershipRequestPersistence extends BasePersistence<MembershipRequest> {
032            /*
033             * NOTE FOR DEVELOPERS:
034             *
035             * Never modify or reference this interface directly. Always use {@link MembershipRequestUtil} to access the membership request persistence. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this interface.
036             */
037    
038            /**
039            * Caches the membership request in the entity cache if it is enabled.
040            *
041            * @param membershipRequest the membership request
042            */
043            public void cacheResult(
044                    com.liferay.portal.model.MembershipRequest membershipRequest);
045    
046            /**
047            * Caches the membership requests in the entity cache if it is enabled.
048            *
049            * @param membershipRequests the membership requests
050            */
051            public void cacheResult(
052                    java.util.List<com.liferay.portal.model.MembershipRequest> membershipRequests);
053    
054            /**
055            * Creates a new membership request with the primary key. Does not add the membership request to the database.
056            *
057            * @param membershipRequestId the primary key for the new membership request
058            * @return the new membership request
059            */
060            public com.liferay.portal.model.MembershipRequest create(
061                    long membershipRequestId);
062    
063            /**
064            * Removes the membership request with the primary key from the database. Also notifies the appropriate model listeners.
065            *
066            * @param membershipRequestId the primary key of the membership request
067            * @return the membership request that was removed
068            * @throws com.liferay.portal.NoSuchMembershipRequestException if a membership request with the primary key could not be found
069            * @throws SystemException if a system exception occurred
070            */
071            public com.liferay.portal.model.MembershipRequest remove(
072                    long membershipRequestId)
073                    throws com.liferay.portal.NoSuchMembershipRequestException,
074                            com.liferay.portal.kernel.exception.SystemException;
075    
076            public com.liferay.portal.model.MembershipRequest updateImpl(
077                    com.liferay.portal.model.MembershipRequest membershipRequest,
078                    boolean merge)
079                    throws com.liferay.portal.kernel.exception.SystemException;
080    
081            /**
082            * Returns the membership request with the primary key or throws a {@link com.liferay.portal.NoSuchMembershipRequestException} if it could not be found.
083            *
084            * @param membershipRequestId the primary key of the membership request
085            * @return the membership request
086            * @throws com.liferay.portal.NoSuchMembershipRequestException if a membership request with the primary key could not be found
087            * @throws SystemException if a system exception occurred
088            */
089            public com.liferay.portal.model.MembershipRequest findByPrimaryKey(
090                    long membershipRequestId)
091                    throws com.liferay.portal.NoSuchMembershipRequestException,
092                            com.liferay.portal.kernel.exception.SystemException;
093    
094            /**
095            * Returns the membership request with the primary key or returns <code>null</code> if it could not be found.
096            *
097            * @param membershipRequestId the primary key of the membership request
098            * @return the membership request, or <code>null</code> if a membership request with the primary key could not be found
099            * @throws SystemException if a system exception occurred
100            */
101            public com.liferay.portal.model.MembershipRequest fetchByPrimaryKey(
102                    long membershipRequestId)
103                    throws com.liferay.portal.kernel.exception.SystemException;
104    
105            /**
106            * Returns all the membership requests where groupId = &#63;.
107            *
108            * @param groupId the group ID
109            * @return the matching membership requests
110            * @throws SystemException if a system exception occurred
111            */
112            public java.util.List<com.liferay.portal.model.MembershipRequest> findByGroupId(
113                    long groupId)
114                    throws com.liferay.portal.kernel.exception.SystemException;
115    
116            /**
117            * Returns a range of all the membership requests where groupId = &#63;.
118            *
119            * <p>
120            * 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.
121            * </p>
122            *
123            * @param groupId the group ID
124            * @param start the lower bound of the range of membership requests
125            * @param end the upper bound of the range of membership requests (not inclusive)
126            * @return the range of matching membership requests
127            * @throws SystemException if a system exception occurred
128            */
129            public java.util.List<com.liferay.portal.model.MembershipRequest> findByGroupId(
130                    long groupId, int start, int end)
131                    throws com.liferay.portal.kernel.exception.SystemException;
132    
133            /**
134            * Returns an ordered range of all the membership requests where groupId = &#63;.
135            *
136            * <p>
137            * 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.
138            * </p>
139            *
140            * @param groupId the group ID
141            * @param start the lower bound of the range of membership requests
142            * @param end the upper bound of the range of membership requests (not inclusive)
143            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
144            * @return the ordered range of matching membership requests
145            * @throws SystemException if a system exception occurred
146            */
147            public java.util.List<com.liferay.portal.model.MembershipRequest> findByGroupId(
148                    long groupId, int start, int end,
149                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
150                    throws com.liferay.portal.kernel.exception.SystemException;
151    
152            /**
153            * Returns the first membership request in the ordered set where groupId = &#63;.
154            *
155            * <p>
156            * 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.
157            * </p>
158            *
159            * @param groupId the group ID
160            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
161            * @return the first matching membership request
162            * @throws com.liferay.portal.NoSuchMembershipRequestException if a matching membership request could not be found
163            * @throws SystemException if a system exception occurred
164            */
165            public com.liferay.portal.model.MembershipRequest findByGroupId_First(
166                    long groupId,
167                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
168                    throws com.liferay.portal.NoSuchMembershipRequestException,
169                            com.liferay.portal.kernel.exception.SystemException;
170    
171            /**
172            * Returns the last membership request in the ordered set where groupId = &#63;.
173            *
174            * <p>
175            * 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.
176            * </p>
177            *
178            * @param groupId the group ID
179            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
180            * @return the last matching membership request
181            * @throws com.liferay.portal.NoSuchMembershipRequestException if a matching membership request could not be found
182            * @throws SystemException if a system exception occurred
183            */
184            public com.liferay.portal.model.MembershipRequest findByGroupId_Last(
185                    long groupId,
186                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
187                    throws com.liferay.portal.NoSuchMembershipRequestException,
188                            com.liferay.portal.kernel.exception.SystemException;
189    
190            /**
191            * Returns the membership requests before and after the current membership request in the ordered set where groupId = &#63;.
192            *
193            * <p>
194            * 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.
195            * </p>
196            *
197            * @param membershipRequestId the primary key of the current membership request
198            * @param groupId the group ID
199            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
200            * @return the previous, current, and next membership request
201            * @throws com.liferay.portal.NoSuchMembershipRequestException if a membership request with the primary key could not be found
202            * @throws SystemException if a system exception occurred
203            */
204            public com.liferay.portal.model.MembershipRequest[] findByGroupId_PrevAndNext(
205                    long membershipRequestId, long groupId,
206                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
207                    throws com.liferay.portal.NoSuchMembershipRequestException,
208                            com.liferay.portal.kernel.exception.SystemException;
209    
210            /**
211            * Returns all the membership requests where userId = &#63;.
212            *
213            * @param userId the user ID
214            * @return the matching membership requests
215            * @throws SystemException if a system exception occurred
216            */
217            public java.util.List<com.liferay.portal.model.MembershipRequest> findByUserId(
218                    long userId) throws com.liferay.portal.kernel.exception.SystemException;
219    
220            /**
221            * Returns a range of all the membership requests where userId = &#63;.
222            *
223            * <p>
224            * 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.
225            * </p>
226            *
227            * @param userId the user ID
228            * @param start the lower bound of the range of membership requests
229            * @param end the upper bound of the range of membership requests (not inclusive)
230            * @return the range of matching membership requests
231            * @throws SystemException if a system exception occurred
232            */
233            public java.util.List<com.liferay.portal.model.MembershipRequest> findByUserId(
234                    long userId, int start, int end)
235                    throws com.liferay.portal.kernel.exception.SystemException;
236    
237            /**
238            * Returns an ordered range of all the membership requests where userId = &#63;.
239            *
240            * <p>
241            * 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.
242            * </p>
243            *
244            * @param userId the user ID
245            * @param start the lower bound of the range of membership requests
246            * @param end the upper bound of the range of membership requests (not inclusive)
247            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
248            * @return the ordered range of matching membership requests
249            * @throws SystemException if a system exception occurred
250            */
251            public java.util.List<com.liferay.portal.model.MembershipRequest> findByUserId(
252                    long userId, int start, int end,
253                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
254                    throws com.liferay.portal.kernel.exception.SystemException;
255    
256            /**
257            * Returns the first membership request in the ordered set where 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 userId the user ID
264            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
265            * @return the first matching membership request
266            * @throws com.liferay.portal.NoSuchMembershipRequestException if a matching membership request could not be found
267            * @throws SystemException if a system exception occurred
268            */
269            public com.liferay.portal.model.MembershipRequest findByUserId_First(
270                    long userId,
271                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
272                    throws com.liferay.portal.NoSuchMembershipRequestException,
273                            com.liferay.portal.kernel.exception.SystemException;
274    
275            /**
276            * Returns the last membership request in the ordered set where userId = &#63;.
277            *
278            * <p>
279            * 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.
280            * </p>
281            *
282            * @param userId the user ID
283            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
284            * @return the last matching membership request
285            * @throws com.liferay.portal.NoSuchMembershipRequestException if a matching membership request could not be found
286            * @throws SystemException if a system exception occurred
287            */
288            public com.liferay.portal.model.MembershipRequest findByUserId_Last(
289                    long userId,
290                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
291                    throws com.liferay.portal.NoSuchMembershipRequestException,
292                            com.liferay.portal.kernel.exception.SystemException;
293    
294            /**
295            * Returns the membership requests before and after the current membership request in the ordered set where userId = &#63;.
296            *
297            * <p>
298            * 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.
299            * </p>
300            *
301            * @param membershipRequestId the primary key of the current membership request
302            * @param userId the user ID
303            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
304            * @return the previous, current, and next membership request
305            * @throws com.liferay.portal.NoSuchMembershipRequestException if a membership request with the primary key could not be found
306            * @throws SystemException if a system exception occurred
307            */
308            public com.liferay.portal.model.MembershipRequest[] findByUserId_PrevAndNext(
309                    long membershipRequestId, long userId,
310                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
311                    throws com.liferay.portal.NoSuchMembershipRequestException,
312                            com.liferay.portal.kernel.exception.SystemException;
313    
314            /**
315            * Returns all the membership requests where groupId = &#63; and statusId = &#63;.
316            *
317            * @param groupId the group ID
318            * @param statusId the status ID
319            * @return the matching membership requests
320            * @throws SystemException if a system exception occurred
321            */
322            public java.util.List<com.liferay.portal.model.MembershipRequest> findByG_S(
323                    long groupId, int statusId)
324                    throws com.liferay.portal.kernel.exception.SystemException;
325    
326            /**
327            * Returns a range of all the membership requests where groupId = &#63; and statusId = &#63;.
328            *
329            * <p>
330            * 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.
331            * </p>
332            *
333            * @param groupId the group ID
334            * @param statusId the status ID
335            * @param start the lower bound of the range of membership requests
336            * @param end the upper bound of the range of membership requests (not inclusive)
337            * @return the range of matching membership requests
338            * @throws SystemException if a system exception occurred
339            */
340            public java.util.List<com.liferay.portal.model.MembershipRequest> findByG_S(
341                    long groupId, int statusId, int start, int end)
342                    throws com.liferay.portal.kernel.exception.SystemException;
343    
344            /**
345            * Returns an ordered range of all the membership requests where groupId = &#63; and statusId = &#63;.
346            *
347            * <p>
348            * 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.
349            * </p>
350            *
351            * @param groupId the group ID
352            * @param statusId the status ID
353            * @param start the lower bound of the range of membership requests
354            * @param end the upper bound of the range of membership requests (not inclusive)
355            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
356            * @return the ordered range of matching membership requests
357            * @throws SystemException if a system exception occurred
358            */
359            public java.util.List<com.liferay.portal.model.MembershipRequest> findByG_S(
360                    long groupId, int statusId, int start, int end,
361                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
362                    throws com.liferay.portal.kernel.exception.SystemException;
363    
364            /**
365            * Returns the first membership request in the ordered set where groupId = &#63; and statusId = &#63;.
366            *
367            * <p>
368            * 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.
369            * </p>
370            *
371            * @param groupId the group ID
372            * @param statusId the status ID
373            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
374            * @return the first matching membership request
375            * @throws com.liferay.portal.NoSuchMembershipRequestException if a matching membership request could not be found
376            * @throws SystemException if a system exception occurred
377            */
378            public com.liferay.portal.model.MembershipRequest findByG_S_First(
379                    long groupId, int statusId,
380                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
381                    throws com.liferay.portal.NoSuchMembershipRequestException,
382                            com.liferay.portal.kernel.exception.SystemException;
383    
384            /**
385            * Returns the last membership request in the ordered set where groupId = &#63; and statusId = &#63;.
386            *
387            * <p>
388            * 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.
389            * </p>
390            *
391            * @param groupId the group ID
392            * @param statusId the status ID
393            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
394            * @return the last matching membership request
395            * @throws com.liferay.portal.NoSuchMembershipRequestException if a matching membership request could not be found
396            * @throws SystemException if a system exception occurred
397            */
398            public com.liferay.portal.model.MembershipRequest findByG_S_Last(
399                    long groupId, int statusId,
400                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
401                    throws com.liferay.portal.NoSuchMembershipRequestException,
402                            com.liferay.portal.kernel.exception.SystemException;
403    
404            /**
405            * Returns the membership requests before and after the current membership request in the ordered set where groupId = &#63; and statusId = &#63;.
406            *
407            * <p>
408            * 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.
409            * </p>
410            *
411            * @param membershipRequestId the primary key of the current membership request
412            * @param groupId the group ID
413            * @param statusId the status ID
414            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
415            * @return the previous, current, and next membership request
416            * @throws com.liferay.portal.NoSuchMembershipRequestException if a membership request with the primary key could not be found
417            * @throws SystemException if a system exception occurred
418            */
419            public com.liferay.portal.model.MembershipRequest[] findByG_S_PrevAndNext(
420                    long membershipRequestId, long groupId, int statusId,
421                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
422                    throws com.liferay.portal.NoSuchMembershipRequestException,
423                            com.liferay.portal.kernel.exception.SystemException;
424    
425            /**
426            * Returns all the membership requests where groupId = &#63; and userId = &#63; and statusId = &#63;.
427            *
428            * @param groupId the group ID
429            * @param userId the user ID
430            * @param statusId the status ID
431            * @return the matching membership requests
432            * @throws SystemException if a system exception occurred
433            */
434            public java.util.List<com.liferay.portal.model.MembershipRequest> findByG_U_S(
435                    long groupId, long userId, int statusId)
436                    throws com.liferay.portal.kernel.exception.SystemException;
437    
438            /**
439            * Returns a range of all the membership requests where groupId = &#63; and userId = &#63; and statusId = &#63;.
440            *
441            * <p>
442            * 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.
443            * </p>
444            *
445            * @param groupId the group ID
446            * @param userId the user ID
447            * @param statusId the status ID
448            * @param start the lower bound of the range of membership requests
449            * @param end the upper bound of the range of membership requests (not inclusive)
450            * @return the range of matching membership requests
451            * @throws SystemException if a system exception occurred
452            */
453            public java.util.List<com.liferay.portal.model.MembershipRequest> findByG_U_S(
454                    long groupId, long userId, int statusId, int start, int end)
455                    throws com.liferay.portal.kernel.exception.SystemException;
456    
457            /**
458            * Returns an ordered range of all the membership requests where groupId = &#63; and userId = &#63; and statusId = &#63;.
459            *
460            * <p>
461            * 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.
462            * </p>
463            *
464            * @param groupId the group ID
465            * @param userId the user ID
466            * @param statusId the status ID
467            * @param start the lower bound of the range of membership requests
468            * @param end the upper bound of the range of membership requests (not inclusive)
469            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
470            * @return the ordered range of matching membership requests
471            * @throws SystemException if a system exception occurred
472            */
473            public java.util.List<com.liferay.portal.model.MembershipRequest> findByG_U_S(
474                    long groupId, long userId, int statusId, int start, int end,
475                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
476                    throws com.liferay.portal.kernel.exception.SystemException;
477    
478            /**
479            * Returns the first membership request in the ordered set where groupId = &#63; and userId = &#63; and statusId = &#63;.
480            *
481            * <p>
482            * 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.
483            * </p>
484            *
485            * @param groupId the group ID
486            * @param userId the user ID
487            * @param statusId the status ID
488            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
489            * @return the first matching membership request
490            * @throws com.liferay.portal.NoSuchMembershipRequestException if a matching membership request could not be found
491            * @throws SystemException if a system exception occurred
492            */
493            public com.liferay.portal.model.MembershipRequest findByG_U_S_First(
494                    long groupId, long userId, int statusId,
495                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
496                    throws com.liferay.portal.NoSuchMembershipRequestException,
497                            com.liferay.portal.kernel.exception.SystemException;
498    
499            /**
500            * Returns the last membership request in the ordered set where groupId = &#63; and userId = &#63; and statusId = &#63;.
501            *
502            * <p>
503            * 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.
504            * </p>
505            *
506            * @param groupId the group ID
507            * @param userId the user ID
508            * @param statusId the status ID
509            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
510            * @return the last matching membership request
511            * @throws com.liferay.portal.NoSuchMembershipRequestException if a matching membership request could not be found
512            * @throws SystemException if a system exception occurred
513            */
514            public com.liferay.portal.model.MembershipRequest findByG_U_S_Last(
515                    long groupId, long userId, int statusId,
516                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
517                    throws com.liferay.portal.NoSuchMembershipRequestException,
518                            com.liferay.portal.kernel.exception.SystemException;
519    
520            /**
521            * Returns the membership requests before and after the current membership request in the ordered set where groupId = &#63; and userId = &#63; and statusId = &#63;.
522            *
523            * <p>
524            * 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.
525            * </p>
526            *
527            * @param membershipRequestId the primary key of the current membership request
528            * @param groupId the group ID
529            * @param userId the user ID
530            * @param statusId the status ID
531            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
532            * @return the previous, current, and next membership request
533            * @throws com.liferay.portal.NoSuchMembershipRequestException if a membership request with the primary key could not be found
534            * @throws SystemException if a system exception occurred
535            */
536            public com.liferay.portal.model.MembershipRequest[] findByG_U_S_PrevAndNext(
537                    long membershipRequestId, long groupId, long userId, int statusId,
538                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
539                    throws com.liferay.portal.NoSuchMembershipRequestException,
540                            com.liferay.portal.kernel.exception.SystemException;
541    
542            /**
543            * Returns all the membership requests.
544            *
545            * @return the membership requests
546            * @throws SystemException if a system exception occurred
547            */
548            public java.util.List<com.liferay.portal.model.MembershipRequest> findAll()
549                    throws com.liferay.portal.kernel.exception.SystemException;
550    
551            /**
552            * Returns a range of all the membership requests.
553            *
554            * <p>
555            * 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.
556            * </p>
557            *
558            * @param start the lower bound of the range of membership requests
559            * @param end the upper bound of the range of membership requests (not inclusive)
560            * @return the range of membership requests
561            * @throws SystemException if a system exception occurred
562            */
563            public java.util.List<com.liferay.portal.model.MembershipRequest> findAll(
564                    int start, int end)
565                    throws com.liferay.portal.kernel.exception.SystemException;
566    
567            /**
568            * Returns an ordered range of all the membership requests.
569            *
570            * <p>
571            * 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.
572            * </p>
573            *
574            * @param start the lower bound of the range of membership requests
575            * @param end the upper bound of the range of membership requests (not inclusive)
576            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
577            * @return the ordered range of membership requests
578            * @throws SystemException if a system exception occurred
579            */
580            public java.util.List<com.liferay.portal.model.MembershipRequest> findAll(
581                    int start, int end,
582                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
583                    throws com.liferay.portal.kernel.exception.SystemException;
584    
585            /**
586            * Removes all the membership requests where groupId = &#63; from the database.
587            *
588            * @param groupId the group ID
589            * @throws SystemException if a system exception occurred
590            */
591            public void removeByGroupId(long groupId)
592                    throws com.liferay.portal.kernel.exception.SystemException;
593    
594            /**
595            * Removes all the membership requests where userId = &#63; from the database.
596            *
597            * @param userId the user ID
598            * @throws SystemException if a system exception occurred
599            */
600            public void removeByUserId(long userId)
601                    throws com.liferay.portal.kernel.exception.SystemException;
602    
603            /**
604            * Removes all the membership requests where groupId = &#63; and statusId = &#63; from the database.
605            *
606            * @param groupId the group ID
607            * @param statusId the status ID
608            * @throws SystemException if a system exception occurred
609            */
610            public void removeByG_S(long groupId, int statusId)
611                    throws com.liferay.portal.kernel.exception.SystemException;
612    
613            /**
614            * Removes all the membership requests where groupId = &#63; and userId = &#63; and statusId = &#63; from the database.
615            *
616            * @param groupId the group ID
617            * @param userId the user ID
618            * @param statusId the status ID
619            * @throws SystemException if a system exception occurred
620            */
621            public void removeByG_U_S(long groupId, long userId, int statusId)
622                    throws com.liferay.portal.kernel.exception.SystemException;
623    
624            /**
625            * Removes all the membership requests from the database.
626            *
627            * @throws SystemException if a system exception occurred
628            */
629            public void removeAll()
630                    throws com.liferay.portal.kernel.exception.SystemException;
631    
632            /**
633            * Returns the number of membership requests where groupId = &#63;.
634            *
635            * @param groupId the group ID
636            * @return the number of matching membership requests
637            * @throws SystemException if a system exception occurred
638            */
639            public int countByGroupId(long groupId)
640                    throws com.liferay.portal.kernel.exception.SystemException;
641    
642            /**
643            * Returns the number of membership requests where userId = &#63;.
644            *
645            * @param userId the user ID
646            * @return the number of matching membership requests
647            * @throws SystemException if a system exception occurred
648            */
649            public int countByUserId(long userId)
650                    throws com.liferay.portal.kernel.exception.SystemException;
651    
652            /**
653            * Returns the number of membership requests where groupId = &#63; and statusId = &#63;.
654            *
655            * @param groupId the group ID
656            * @param statusId the status ID
657            * @return the number of matching membership requests
658            * @throws SystemException if a system exception occurred
659            */
660            public int countByG_S(long groupId, int statusId)
661                    throws com.liferay.portal.kernel.exception.SystemException;
662    
663            /**
664            * Returns the number of membership requests where groupId = &#63; and userId = &#63; and statusId = &#63;.
665            *
666            * @param groupId the group ID
667            * @param userId the user ID
668            * @param statusId the status ID
669            * @return the number of matching membership requests
670            * @throws SystemException if a system exception occurred
671            */
672            public int countByG_U_S(long groupId, long userId, int statusId)
673                    throws com.liferay.portal.kernel.exception.SystemException;
674    
675            /**
676            * Returns the number of membership requests.
677            *
678            * @return the number of membership requests
679            * @throws SystemException if a system exception occurred
680            */
681            public int countAll()
682                    throws com.liferay.portal.kernel.exception.SystemException;
683    }