001    /**
002     * Copyright (c) 2000-present 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 aQute.bnd.annotation.ProviderType;
018    
019    import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
020    import com.liferay.portal.kernel.dao.orm.DynamicQuery;
021    import com.liferay.portal.kernel.util.OrderByComparator;
022    import com.liferay.portal.kernel.util.ReferenceRegistry;
023    import com.liferay.portal.model.MembershipRequest;
024    import com.liferay.portal.service.ServiceContext;
025    
026    import java.util.List;
027    
028    /**
029     * The persistence utility for the membership request service. This utility wraps {@link MembershipRequestPersistenceImpl} and provides direct access to the database for CRUD operations. This utility should only be used by the service layer, as it must operate within a transaction. Never access this utility in a JSP, controller, model, or other front-end class.
030     *
031     * <p>
032     * Caching information and settings can be found in <code>portal.properties</code>
033     * </p>
034     *
035     * @author Brian Wing Shun Chan
036     * @see MembershipRequestPersistence
037     * @see MembershipRequestPersistenceImpl
038     * @generated
039     */
040    @ProviderType
041    public class MembershipRequestUtil {
042            /*
043             * NOTE FOR DEVELOPERS:
044             *
045             * Never modify this class directly. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this class.
046             */
047    
048            /**
049             * @see com.liferay.portal.service.persistence.BasePersistence#clearCache()
050             */
051            public static void clearCache() {
052                    getPersistence().clearCache();
053            }
054    
055            /**
056             * @see com.liferay.portal.service.persistence.BasePersistence#clearCache(com.liferay.portal.model.BaseModel)
057             */
058            public static void clearCache(MembershipRequest membershipRequest) {
059                    getPersistence().clearCache(membershipRequest);
060            }
061    
062            /**
063             * @see com.liferay.portal.service.persistence.BasePersistence#countWithDynamicQuery(DynamicQuery)
064             */
065            public static long countWithDynamicQuery(DynamicQuery dynamicQuery) {
066                    return getPersistence().countWithDynamicQuery(dynamicQuery);
067            }
068    
069            /**
070             * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery)
071             */
072            public static List<MembershipRequest> findWithDynamicQuery(
073                    DynamicQuery dynamicQuery) {
074                    return getPersistence().findWithDynamicQuery(dynamicQuery);
075            }
076    
077            /**
078             * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int)
079             */
080            public static List<MembershipRequest> findWithDynamicQuery(
081                    DynamicQuery dynamicQuery, int start, int end) {
082                    return getPersistence().findWithDynamicQuery(dynamicQuery, start, end);
083            }
084    
085            /**
086             * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int, OrderByComparator)
087             */
088            public static List<MembershipRequest> findWithDynamicQuery(
089                    DynamicQuery dynamicQuery, int start, int end,
090                    OrderByComparator<MembershipRequest> orderByComparator) {
091                    return getPersistence()
092                                       .findWithDynamicQuery(dynamicQuery, start, end,
093                            orderByComparator);
094            }
095    
096            /**
097             * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel)
098             */
099            public static MembershipRequest update(MembershipRequest membershipRequest) {
100                    return getPersistence().update(membershipRequest);
101            }
102    
103            /**
104             * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, ServiceContext)
105             */
106            public static MembershipRequest update(
107                    MembershipRequest membershipRequest, ServiceContext serviceContext) {
108                    return getPersistence().update(membershipRequest, serviceContext);
109            }
110    
111            /**
112            * Returns all the membership requests where groupId = &#63;.
113            *
114            * @param groupId the group ID
115            * @return the matching membership requests
116            */
117            public static java.util.List<com.liferay.portal.model.MembershipRequest> findByGroupId(
118                    long groupId) {
119                    return getPersistence().findByGroupId(groupId);
120            }
121    
122            /**
123            * Returns a range of all the membership requests where groupId = &#63;.
124            *
125            * <p>
126            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.MembershipRequestModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
127            * </p>
128            *
129            * @param groupId the group ID
130            * @param start the lower bound of the range of membership requests
131            * @param end the upper bound of the range of membership requests (not inclusive)
132            * @return the range of matching membership requests
133            */
134            public static java.util.List<com.liferay.portal.model.MembershipRequest> findByGroupId(
135                    long groupId, int start, int end) {
136                    return getPersistence().findByGroupId(groupId, start, end);
137            }
138    
139            /**
140            * Returns an ordered range of all the membership requests where groupId = &#63;.
141            *
142            * <p>
143            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.MembershipRequestModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
144            * </p>
145            *
146            * @param groupId the group ID
147            * @param start the lower bound of the range of membership requests
148            * @param end the upper bound of the range of membership requests (not inclusive)
149            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
150            * @return the ordered range of matching membership requests
151            */
152            public static java.util.List<com.liferay.portal.model.MembershipRequest> findByGroupId(
153                    long groupId, int start, int end,
154                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.MembershipRequest> orderByComparator) {
155                    return getPersistence()
156                                       .findByGroupId(groupId, start, end, orderByComparator);
157            }
158    
159            /**
160            * Returns the first membership request in the ordered set where groupId = &#63;.
161            *
162            * @param groupId the group ID
163            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
164            * @return the first matching membership request
165            * @throws com.liferay.portal.NoSuchMembershipRequestException if a matching membership request could not be found
166            */
167            public static com.liferay.portal.model.MembershipRequest findByGroupId_First(
168                    long groupId,
169                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.MembershipRequest> orderByComparator)
170                    throws com.liferay.portal.NoSuchMembershipRequestException {
171                    return getPersistence().findByGroupId_First(groupId, orderByComparator);
172            }
173    
174            /**
175            * Returns the first membership request in the ordered set where groupId = &#63;.
176            *
177            * @param groupId the group ID
178            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
179            * @return the first matching membership request, or <code>null</code> if a matching membership request could not be found
180            */
181            public static com.liferay.portal.model.MembershipRequest fetchByGroupId_First(
182                    long groupId,
183                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.MembershipRequest> orderByComparator) {
184                    return getPersistence().fetchByGroupId_First(groupId, orderByComparator);
185            }
186    
187            /**
188            * Returns the last membership request in the ordered set where groupId = &#63;.
189            *
190            * @param groupId the group ID
191            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
192            * @return the last matching membership request
193            * @throws com.liferay.portal.NoSuchMembershipRequestException if a matching membership request could not be found
194            */
195            public static com.liferay.portal.model.MembershipRequest findByGroupId_Last(
196                    long groupId,
197                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.MembershipRequest> orderByComparator)
198                    throws com.liferay.portal.NoSuchMembershipRequestException {
199                    return getPersistence().findByGroupId_Last(groupId, orderByComparator);
200            }
201    
202            /**
203            * Returns the last membership request in the ordered set where groupId = &#63;.
204            *
205            * @param groupId the group ID
206            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
207            * @return the last matching membership request, or <code>null</code> if a matching membership request could not be found
208            */
209            public static com.liferay.portal.model.MembershipRequest fetchByGroupId_Last(
210                    long groupId,
211                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.MembershipRequest> orderByComparator) {
212                    return getPersistence().fetchByGroupId_Last(groupId, orderByComparator);
213            }
214    
215            /**
216            * Returns the membership requests before and after the current membership request in the ordered set where groupId = &#63;.
217            *
218            * @param membershipRequestId the primary key of the current membership request
219            * @param groupId the group ID
220            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
221            * @return the previous, current, and next membership request
222            * @throws com.liferay.portal.NoSuchMembershipRequestException if a membership request with the primary key could not be found
223            */
224            public static com.liferay.portal.model.MembershipRequest[] findByGroupId_PrevAndNext(
225                    long membershipRequestId, long groupId,
226                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.MembershipRequest> orderByComparator)
227                    throws com.liferay.portal.NoSuchMembershipRequestException {
228                    return getPersistence()
229                                       .findByGroupId_PrevAndNext(membershipRequestId, groupId,
230                            orderByComparator);
231            }
232    
233            /**
234            * Removes all the membership requests where groupId = &#63; from the database.
235            *
236            * @param groupId the group ID
237            */
238            public static void removeByGroupId(long groupId) {
239                    getPersistence().removeByGroupId(groupId);
240            }
241    
242            /**
243            * Returns the number of membership requests where groupId = &#63;.
244            *
245            * @param groupId the group ID
246            * @return the number of matching membership requests
247            */
248            public static int countByGroupId(long groupId) {
249                    return getPersistence().countByGroupId(groupId);
250            }
251    
252            /**
253            * Returns all the membership requests where userId = &#63;.
254            *
255            * @param userId the user ID
256            * @return the matching membership requests
257            */
258            public static java.util.List<com.liferay.portal.model.MembershipRequest> findByUserId(
259                    long userId) {
260                    return getPersistence().findByUserId(userId);
261            }
262    
263            /**
264            * Returns a range of all the membership requests where userId = &#63;.
265            *
266            * <p>
267            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.MembershipRequestModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
268            * </p>
269            *
270            * @param userId the user ID
271            * @param start the lower bound of the range of membership requests
272            * @param end the upper bound of the range of membership requests (not inclusive)
273            * @return the range of matching membership requests
274            */
275            public static java.util.List<com.liferay.portal.model.MembershipRequest> findByUserId(
276                    long userId, int start, int end) {
277                    return getPersistence().findByUserId(userId, start, end);
278            }
279    
280            /**
281            * Returns an ordered range of all the membership requests where userId = &#63;.
282            *
283            * <p>
284            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.MembershipRequestModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
285            * </p>
286            *
287            * @param userId the user ID
288            * @param start the lower bound of the range of membership requests
289            * @param end the upper bound of the range of membership requests (not inclusive)
290            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
291            * @return the ordered range of matching membership requests
292            */
293            public static java.util.List<com.liferay.portal.model.MembershipRequest> findByUserId(
294                    long userId, int start, int end,
295                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.MembershipRequest> orderByComparator) {
296                    return getPersistence()
297                                       .findByUserId(userId, start, end, orderByComparator);
298            }
299    
300            /**
301            * Returns the first membership request in the ordered set where userId = &#63;.
302            *
303            * @param userId the user ID
304            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
305            * @return the first matching membership request
306            * @throws com.liferay.portal.NoSuchMembershipRequestException if a matching membership request could not be found
307            */
308            public static com.liferay.portal.model.MembershipRequest findByUserId_First(
309                    long userId,
310                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.MembershipRequest> orderByComparator)
311                    throws com.liferay.portal.NoSuchMembershipRequestException {
312                    return getPersistence().findByUserId_First(userId, orderByComparator);
313            }
314    
315            /**
316            * Returns the first membership request in the ordered set where userId = &#63;.
317            *
318            * @param userId the user ID
319            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
320            * @return the first matching membership request, or <code>null</code> if a matching membership request could not be found
321            */
322            public static com.liferay.portal.model.MembershipRequest fetchByUserId_First(
323                    long userId,
324                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.MembershipRequest> orderByComparator) {
325                    return getPersistence().fetchByUserId_First(userId, orderByComparator);
326            }
327    
328            /**
329            * Returns the last membership request in the ordered set where userId = &#63;.
330            *
331            * @param userId the user ID
332            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
333            * @return the last matching membership request
334            * @throws com.liferay.portal.NoSuchMembershipRequestException if a matching membership request could not be found
335            */
336            public static com.liferay.portal.model.MembershipRequest findByUserId_Last(
337                    long userId,
338                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.MembershipRequest> orderByComparator)
339                    throws com.liferay.portal.NoSuchMembershipRequestException {
340                    return getPersistence().findByUserId_Last(userId, orderByComparator);
341            }
342    
343            /**
344            * Returns the last membership request in the ordered set where userId = &#63;.
345            *
346            * @param userId the user ID
347            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
348            * @return the last matching membership request, or <code>null</code> if a matching membership request could not be found
349            */
350            public static com.liferay.portal.model.MembershipRequest fetchByUserId_Last(
351                    long userId,
352                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.MembershipRequest> orderByComparator) {
353                    return getPersistence().fetchByUserId_Last(userId, orderByComparator);
354            }
355    
356            /**
357            * Returns the membership requests before and after the current membership request in the ordered set where userId = &#63;.
358            *
359            * @param membershipRequestId the primary key of the current membership request
360            * @param userId the user ID
361            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
362            * @return the previous, current, and next membership request
363            * @throws com.liferay.portal.NoSuchMembershipRequestException if a membership request with the primary key could not be found
364            */
365            public static com.liferay.portal.model.MembershipRequest[] findByUserId_PrevAndNext(
366                    long membershipRequestId, long userId,
367                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.MembershipRequest> orderByComparator)
368                    throws com.liferay.portal.NoSuchMembershipRequestException {
369                    return getPersistence()
370                                       .findByUserId_PrevAndNext(membershipRequestId, userId,
371                            orderByComparator);
372            }
373    
374            /**
375            * Removes all the membership requests where userId = &#63; from the database.
376            *
377            * @param userId the user ID
378            */
379            public static void removeByUserId(long userId) {
380                    getPersistence().removeByUserId(userId);
381            }
382    
383            /**
384            * Returns the number of membership requests where userId = &#63;.
385            *
386            * @param userId the user ID
387            * @return the number of matching membership requests
388            */
389            public static int countByUserId(long userId) {
390                    return getPersistence().countByUserId(userId);
391            }
392    
393            /**
394            * Returns all the membership requests where groupId = &#63; and statusId = &#63;.
395            *
396            * @param groupId the group ID
397            * @param statusId the status ID
398            * @return the matching membership requests
399            */
400            public static java.util.List<com.liferay.portal.model.MembershipRequest> findByG_S(
401                    long groupId, int statusId) {
402                    return getPersistence().findByG_S(groupId, statusId);
403            }
404    
405            /**
406            * Returns a range of all the membership requests where groupId = &#63; and statusId = &#63;.
407            *
408            * <p>
409            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.MembershipRequestModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
410            * </p>
411            *
412            * @param groupId the group ID
413            * @param statusId the status ID
414            * @param start the lower bound of the range of membership requests
415            * @param end the upper bound of the range of membership requests (not inclusive)
416            * @return the range of matching membership requests
417            */
418            public static java.util.List<com.liferay.portal.model.MembershipRequest> findByG_S(
419                    long groupId, int statusId, int start, int end) {
420                    return getPersistence().findByG_S(groupId, statusId, start, end);
421            }
422    
423            /**
424            * Returns an ordered range of all the membership requests where groupId = &#63; and statusId = &#63;.
425            *
426            * <p>
427            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.MembershipRequestModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
428            * </p>
429            *
430            * @param groupId the group ID
431            * @param statusId the status ID
432            * @param start the lower bound of the range of membership requests
433            * @param end the upper bound of the range of membership requests (not inclusive)
434            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
435            * @return the ordered range of matching membership requests
436            */
437            public static java.util.List<com.liferay.portal.model.MembershipRequest> findByG_S(
438                    long groupId, int statusId, int start, int end,
439                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.MembershipRequest> orderByComparator) {
440                    return getPersistence()
441                                       .findByG_S(groupId, statusId, start, end, orderByComparator);
442            }
443    
444            /**
445            * Returns the first membership request in the ordered set where groupId = &#63; and statusId = &#63;.
446            *
447            * @param groupId the group ID
448            * @param statusId the status ID
449            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
450            * @return the first matching membership request
451            * @throws com.liferay.portal.NoSuchMembershipRequestException if a matching membership request could not be found
452            */
453            public static com.liferay.portal.model.MembershipRequest findByG_S_First(
454                    long groupId, int statusId,
455                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.MembershipRequest> orderByComparator)
456                    throws com.liferay.portal.NoSuchMembershipRequestException {
457                    return getPersistence()
458                                       .findByG_S_First(groupId, statusId, orderByComparator);
459            }
460    
461            /**
462            * Returns the first membership request in the ordered set where groupId = &#63; and statusId = &#63;.
463            *
464            * @param groupId the group ID
465            * @param statusId the status ID
466            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
467            * @return the first matching membership request, or <code>null</code> if a matching membership request could not be found
468            */
469            public static com.liferay.portal.model.MembershipRequest fetchByG_S_First(
470                    long groupId, int statusId,
471                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.MembershipRequest> orderByComparator) {
472                    return getPersistence()
473                                       .fetchByG_S_First(groupId, statusId, orderByComparator);
474            }
475    
476            /**
477            * Returns the last membership request in the ordered set where groupId = &#63; and statusId = &#63;.
478            *
479            * @param groupId the group ID
480            * @param statusId the status ID
481            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
482            * @return the last matching membership request
483            * @throws com.liferay.portal.NoSuchMembershipRequestException if a matching membership request could not be found
484            */
485            public static com.liferay.portal.model.MembershipRequest findByG_S_Last(
486                    long groupId, int statusId,
487                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.MembershipRequest> orderByComparator)
488                    throws com.liferay.portal.NoSuchMembershipRequestException {
489                    return getPersistence()
490                                       .findByG_S_Last(groupId, statusId, orderByComparator);
491            }
492    
493            /**
494            * Returns the last membership request in the ordered set where groupId = &#63; and statusId = &#63;.
495            *
496            * @param groupId the group ID
497            * @param statusId the status ID
498            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
499            * @return the last matching membership request, or <code>null</code> if a matching membership request could not be found
500            */
501            public static com.liferay.portal.model.MembershipRequest fetchByG_S_Last(
502                    long groupId, int statusId,
503                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.MembershipRequest> orderByComparator) {
504                    return getPersistence()
505                                       .fetchByG_S_Last(groupId, statusId, orderByComparator);
506            }
507    
508            /**
509            * Returns the membership requests before and after the current membership request in the ordered set where groupId = &#63; and statusId = &#63;.
510            *
511            * @param membershipRequestId the primary key of the current membership request
512            * @param groupId the group ID
513            * @param statusId the status ID
514            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
515            * @return the previous, current, and next membership request
516            * @throws com.liferay.portal.NoSuchMembershipRequestException if a membership request with the primary key could not be found
517            */
518            public static com.liferay.portal.model.MembershipRequest[] findByG_S_PrevAndNext(
519                    long membershipRequestId, long groupId, int statusId,
520                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.MembershipRequest> orderByComparator)
521                    throws com.liferay.portal.NoSuchMembershipRequestException {
522                    return getPersistence()
523                                       .findByG_S_PrevAndNext(membershipRequestId, groupId,
524                            statusId, orderByComparator);
525            }
526    
527            /**
528            * Removes all the membership requests where groupId = &#63; and statusId = &#63; from the database.
529            *
530            * @param groupId the group ID
531            * @param statusId the status ID
532            */
533            public static void removeByG_S(long groupId, int statusId) {
534                    getPersistence().removeByG_S(groupId, statusId);
535            }
536    
537            /**
538            * Returns the number of membership requests where groupId = &#63; and statusId = &#63;.
539            *
540            * @param groupId the group ID
541            * @param statusId the status ID
542            * @return the number of matching membership requests
543            */
544            public static int countByG_S(long groupId, int statusId) {
545                    return getPersistence().countByG_S(groupId, statusId);
546            }
547    
548            /**
549            * Returns all the membership requests where groupId = &#63; and userId = &#63; and statusId = &#63;.
550            *
551            * @param groupId the group ID
552            * @param userId the user ID
553            * @param statusId the status ID
554            * @return the matching membership requests
555            */
556            public static java.util.List<com.liferay.portal.model.MembershipRequest> findByG_U_S(
557                    long groupId, long userId, int statusId) {
558                    return getPersistence().findByG_U_S(groupId, userId, statusId);
559            }
560    
561            /**
562            * Returns a range of all the membership requests where groupId = &#63; and userId = &#63; and statusId = &#63;.
563            *
564            * <p>
565            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.MembershipRequestModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
566            * </p>
567            *
568            * @param groupId the group ID
569            * @param userId the user ID
570            * @param statusId the status ID
571            * @param start the lower bound of the range of membership requests
572            * @param end the upper bound of the range of membership requests (not inclusive)
573            * @return the range of matching membership requests
574            */
575            public static java.util.List<com.liferay.portal.model.MembershipRequest> findByG_U_S(
576                    long groupId, long userId, int statusId, int start, int end) {
577                    return getPersistence()
578                                       .findByG_U_S(groupId, userId, statusId, start, end);
579            }
580    
581            /**
582            * Returns an ordered range of all the membership requests where groupId = &#63; and userId = &#63; and statusId = &#63;.
583            *
584            * <p>
585            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.MembershipRequestModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
586            * </p>
587            *
588            * @param groupId the group ID
589            * @param userId the user ID
590            * @param statusId the status ID
591            * @param start the lower bound of the range of membership requests
592            * @param end the upper bound of the range of membership requests (not inclusive)
593            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
594            * @return the ordered range of matching membership requests
595            */
596            public static java.util.List<com.liferay.portal.model.MembershipRequest> findByG_U_S(
597                    long groupId, long userId, int statusId, int start, int end,
598                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.MembershipRequest> orderByComparator) {
599                    return getPersistence()
600                                       .findByG_U_S(groupId, userId, statusId, start, end,
601                            orderByComparator);
602            }
603    
604            /**
605            * Returns the first membership request in the ordered set where groupId = &#63; and userId = &#63; and statusId = &#63;.
606            *
607            * @param groupId the group ID
608            * @param userId the user ID
609            * @param statusId the status ID
610            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
611            * @return the first matching membership request
612            * @throws com.liferay.portal.NoSuchMembershipRequestException if a matching membership request could not be found
613            */
614            public static com.liferay.portal.model.MembershipRequest findByG_U_S_First(
615                    long groupId, long userId, int statusId,
616                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.MembershipRequest> orderByComparator)
617                    throws com.liferay.portal.NoSuchMembershipRequestException {
618                    return getPersistence()
619                                       .findByG_U_S_First(groupId, userId, statusId,
620                            orderByComparator);
621            }
622    
623            /**
624            * Returns the first membership request in the ordered set where groupId = &#63; and userId = &#63; and statusId = &#63;.
625            *
626            * @param groupId the group ID
627            * @param userId the user ID
628            * @param statusId the status ID
629            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
630            * @return the first matching membership request, or <code>null</code> if a matching membership request could not be found
631            */
632            public static com.liferay.portal.model.MembershipRequest fetchByG_U_S_First(
633                    long groupId, long userId, int statusId,
634                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.MembershipRequest> orderByComparator) {
635                    return getPersistence()
636                                       .fetchByG_U_S_First(groupId, userId, statusId,
637                            orderByComparator);
638            }
639    
640            /**
641            * Returns the last membership request in the ordered set where groupId = &#63; and userId = &#63; and statusId = &#63;.
642            *
643            * @param groupId the group ID
644            * @param userId the user ID
645            * @param statusId the status ID
646            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
647            * @return the last matching membership request
648            * @throws com.liferay.portal.NoSuchMembershipRequestException if a matching membership request could not be found
649            */
650            public static com.liferay.portal.model.MembershipRequest findByG_U_S_Last(
651                    long groupId, long userId, int statusId,
652                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.MembershipRequest> orderByComparator)
653                    throws com.liferay.portal.NoSuchMembershipRequestException {
654                    return getPersistence()
655                                       .findByG_U_S_Last(groupId, userId, statusId,
656                            orderByComparator);
657            }
658    
659            /**
660            * Returns the last membership request in the ordered set where groupId = &#63; and userId = &#63; and statusId = &#63;.
661            *
662            * @param groupId the group ID
663            * @param userId the user ID
664            * @param statusId the status ID
665            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
666            * @return the last matching membership request, or <code>null</code> if a matching membership request could not be found
667            */
668            public static com.liferay.portal.model.MembershipRequest fetchByG_U_S_Last(
669                    long groupId, long userId, int statusId,
670                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.MembershipRequest> orderByComparator) {
671                    return getPersistence()
672                                       .fetchByG_U_S_Last(groupId, userId, statusId,
673                            orderByComparator);
674            }
675    
676            /**
677            * Returns the membership requests before and after the current membership request in the ordered set where groupId = &#63; and userId = &#63; and statusId = &#63;.
678            *
679            * @param membershipRequestId the primary key of the current membership request
680            * @param groupId the group ID
681            * @param userId the user ID
682            * @param statusId the status ID
683            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
684            * @return the previous, current, and next membership request
685            * @throws com.liferay.portal.NoSuchMembershipRequestException if a membership request with the primary key could not be found
686            */
687            public static com.liferay.portal.model.MembershipRequest[] findByG_U_S_PrevAndNext(
688                    long membershipRequestId, long groupId, long userId, int statusId,
689                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.MembershipRequest> orderByComparator)
690                    throws com.liferay.portal.NoSuchMembershipRequestException {
691                    return getPersistence()
692                                       .findByG_U_S_PrevAndNext(membershipRequestId, groupId,
693                            userId, statusId, orderByComparator);
694            }
695    
696            /**
697            * Removes all the membership requests where groupId = &#63; and userId = &#63; and statusId = &#63; from the database.
698            *
699            * @param groupId the group ID
700            * @param userId the user ID
701            * @param statusId the status ID
702            */
703            public static void removeByG_U_S(long groupId, long userId, int statusId) {
704                    getPersistence().removeByG_U_S(groupId, userId, statusId);
705            }
706    
707            /**
708            * Returns the number of membership requests where groupId = &#63; and userId = &#63; and statusId = &#63;.
709            *
710            * @param groupId the group ID
711            * @param userId the user ID
712            * @param statusId the status ID
713            * @return the number of matching membership requests
714            */
715            public static int countByG_U_S(long groupId, long userId, int statusId) {
716                    return getPersistence().countByG_U_S(groupId, userId, statusId);
717            }
718    
719            /**
720            * Caches the membership request in the entity cache if it is enabled.
721            *
722            * @param membershipRequest the membership request
723            */
724            public static void cacheResult(
725                    com.liferay.portal.model.MembershipRequest membershipRequest) {
726                    getPersistence().cacheResult(membershipRequest);
727            }
728    
729            /**
730            * Caches the membership requests in the entity cache if it is enabled.
731            *
732            * @param membershipRequests the membership requests
733            */
734            public static void cacheResult(
735                    java.util.List<com.liferay.portal.model.MembershipRequest> membershipRequests) {
736                    getPersistence().cacheResult(membershipRequests);
737            }
738    
739            /**
740            * Creates a new membership request with the primary key. Does not add the membership request to the database.
741            *
742            * @param membershipRequestId the primary key for the new membership request
743            * @return the new membership request
744            */
745            public static com.liferay.portal.model.MembershipRequest create(
746                    long membershipRequestId) {
747                    return getPersistence().create(membershipRequestId);
748            }
749    
750            /**
751            * Removes the membership request with the primary key from the database. Also notifies the appropriate model listeners.
752            *
753            * @param membershipRequestId the primary key of the membership request
754            * @return the membership request that was removed
755            * @throws com.liferay.portal.NoSuchMembershipRequestException if a membership request with the primary key could not be found
756            */
757            public static com.liferay.portal.model.MembershipRequest remove(
758                    long membershipRequestId)
759                    throws com.liferay.portal.NoSuchMembershipRequestException {
760                    return getPersistence().remove(membershipRequestId);
761            }
762    
763            public static com.liferay.portal.model.MembershipRequest updateImpl(
764                    com.liferay.portal.model.MembershipRequest membershipRequest) {
765                    return getPersistence().updateImpl(membershipRequest);
766            }
767    
768            /**
769            * Returns the membership request with the primary key or throws a {@link com.liferay.portal.NoSuchMembershipRequestException} if it could not be found.
770            *
771            * @param membershipRequestId the primary key of the membership request
772            * @return the membership request
773            * @throws com.liferay.portal.NoSuchMembershipRequestException if a membership request with the primary key could not be found
774            */
775            public static com.liferay.portal.model.MembershipRequest findByPrimaryKey(
776                    long membershipRequestId)
777                    throws com.liferay.portal.NoSuchMembershipRequestException {
778                    return getPersistence().findByPrimaryKey(membershipRequestId);
779            }
780    
781            /**
782            * Returns the membership request with the primary key or returns <code>null</code> if it could not be found.
783            *
784            * @param membershipRequestId the primary key of the membership request
785            * @return the membership request, or <code>null</code> if a membership request with the primary key could not be found
786            */
787            public static com.liferay.portal.model.MembershipRequest fetchByPrimaryKey(
788                    long membershipRequestId) {
789                    return getPersistence().fetchByPrimaryKey(membershipRequestId);
790            }
791    
792            public static java.util.Map<java.io.Serializable, com.liferay.portal.model.MembershipRequest> fetchByPrimaryKeys(
793                    java.util.Set<java.io.Serializable> primaryKeys) {
794                    return getPersistence().fetchByPrimaryKeys(primaryKeys);
795            }
796    
797            /**
798            * Returns all the membership requests.
799            *
800            * @return the membership requests
801            */
802            public static java.util.List<com.liferay.portal.model.MembershipRequest> findAll() {
803                    return getPersistence().findAll();
804            }
805    
806            /**
807            * Returns a range of all the membership requests.
808            *
809            * <p>
810            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.MembershipRequestModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
811            * </p>
812            *
813            * @param start the lower bound of the range of membership requests
814            * @param end the upper bound of the range of membership requests (not inclusive)
815            * @return the range of membership requests
816            */
817            public static java.util.List<com.liferay.portal.model.MembershipRequest> findAll(
818                    int start, int end) {
819                    return getPersistence().findAll(start, end);
820            }
821    
822            /**
823            * Returns an ordered range of all the membership requests.
824            *
825            * <p>
826            * 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. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portal.model.impl.MembershipRequestModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
827            * </p>
828            *
829            * @param start the lower bound of the range of membership requests
830            * @param end the upper bound of the range of membership requests (not inclusive)
831            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
832            * @return the ordered range of membership requests
833            */
834            public static java.util.List<com.liferay.portal.model.MembershipRequest> findAll(
835                    int start, int end,
836                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.model.MembershipRequest> orderByComparator) {
837                    return getPersistence().findAll(start, end, orderByComparator);
838            }
839    
840            /**
841            * Removes all the membership requests from the database.
842            */
843            public static void removeAll() {
844                    getPersistence().removeAll();
845            }
846    
847            /**
848            * Returns the number of membership requests.
849            *
850            * @return the number of membership requests
851            */
852            public static int countAll() {
853                    return getPersistence().countAll();
854            }
855    
856            public static MembershipRequestPersistence getPersistence() {
857                    if (_persistence == null) {
858                            _persistence = (MembershipRequestPersistence)PortalBeanLocatorUtil.locate(MembershipRequestPersistence.class.getName());
859    
860                            ReferenceRegistry.registerReference(MembershipRequestUtil.class,
861                                    "_persistence");
862                    }
863    
864                    return _persistence;
865            }
866    
867            /**
868             * @deprecated As of 6.2.0
869             */
870            @Deprecated
871            public void setPersistence(MembershipRequestPersistence persistence) {
872            }
873    
874            private static MembershipRequestPersistence _persistence;
875    }