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                    throws com.liferay.portal.kernel.exception.SystemException;
079    
080            /**
081            * Returns the membership request with the primary key or throws a {@link com.liferay.portal.NoSuchMembershipRequestException} if it could not be found.
082            *
083            * @param membershipRequestId the primary key of the membership request
084            * @return the membership request
085            * @throws com.liferay.portal.NoSuchMembershipRequestException if a membership request with the primary key could not be found
086            * @throws SystemException if a system exception occurred
087            */
088            public com.liferay.portal.model.MembershipRequest findByPrimaryKey(
089                    long membershipRequestId)
090                    throws com.liferay.portal.NoSuchMembershipRequestException,
091                            com.liferay.portal.kernel.exception.SystemException;
092    
093            /**
094            * Returns the membership request with the primary key or returns <code>null</code> if it could not be found.
095            *
096            * @param membershipRequestId the primary key of the membership request
097            * @return the membership request, or <code>null</code> if a membership request with the primary key could not be found
098            * @throws SystemException if a system exception occurred
099            */
100            public com.liferay.portal.model.MembershipRequest fetchByPrimaryKey(
101                    long membershipRequestId)
102                    throws com.liferay.portal.kernel.exception.SystemException;
103    
104            /**
105            * Returns all the membership requests where groupId = &#63;.
106            *
107            * @param groupId the group ID
108            * @return the matching membership requests
109            * @throws SystemException if a system exception occurred
110            */
111            public java.util.List<com.liferay.portal.model.MembershipRequest> findByGroupId(
112                    long groupId)
113                    throws com.liferay.portal.kernel.exception.SystemException;
114    
115            /**
116            * Returns a range of all the membership requests where groupId = &#63;.
117            *
118            * <p>
119            * 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.
120            * </p>
121            *
122            * @param groupId the group ID
123            * @param start the lower bound of the range of membership requests
124            * @param end the upper bound of the range of membership requests (not inclusive)
125            * @return the range of matching membership requests
126            * @throws SystemException if a system exception occurred
127            */
128            public java.util.List<com.liferay.portal.model.MembershipRequest> findByGroupId(
129                    long groupId, int start, int end)
130                    throws com.liferay.portal.kernel.exception.SystemException;
131    
132            /**
133            * Returns an ordered range of all the membership requests where groupId = &#63;.
134            *
135            * <p>
136            * 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.
137            * </p>
138            *
139            * @param groupId the group ID
140            * @param start the lower bound of the range of membership requests
141            * @param end the upper bound of the range of membership requests (not inclusive)
142            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
143            * @return the ordered range of matching membership requests
144            * @throws SystemException if a system exception occurred
145            */
146            public java.util.List<com.liferay.portal.model.MembershipRequest> findByGroupId(
147                    long groupId, int start, int end,
148                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
149                    throws com.liferay.portal.kernel.exception.SystemException;
150    
151            /**
152            * Returns the first membership request in the ordered set where groupId = &#63;.
153            *
154            * @param groupId the group ID
155            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
156            * @return the first matching membership request
157            * @throws com.liferay.portal.NoSuchMembershipRequestException if a matching membership request could not be found
158            * @throws SystemException if a system exception occurred
159            */
160            public com.liferay.portal.model.MembershipRequest findByGroupId_First(
161                    long groupId,
162                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
163                    throws com.liferay.portal.NoSuchMembershipRequestException,
164                            com.liferay.portal.kernel.exception.SystemException;
165    
166            /**
167            * Returns the first membership request in the ordered set where groupId = &#63;.
168            *
169            * @param groupId the group ID
170            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
171            * @return the first matching membership request, or <code>null</code> if a matching membership request could not be found
172            * @throws SystemException if a system exception occurred
173            */
174            public com.liferay.portal.model.MembershipRequest fetchByGroupId_First(
175                    long groupId,
176                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
177                    throws com.liferay.portal.kernel.exception.SystemException;
178    
179            /**
180            * Returns the last membership request in the ordered set where groupId = &#63;.
181            *
182            * @param groupId the group ID
183            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
184            * @return the last matching membership request
185            * @throws com.liferay.portal.NoSuchMembershipRequestException if a matching membership request could not be found
186            * @throws SystemException if a system exception occurred
187            */
188            public com.liferay.portal.model.MembershipRequest findByGroupId_Last(
189                    long groupId,
190                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
191                    throws com.liferay.portal.NoSuchMembershipRequestException,
192                            com.liferay.portal.kernel.exception.SystemException;
193    
194            /**
195            * Returns the last membership request in the ordered set where groupId = &#63;.
196            *
197            * @param groupId the group ID
198            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
199            * @return the last matching membership request, or <code>null</code> if a matching membership request could not be found
200            * @throws SystemException if a system exception occurred
201            */
202            public com.liferay.portal.model.MembershipRequest fetchByGroupId_Last(
203                    long groupId,
204                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
205                    throws com.liferay.portal.kernel.exception.SystemException;
206    
207            /**
208            * Returns the membership requests before and after the current membership request in the ordered set where groupId = &#63;.
209            *
210            * @param membershipRequestId the primary key of the current membership request
211            * @param groupId the group ID
212            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
213            * @return the previous, current, and next membership request
214            * @throws com.liferay.portal.NoSuchMembershipRequestException if a membership request with the primary key could not be found
215            * @throws SystemException if a system exception occurred
216            */
217            public com.liferay.portal.model.MembershipRequest[] findByGroupId_PrevAndNext(
218                    long membershipRequestId, long groupId,
219                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
220                    throws com.liferay.portal.NoSuchMembershipRequestException,
221                            com.liferay.portal.kernel.exception.SystemException;
222    
223            /**
224            * Returns all the membership requests where userId = &#63;.
225            *
226            * @param userId the user ID
227            * @return the matching membership requests
228            * @throws SystemException if a system exception occurred
229            */
230            public java.util.List<com.liferay.portal.model.MembershipRequest> findByUserId(
231                    long userId) throws com.liferay.portal.kernel.exception.SystemException;
232    
233            /**
234            * Returns a range of all the membership requests where userId = &#63;.
235            *
236            * <p>
237            * 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.
238            * </p>
239            *
240            * @param userId the user ID
241            * @param start the lower bound of the range of membership requests
242            * @param end the upper bound of the range of membership requests (not inclusive)
243            * @return the range of matching membership requests
244            * @throws SystemException if a system exception occurred
245            */
246            public java.util.List<com.liferay.portal.model.MembershipRequest> findByUserId(
247                    long userId, int start, int end)
248                    throws com.liferay.portal.kernel.exception.SystemException;
249    
250            /**
251            * Returns an ordered range of all the membership requests where userId = &#63;.
252            *
253            * <p>
254            * 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.
255            * </p>
256            *
257            * @param userId the user ID
258            * @param start the lower bound of the range of membership requests
259            * @param end the upper bound of the range of membership requests (not inclusive)
260            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
261            * @return the ordered range of matching membership requests
262            * @throws SystemException if a system exception occurred
263            */
264            public java.util.List<com.liferay.portal.model.MembershipRequest> findByUserId(
265                    long userId, int start, int end,
266                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
267                    throws com.liferay.portal.kernel.exception.SystemException;
268    
269            /**
270            * Returns the first membership request in the ordered set where userId = &#63;.
271            *
272            * @param userId the user ID
273            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
274            * @return the first matching membership request
275            * @throws com.liferay.portal.NoSuchMembershipRequestException if a matching membership request could not be found
276            * @throws SystemException if a system exception occurred
277            */
278            public com.liferay.portal.model.MembershipRequest findByUserId_First(
279                    long userId,
280                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
281                    throws com.liferay.portal.NoSuchMembershipRequestException,
282                            com.liferay.portal.kernel.exception.SystemException;
283    
284            /**
285            * Returns the first membership request in the ordered set where userId = &#63;.
286            *
287            * @param userId the user ID
288            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
289            * @return the first matching membership request, or <code>null</code> if a matching membership request could not be found
290            * @throws SystemException if a system exception occurred
291            */
292            public com.liferay.portal.model.MembershipRequest fetchByUserId_First(
293                    long userId,
294                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
295                    throws com.liferay.portal.kernel.exception.SystemException;
296    
297            /**
298            * Returns the last membership request in the ordered set where userId = &#63;.
299            *
300            * @param userId the user ID
301            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
302            * @return the last matching membership request
303            * @throws com.liferay.portal.NoSuchMembershipRequestException if a matching membership request could not be found
304            * @throws SystemException if a system exception occurred
305            */
306            public com.liferay.portal.model.MembershipRequest findByUserId_Last(
307                    long userId,
308                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
309                    throws com.liferay.portal.NoSuchMembershipRequestException,
310                            com.liferay.portal.kernel.exception.SystemException;
311    
312            /**
313            * Returns the last membership request in the ordered set where userId = &#63;.
314            *
315            * @param userId the user ID
316            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
317            * @return the last matching membership request, or <code>null</code> if a matching membership request could not be found
318            * @throws SystemException if a system exception occurred
319            */
320            public com.liferay.portal.model.MembershipRequest fetchByUserId_Last(
321                    long userId,
322                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
323                    throws com.liferay.portal.kernel.exception.SystemException;
324    
325            /**
326            * Returns the membership requests before and after the current membership request in the ordered set where userId = &#63;.
327            *
328            * @param membershipRequestId the primary key of the current membership request
329            * @param userId the user ID
330            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
331            * @return the previous, current, and next membership request
332            * @throws com.liferay.portal.NoSuchMembershipRequestException if a membership request with the primary key could not be found
333            * @throws SystemException if a system exception occurred
334            */
335            public com.liferay.portal.model.MembershipRequest[] findByUserId_PrevAndNext(
336                    long membershipRequestId, long userId,
337                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
338                    throws com.liferay.portal.NoSuchMembershipRequestException,
339                            com.liferay.portal.kernel.exception.SystemException;
340    
341            /**
342            * Returns all the membership requests where groupId = &#63; and statusId = &#63;.
343            *
344            * @param groupId the group ID
345            * @param statusId the status ID
346            * @return the matching membership requests
347            * @throws SystemException if a system exception occurred
348            */
349            public java.util.List<com.liferay.portal.model.MembershipRequest> findByG_S(
350                    long groupId, int statusId)
351                    throws com.liferay.portal.kernel.exception.SystemException;
352    
353            /**
354            * Returns a range of all the membership requests where groupId = &#63; and statusId = &#63;.
355            *
356            * <p>
357            * 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.
358            * </p>
359            *
360            * @param groupId the group ID
361            * @param statusId the status ID
362            * @param start the lower bound of the range of membership requests
363            * @param end the upper bound of the range of membership requests (not inclusive)
364            * @return the range of matching membership requests
365            * @throws SystemException if a system exception occurred
366            */
367            public java.util.List<com.liferay.portal.model.MembershipRequest> findByG_S(
368                    long groupId, int statusId, int start, int end)
369                    throws com.liferay.portal.kernel.exception.SystemException;
370    
371            /**
372            * Returns an ordered range of all the membership requests where groupId = &#63; and statusId = &#63;.
373            *
374            * <p>
375            * 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.
376            * </p>
377            *
378            * @param groupId the group ID
379            * @param statusId the status ID
380            * @param start the lower bound of the range of membership requests
381            * @param end the upper bound of the range of membership requests (not inclusive)
382            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
383            * @return the ordered range of matching membership requests
384            * @throws SystemException if a system exception occurred
385            */
386            public java.util.List<com.liferay.portal.model.MembershipRequest> findByG_S(
387                    long groupId, int statusId, int start, int end,
388                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
389                    throws com.liferay.portal.kernel.exception.SystemException;
390    
391            /**
392            * Returns the first membership request in the ordered set where groupId = &#63; and statusId = &#63;.
393            *
394            * @param groupId the group ID
395            * @param statusId the status ID
396            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
397            * @return the first matching membership request
398            * @throws com.liferay.portal.NoSuchMembershipRequestException if a matching membership request could not be found
399            * @throws SystemException if a system exception occurred
400            */
401            public com.liferay.portal.model.MembershipRequest findByG_S_First(
402                    long groupId, int statusId,
403                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
404                    throws com.liferay.portal.NoSuchMembershipRequestException,
405                            com.liferay.portal.kernel.exception.SystemException;
406    
407            /**
408            * Returns the first membership request in the ordered set where groupId = &#63; and statusId = &#63;.
409            *
410            * @param groupId the group ID
411            * @param statusId the status ID
412            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
413            * @return the first matching membership request, or <code>null</code> if a matching membership request could not be found
414            * @throws SystemException if a system exception occurred
415            */
416            public com.liferay.portal.model.MembershipRequest fetchByG_S_First(
417                    long groupId, int statusId,
418                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
419                    throws com.liferay.portal.kernel.exception.SystemException;
420    
421            /**
422            * Returns the last membership request in the ordered set where groupId = &#63; and statusId = &#63;.
423            *
424            * @param groupId the group ID
425            * @param statusId the status ID
426            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
427            * @return the last matching membership request
428            * @throws com.liferay.portal.NoSuchMembershipRequestException if a matching membership request could not be found
429            * @throws SystemException if a system exception occurred
430            */
431            public com.liferay.portal.model.MembershipRequest findByG_S_Last(
432                    long groupId, int statusId,
433                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
434                    throws com.liferay.portal.NoSuchMembershipRequestException,
435                            com.liferay.portal.kernel.exception.SystemException;
436    
437            /**
438            * Returns the last membership request in the ordered set where groupId = &#63; and statusId = &#63;.
439            *
440            * @param groupId the group ID
441            * @param statusId the status ID
442            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
443            * @return the last matching membership request, or <code>null</code> if a matching membership request could not be found
444            * @throws SystemException if a system exception occurred
445            */
446            public com.liferay.portal.model.MembershipRequest fetchByG_S_Last(
447                    long groupId, int statusId,
448                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
449                    throws com.liferay.portal.kernel.exception.SystemException;
450    
451            /**
452            * Returns the membership requests before and after the current membership request in the ordered set where groupId = &#63; and statusId = &#63;.
453            *
454            * @param membershipRequestId the primary key of the current membership request
455            * @param groupId the group ID
456            * @param statusId the status ID
457            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
458            * @return the previous, current, and next membership request
459            * @throws com.liferay.portal.NoSuchMembershipRequestException if a membership request with the primary key could not be found
460            * @throws SystemException if a system exception occurred
461            */
462            public com.liferay.portal.model.MembershipRequest[] findByG_S_PrevAndNext(
463                    long membershipRequestId, long groupId, int statusId,
464                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
465                    throws com.liferay.portal.NoSuchMembershipRequestException,
466                            com.liferay.portal.kernel.exception.SystemException;
467    
468            /**
469            * Returns all the membership requests where groupId = &#63; and userId = &#63; and statusId = &#63;.
470            *
471            * @param groupId the group ID
472            * @param userId the user ID
473            * @param statusId the status ID
474            * @return the matching membership requests
475            * @throws SystemException if a system exception occurred
476            */
477            public java.util.List<com.liferay.portal.model.MembershipRequest> findByG_U_S(
478                    long groupId, long userId, int statusId)
479                    throws com.liferay.portal.kernel.exception.SystemException;
480    
481            /**
482            * Returns a range of all the membership requests where groupId = &#63; and userId = &#63; and statusId = &#63;.
483            *
484            * <p>
485            * 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.
486            * </p>
487            *
488            * @param groupId the group ID
489            * @param userId the user ID
490            * @param statusId the status ID
491            * @param start the lower bound of the range of membership requests
492            * @param end the upper bound of the range of membership requests (not inclusive)
493            * @return the range of matching membership requests
494            * @throws SystemException if a system exception occurred
495            */
496            public java.util.List<com.liferay.portal.model.MembershipRequest> findByG_U_S(
497                    long groupId, long userId, int statusId, int start, int end)
498                    throws com.liferay.portal.kernel.exception.SystemException;
499    
500            /**
501            * Returns an ordered range of all the membership requests where groupId = &#63; and userId = &#63; and statusId = &#63;.
502            *
503            * <p>
504            * 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.
505            * </p>
506            *
507            * @param groupId the group ID
508            * @param userId the user ID
509            * @param statusId the status ID
510            * @param start the lower bound of the range of membership requests
511            * @param end the upper bound of the range of membership requests (not inclusive)
512            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
513            * @return the ordered range of matching membership requests
514            * @throws SystemException if a system exception occurred
515            */
516            public java.util.List<com.liferay.portal.model.MembershipRequest> findByG_U_S(
517                    long groupId, long userId, int statusId, int start, int end,
518                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
519                    throws com.liferay.portal.kernel.exception.SystemException;
520    
521            /**
522            * Returns the first membership request in the ordered set where groupId = &#63; and userId = &#63; and statusId = &#63;.
523            *
524            * @param groupId the group ID
525            * @param userId the user ID
526            * @param statusId the status ID
527            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
528            * @return the first matching membership request
529            * @throws com.liferay.portal.NoSuchMembershipRequestException if a matching membership request could not be found
530            * @throws SystemException if a system exception occurred
531            */
532            public com.liferay.portal.model.MembershipRequest findByG_U_S_First(
533                    long groupId, long userId, int statusId,
534                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
535                    throws com.liferay.portal.NoSuchMembershipRequestException,
536                            com.liferay.portal.kernel.exception.SystemException;
537    
538            /**
539            * Returns the first membership request in the ordered set where groupId = &#63; and userId = &#63; and statusId = &#63;.
540            *
541            * @param groupId the group ID
542            * @param userId the user ID
543            * @param statusId the status ID
544            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
545            * @return the first matching membership request, or <code>null</code> if a matching membership request could not be found
546            * @throws SystemException if a system exception occurred
547            */
548            public com.liferay.portal.model.MembershipRequest fetchByG_U_S_First(
549                    long groupId, long userId, int statusId,
550                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
551                    throws com.liferay.portal.kernel.exception.SystemException;
552    
553            /**
554            * Returns the last membership request in the ordered set where groupId = &#63; and userId = &#63; and statusId = &#63;.
555            *
556            * @param groupId the group ID
557            * @param userId the user ID
558            * @param statusId the status ID
559            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
560            * @return the last matching membership request
561            * @throws com.liferay.portal.NoSuchMembershipRequestException if a matching membership request could not be found
562            * @throws SystemException if a system exception occurred
563            */
564            public com.liferay.portal.model.MembershipRequest findByG_U_S_Last(
565                    long groupId, long userId, int statusId,
566                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
567                    throws com.liferay.portal.NoSuchMembershipRequestException,
568                            com.liferay.portal.kernel.exception.SystemException;
569    
570            /**
571            * Returns the last membership request in the ordered set where groupId = &#63; and userId = &#63; and statusId = &#63;.
572            *
573            * @param groupId the group ID
574            * @param userId the user ID
575            * @param statusId the status ID
576            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
577            * @return the last matching membership request, or <code>null</code> if a matching membership request could not be found
578            * @throws SystemException if a system exception occurred
579            */
580            public com.liferay.portal.model.MembershipRequest fetchByG_U_S_Last(
581                    long groupId, long userId, int statusId,
582                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
583                    throws com.liferay.portal.kernel.exception.SystemException;
584    
585            /**
586            * Returns the membership requests before and after the current membership request in the ordered set where groupId = &#63; and userId = &#63; and statusId = &#63;.
587            *
588            * @param membershipRequestId the primary key of the current membership request
589            * @param groupId the group ID
590            * @param userId the user ID
591            * @param statusId the status ID
592            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
593            * @return the previous, current, and next membership request
594            * @throws com.liferay.portal.NoSuchMembershipRequestException if a membership request with the primary key could not be found
595            * @throws SystemException if a system exception occurred
596            */
597            public com.liferay.portal.model.MembershipRequest[] findByG_U_S_PrevAndNext(
598                    long membershipRequestId, long groupId, long userId, int statusId,
599                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
600                    throws com.liferay.portal.NoSuchMembershipRequestException,
601                            com.liferay.portal.kernel.exception.SystemException;
602    
603            /**
604            * Returns all the membership requests.
605            *
606            * @return the membership requests
607            * @throws SystemException if a system exception occurred
608            */
609            public java.util.List<com.liferay.portal.model.MembershipRequest> findAll()
610                    throws com.liferay.portal.kernel.exception.SystemException;
611    
612            /**
613            * Returns a range of all the membership requests.
614            *
615            * <p>
616            * 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.
617            * </p>
618            *
619            * @param start the lower bound of the range of membership requests
620            * @param end the upper bound of the range of membership requests (not inclusive)
621            * @return the range of membership requests
622            * @throws SystemException if a system exception occurred
623            */
624            public java.util.List<com.liferay.portal.model.MembershipRequest> findAll(
625                    int start, int end)
626                    throws com.liferay.portal.kernel.exception.SystemException;
627    
628            /**
629            * Returns an ordered range of all the membership requests.
630            *
631            * <p>
632            * 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.
633            * </p>
634            *
635            * @param start the lower bound of the range of membership requests
636            * @param end the upper bound of the range of membership requests (not inclusive)
637            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
638            * @return the ordered range of membership requests
639            * @throws SystemException if a system exception occurred
640            */
641            public java.util.List<com.liferay.portal.model.MembershipRequest> findAll(
642                    int start, int end,
643                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
644                    throws com.liferay.portal.kernel.exception.SystemException;
645    
646            /**
647            * Removes all the membership requests where groupId = &#63; from the database.
648            *
649            * @param groupId the group ID
650            * @throws SystemException if a system exception occurred
651            */
652            public void removeByGroupId(long groupId)
653                    throws com.liferay.portal.kernel.exception.SystemException;
654    
655            /**
656            * Removes all the membership requests where userId = &#63; from the database.
657            *
658            * @param userId the user ID
659            * @throws SystemException if a system exception occurred
660            */
661            public void removeByUserId(long userId)
662                    throws com.liferay.portal.kernel.exception.SystemException;
663    
664            /**
665            * Removes all the membership requests where groupId = &#63; and statusId = &#63; from the database.
666            *
667            * @param groupId the group ID
668            * @param statusId the status ID
669            * @throws SystemException if a system exception occurred
670            */
671            public void removeByG_S(long groupId, int statusId)
672                    throws com.liferay.portal.kernel.exception.SystemException;
673    
674            /**
675            * Removes all the membership requests where groupId = &#63; and userId = &#63; and statusId = &#63; from the database.
676            *
677            * @param groupId the group ID
678            * @param userId the user ID
679            * @param statusId the status ID
680            * @throws SystemException if a system exception occurred
681            */
682            public void removeByG_U_S(long groupId, long userId, int statusId)
683                    throws com.liferay.portal.kernel.exception.SystemException;
684    
685            /**
686            * Removes all the membership requests from the database.
687            *
688            * @throws SystemException if a system exception occurred
689            */
690            public void removeAll()
691                    throws com.liferay.portal.kernel.exception.SystemException;
692    
693            /**
694            * Returns the number of membership requests where groupId = &#63;.
695            *
696            * @param groupId the group ID
697            * @return the number of matching membership requests
698            * @throws SystemException if a system exception occurred
699            */
700            public int countByGroupId(long groupId)
701                    throws com.liferay.portal.kernel.exception.SystemException;
702    
703            /**
704            * Returns the number of membership requests where userId = &#63;.
705            *
706            * @param userId the user ID
707            * @return the number of matching membership requests
708            * @throws SystemException if a system exception occurred
709            */
710            public int countByUserId(long userId)
711                    throws com.liferay.portal.kernel.exception.SystemException;
712    
713            /**
714            * Returns the number of membership requests where groupId = &#63; and statusId = &#63;.
715            *
716            * @param groupId the group ID
717            * @param statusId the status ID
718            * @return the number of matching membership requests
719            * @throws SystemException if a system exception occurred
720            */
721            public int countByG_S(long groupId, int statusId)
722                    throws com.liferay.portal.kernel.exception.SystemException;
723    
724            /**
725            * Returns the number of membership requests where groupId = &#63; and userId = &#63; and statusId = &#63;.
726            *
727            * @param groupId the group ID
728            * @param userId the user ID
729            * @param statusId the status ID
730            * @return the number of matching membership requests
731            * @throws SystemException if a system exception occurred
732            */
733            public int countByG_U_S(long groupId, long userId, int statusId)
734                    throws com.liferay.portal.kernel.exception.SystemException;
735    
736            /**
737            * Returns the number of membership requests.
738            *
739            * @return the number of membership requests
740            * @throws SystemException if a system exception occurred
741            */
742            public int countAll()
743                    throws com.liferay.portal.kernel.exception.SystemException;
744    }