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.kernel.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.model.Team;
022    import com.liferay.portal.kernel.service.ServiceContext;
023    import com.liferay.portal.kernel.util.OrderByComparator;
024    import com.liferay.portal.kernel.util.ReferenceRegistry;
025    
026    import java.util.List;
027    
028    /**
029     * The persistence utility for the team service. This utility wraps {@link com.liferay.portal.service.persistence.impl.TeamPersistenceImpl} 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 TeamPersistence
037     * @see com.liferay.portal.service.persistence.impl.TeamPersistenceImpl
038     * @generated
039     */
040    @ProviderType
041    public class TeamUtil {
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 BasePersistence#clearCache()
050             */
051            public static void clearCache() {
052                    getPersistence().clearCache();
053            }
054    
055            /**
056             * @see BasePersistence#clearCache(com.liferay.portal.kernel.model.BaseModel)
057             */
058            public static void clearCache(Team team) {
059                    getPersistence().clearCache(team);
060            }
061    
062            /**
063             * @see BasePersistence#countWithDynamicQuery(DynamicQuery)
064             */
065            public static long countWithDynamicQuery(DynamicQuery dynamicQuery) {
066                    return getPersistence().countWithDynamicQuery(dynamicQuery);
067            }
068    
069            /**
070             * @see BasePersistence#findWithDynamicQuery(DynamicQuery)
071             */
072            public static List<Team> findWithDynamicQuery(DynamicQuery dynamicQuery) {
073                    return getPersistence().findWithDynamicQuery(dynamicQuery);
074            }
075    
076            /**
077             * @see BasePersistence#findWithDynamicQuery(DynamicQuery, int, int)
078             */
079            public static List<Team> findWithDynamicQuery(DynamicQuery dynamicQuery,
080                    int start, int end) {
081                    return getPersistence().findWithDynamicQuery(dynamicQuery, start, end);
082            }
083    
084            /**
085             * @see BasePersistence#findWithDynamicQuery(DynamicQuery, int, int, OrderByComparator)
086             */
087            public static List<Team> findWithDynamicQuery(DynamicQuery dynamicQuery,
088                    int start, int end, OrderByComparator<Team> orderByComparator) {
089                    return getPersistence()
090                                       .findWithDynamicQuery(dynamicQuery, start, end,
091                            orderByComparator);
092            }
093    
094            /**
095             * @see BasePersistence#update(com.liferay.portal.kernel.model.BaseModel)
096             */
097            public static Team update(Team team) {
098                    return getPersistence().update(team);
099            }
100    
101            /**
102             * @see BasePersistence#update(com.liferay.portal.kernel.model.BaseModel, ServiceContext)
103             */
104            public static Team update(Team team, ServiceContext serviceContext) {
105                    return getPersistence().update(team, serviceContext);
106            }
107    
108            /**
109            * Returns all the teams where uuid = &#63;.
110            *
111            * @param uuid the uuid
112            * @return the matching teams
113            */
114            public static List<Team> findByUuid(java.lang.String uuid) {
115                    return getPersistence().findByUuid(uuid);
116            }
117    
118            /**
119            * Returns a range of all the teams where uuid = &#63;.
120            *
121            * <p>
122            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link TeamModelImpl}. 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.
123            * </p>
124            *
125            * @param uuid the uuid
126            * @param start the lower bound of the range of teams
127            * @param end the upper bound of the range of teams (not inclusive)
128            * @return the range of matching teams
129            */
130            public static List<Team> findByUuid(java.lang.String uuid, int start,
131                    int end) {
132                    return getPersistence().findByUuid(uuid, start, end);
133            }
134    
135            /**
136            * Returns an ordered range of all the teams where uuid = &#63;.
137            *
138            * <p>
139            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link TeamModelImpl}. 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.
140            * </p>
141            *
142            * @param uuid the uuid
143            * @param start the lower bound of the range of teams
144            * @param end the upper bound of the range of teams (not inclusive)
145            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
146            * @return the ordered range of matching teams
147            */
148            public static List<Team> findByUuid(java.lang.String uuid, int start,
149                    int end, OrderByComparator<Team> orderByComparator) {
150                    return getPersistence().findByUuid(uuid, start, end, orderByComparator);
151            }
152    
153            /**
154            * Returns an ordered range of all the teams where uuid = &#63;.
155            *
156            * <p>
157            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link TeamModelImpl}. 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.
158            * </p>
159            *
160            * @param uuid the uuid
161            * @param start the lower bound of the range of teams
162            * @param end the upper bound of the range of teams (not inclusive)
163            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
164            * @param retrieveFromCache whether to retrieve from the finder cache
165            * @return the ordered range of matching teams
166            */
167            public static List<Team> findByUuid(java.lang.String uuid, int start,
168                    int end, OrderByComparator<Team> orderByComparator,
169                    boolean retrieveFromCache) {
170                    return getPersistence()
171                                       .findByUuid(uuid, start, end, orderByComparator,
172                            retrieveFromCache);
173            }
174    
175            /**
176            * Returns the first team in the ordered set where uuid = &#63;.
177            *
178            * @param uuid the uuid
179            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
180            * @return the first matching team
181            * @throws NoSuchTeamException if a matching team could not be found
182            */
183            public static Team findByUuid_First(java.lang.String uuid,
184                    OrderByComparator<Team> orderByComparator)
185                    throws com.liferay.portal.kernel.exception.NoSuchTeamException {
186                    return getPersistence().findByUuid_First(uuid, orderByComparator);
187            }
188    
189            /**
190            * Returns the first team in the ordered set where uuid = &#63;.
191            *
192            * @param uuid the uuid
193            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
194            * @return the first matching team, or <code>null</code> if a matching team could not be found
195            */
196            public static Team fetchByUuid_First(java.lang.String uuid,
197                    OrderByComparator<Team> orderByComparator) {
198                    return getPersistence().fetchByUuid_First(uuid, orderByComparator);
199            }
200    
201            /**
202            * Returns the last team in the ordered set where uuid = &#63;.
203            *
204            * @param uuid the uuid
205            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
206            * @return the last matching team
207            * @throws NoSuchTeamException if a matching team could not be found
208            */
209            public static Team findByUuid_Last(java.lang.String uuid,
210                    OrderByComparator<Team> orderByComparator)
211                    throws com.liferay.portal.kernel.exception.NoSuchTeamException {
212                    return getPersistence().findByUuid_Last(uuid, orderByComparator);
213            }
214    
215            /**
216            * Returns the last team in the ordered set where uuid = &#63;.
217            *
218            * @param uuid the uuid
219            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
220            * @return the last matching team, or <code>null</code> if a matching team could not be found
221            */
222            public static Team fetchByUuid_Last(java.lang.String uuid,
223                    OrderByComparator<Team> orderByComparator) {
224                    return getPersistence().fetchByUuid_Last(uuid, orderByComparator);
225            }
226    
227            /**
228            * Returns the teams before and after the current team in the ordered set where uuid = &#63;.
229            *
230            * @param teamId the primary key of the current team
231            * @param uuid the uuid
232            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
233            * @return the previous, current, and next team
234            * @throws NoSuchTeamException if a team with the primary key could not be found
235            */
236            public static Team[] findByUuid_PrevAndNext(long teamId,
237                    java.lang.String uuid, OrderByComparator<Team> orderByComparator)
238                    throws com.liferay.portal.kernel.exception.NoSuchTeamException {
239                    return getPersistence()
240                                       .findByUuid_PrevAndNext(teamId, uuid, orderByComparator);
241            }
242    
243            /**
244            * Removes all the teams where uuid = &#63; from the database.
245            *
246            * @param uuid the uuid
247            */
248            public static void removeByUuid(java.lang.String uuid) {
249                    getPersistence().removeByUuid(uuid);
250            }
251    
252            /**
253            * Returns the number of teams where uuid = &#63;.
254            *
255            * @param uuid the uuid
256            * @return the number of matching teams
257            */
258            public static int countByUuid(java.lang.String uuid) {
259                    return getPersistence().countByUuid(uuid);
260            }
261    
262            /**
263            * Returns the team where uuid = &#63; and groupId = &#63; or throws a {@link NoSuchTeamException} if it could not be found.
264            *
265            * @param uuid the uuid
266            * @param groupId the group ID
267            * @return the matching team
268            * @throws NoSuchTeamException if a matching team could not be found
269            */
270            public static Team findByUUID_G(java.lang.String uuid, long groupId)
271                    throws com.liferay.portal.kernel.exception.NoSuchTeamException {
272                    return getPersistence().findByUUID_G(uuid, groupId);
273            }
274    
275            /**
276            * Returns the team where uuid = &#63; and groupId = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
277            *
278            * @param uuid the uuid
279            * @param groupId the group ID
280            * @return the matching team, or <code>null</code> if a matching team could not be found
281            */
282            public static Team fetchByUUID_G(java.lang.String uuid, long groupId) {
283                    return getPersistence().fetchByUUID_G(uuid, groupId);
284            }
285    
286            /**
287            * Returns the team where uuid = &#63; and groupId = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
288            *
289            * @param uuid the uuid
290            * @param groupId the group ID
291            * @param retrieveFromCache whether to retrieve from the finder cache
292            * @return the matching team, or <code>null</code> if a matching team could not be found
293            */
294            public static Team fetchByUUID_G(java.lang.String uuid, long groupId,
295                    boolean retrieveFromCache) {
296                    return getPersistence().fetchByUUID_G(uuid, groupId, retrieveFromCache);
297            }
298    
299            /**
300            * Removes the team where uuid = &#63; and groupId = &#63; from the database.
301            *
302            * @param uuid the uuid
303            * @param groupId the group ID
304            * @return the team that was removed
305            */
306            public static Team removeByUUID_G(java.lang.String uuid, long groupId)
307                    throws com.liferay.portal.kernel.exception.NoSuchTeamException {
308                    return getPersistence().removeByUUID_G(uuid, groupId);
309            }
310    
311            /**
312            * Returns the number of teams where uuid = &#63; and groupId = &#63;.
313            *
314            * @param uuid the uuid
315            * @param groupId the group ID
316            * @return the number of matching teams
317            */
318            public static int countByUUID_G(java.lang.String uuid, long groupId) {
319                    return getPersistence().countByUUID_G(uuid, groupId);
320            }
321    
322            /**
323            * Returns all the teams where uuid = &#63; and companyId = &#63;.
324            *
325            * @param uuid the uuid
326            * @param companyId the company ID
327            * @return the matching teams
328            */
329            public static List<Team> findByUuid_C(java.lang.String uuid, long companyId) {
330                    return getPersistence().findByUuid_C(uuid, companyId);
331            }
332    
333            /**
334            * Returns a range of all the teams where uuid = &#63; and companyId = &#63;.
335            *
336            * <p>
337            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link TeamModelImpl}. 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.
338            * </p>
339            *
340            * @param uuid the uuid
341            * @param companyId the company ID
342            * @param start the lower bound of the range of teams
343            * @param end the upper bound of the range of teams (not inclusive)
344            * @return the range of matching teams
345            */
346            public static List<Team> findByUuid_C(java.lang.String uuid,
347                    long companyId, int start, int end) {
348                    return getPersistence().findByUuid_C(uuid, companyId, start, end);
349            }
350    
351            /**
352            * Returns an ordered range of all the teams where uuid = &#63; and companyId = &#63;.
353            *
354            * <p>
355            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link TeamModelImpl}. 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.
356            * </p>
357            *
358            * @param uuid the uuid
359            * @param companyId the company ID
360            * @param start the lower bound of the range of teams
361            * @param end the upper bound of the range of teams (not inclusive)
362            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
363            * @return the ordered range of matching teams
364            */
365            public static List<Team> findByUuid_C(java.lang.String uuid,
366                    long companyId, int start, int end,
367                    OrderByComparator<Team> orderByComparator) {
368                    return getPersistence()
369                                       .findByUuid_C(uuid, companyId, start, end, orderByComparator);
370            }
371    
372            /**
373            * Returns an ordered range of all the teams where uuid = &#63; and companyId = &#63;.
374            *
375            * <p>
376            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link TeamModelImpl}. 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.
377            * </p>
378            *
379            * @param uuid the uuid
380            * @param companyId the company ID
381            * @param start the lower bound of the range of teams
382            * @param end the upper bound of the range of teams (not inclusive)
383            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
384            * @param retrieveFromCache whether to retrieve from the finder cache
385            * @return the ordered range of matching teams
386            */
387            public static List<Team> findByUuid_C(java.lang.String uuid,
388                    long companyId, int start, int end,
389                    OrderByComparator<Team> orderByComparator, boolean retrieveFromCache) {
390                    return getPersistence()
391                                       .findByUuid_C(uuid, companyId, start, end,
392                            orderByComparator, retrieveFromCache);
393            }
394    
395            /**
396            * Returns the first team in the ordered set where uuid = &#63; and companyId = &#63;.
397            *
398            * @param uuid the uuid
399            * @param companyId the company ID
400            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
401            * @return the first matching team
402            * @throws NoSuchTeamException if a matching team could not be found
403            */
404            public static Team findByUuid_C_First(java.lang.String uuid,
405                    long companyId, OrderByComparator<Team> orderByComparator)
406                    throws com.liferay.portal.kernel.exception.NoSuchTeamException {
407                    return getPersistence()
408                                       .findByUuid_C_First(uuid, companyId, orderByComparator);
409            }
410    
411            /**
412            * Returns the first team in the ordered set where uuid = &#63; and companyId = &#63;.
413            *
414            * @param uuid the uuid
415            * @param companyId the company ID
416            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
417            * @return the first matching team, or <code>null</code> if a matching team could not be found
418            */
419            public static Team fetchByUuid_C_First(java.lang.String uuid,
420                    long companyId, OrderByComparator<Team> orderByComparator) {
421                    return getPersistence()
422                                       .fetchByUuid_C_First(uuid, companyId, orderByComparator);
423            }
424    
425            /**
426            * Returns the last team in the ordered set where uuid = &#63; and companyId = &#63;.
427            *
428            * @param uuid the uuid
429            * @param companyId the company ID
430            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
431            * @return the last matching team
432            * @throws NoSuchTeamException if a matching team could not be found
433            */
434            public static Team findByUuid_C_Last(java.lang.String uuid, long companyId,
435                    OrderByComparator<Team> orderByComparator)
436                    throws com.liferay.portal.kernel.exception.NoSuchTeamException {
437                    return getPersistence()
438                                       .findByUuid_C_Last(uuid, companyId, orderByComparator);
439            }
440    
441            /**
442            * Returns the last team in the ordered set where uuid = &#63; and companyId = &#63;.
443            *
444            * @param uuid the uuid
445            * @param companyId the company ID
446            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
447            * @return the last matching team, or <code>null</code> if a matching team could not be found
448            */
449            public static Team fetchByUuid_C_Last(java.lang.String uuid,
450                    long companyId, OrderByComparator<Team> orderByComparator) {
451                    return getPersistence()
452                                       .fetchByUuid_C_Last(uuid, companyId, orderByComparator);
453            }
454    
455            /**
456            * Returns the teams before and after the current team in the ordered set where uuid = &#63; and companyId = &#63;.
457            *
458            * @param teamId the primary key of the current team
459            * @param uuid the uuid
460            * @param companyId the company ID
461            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
462            * @return the previous, current, and next team
463            * @throws NoSuchTeamException if a team with the primary key could not be found
464            */
465            public static Team[] findByUuid_C_PrevAndNext(long teamId,
466                    java.lang.String uuid, long companyId,
467                    OrderByComparator<Team> orderByComparator)
468                    throws com.liferay.portal.kernel.exception.NoSuchTeamException {
469                    return getPersistence()
470                                       .findByUuid_C_PrevAndNext(teamId, uuid, companyId,
471                            orderByComparator);
472            }
473    
474            /**
475            * Removes all the teams where uuid = &#63; and companyId = &#63; from the database.
476            *
477            * @param uuid the uuid
478            * @param companyId the company ID
479            */
480            public static void removeByUuid_C(java.lang.String uuid, long companyId) {
481                    getPersistence().removeByUuid_C(uuid, companyId);
482            }
483    
484            /**
485            * Returns the number of teams where uuid = &#63; and companyId = &#63;.
486            *
487            * @param uuid the uuid
488            * @param companyId the company ID
489            * @return the number of matching teams
490            */
491            public static int countByUuid_C(java.lang.String uuid, long companyId) {
492                    return getPersistence().countByUuid_C(uuid, companyId);
493            }
494    
495            /**
496            * Returns all the teams where groupId = &#63;.
497            *
498            * @param groupId the group ID
499            * @return the matching teams
500            */
501            public static List<Team> findByGroupId(long groupId) {
502                    return getPersistence().findByGroupId(groupId);
503            }
504    
505            /**
506            * Returns a range of all the teams where groupId = &#63;.
507            *
508            * <p>
509            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link TeamModelImpl}. 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.
510            * </p>
511            *
512            * @param groupId the group ID
513            * @param start the lower bound of the range of teams
514            * @param end the upper bound of the range of teams (not inclusive)
515            * @return the range of matching teams
516            */
517            public static List<Team> findByGroupId(long groupId, int start, int end) {
518                    return getPersistence().findByGroupId(groupId, start, end);
519            }
520    
521            /**
522            * Returns an ordered range of all the teams where groupId = &#63;.
523            *
524            * <p>
525            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link TeamModelImpl}. 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.
526            * </p>
527            *
528            * @param groupId the group ID
529            * @param start the lower bound of the range of teams
530            * @param end the upper bound of the range of teams (not inclusive)
531            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
532            * @return the ordered range of matching teams
533            */
534            public static List<Team> findByGroupId(long groupId, int start, int end,
535                    OrderByComparator<Team> orderByComparator) {
536                    return getPersistence()
537                                       .findByGroupId(groupId, start, end, orderByComparator);
538            }
539    
540            /**
541            * Returns an ordered range of all the teams where groupId = &#63;.
542            *
543            * <p>
544            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link TeamModelImpl}. 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.
545            * </p>
546            *
547            * @param groupId the group ID
548            * @param start the lower bound of the range of teams
549            * @param end the upper bound of the range of teams (not inclusive)
550            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
551            * @param retrieveFromCache whether to retrieve from the finder cache
552            * @return the ordered range of matching teams
553            */
554            public static List<Team> findByGroupId(long groupId, int start, int end,
555                    OrderByComparator<Team> orderByComparator, boolean retrieveFromCache) {
556                    return getPersistence()
557                                       .findByGroupId(groupId, start, end, orderByComparator,
558                            retrieveFromCache);
559            }
560    
561            /**
562            * Returns the first team in the ordered set where groupId = &#63;.
563            *
564            * @param groupId the group ID
565            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
566            * @return the first matching team
567            * @throws NoSuchTeamException if a matching team could not be found
568            */
569            public static Team findByGroupId_First(long groupId,
570                    OrderByComparator<Team> orderByComparator)
571                    throws com.liferay.portal.kernel.exception.NoSuchTeamException {
572                    return getPersistence().findByGroupId_First(groupId, orderByComparator);
573            }
574    
575            /**
576            * Returns the first team in the ordered set where groupId = &#63;.
577            *
578            * @param groupId the group ID
579            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
580            * @return the first matching team, or <code>null</code> if a matching team could not be found
581            */
582            public static Team fetchByGroupId_First(long groupId,
583                    OrderByComparator<Team> orderByComparator) {
584                    return getPersistence().fetchByGroupId_First(groupId, orderByComparator);
585            }
586    
587            /**
588            * Returns the last team in the ordered set where groupId = &#63;.
589            *
590            * @param groupId the group ID
591            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
592            * @return the last matching team
593            * @throws NoSuchTeamException if a matching team could not be found
594            */
595            public static Team findByGroupId_Last(long groupId,
596                    OrderByComparator<Team> orderByComparator)
597                    throws com.liferay.portal.kernel.exception.NoSuchTeamException {
598                    return getPersistence().findByGroupId_Last(groupId, orderByComparator);
599            }
600    
601            /**
602            * Returns the last team in the ordered set where groupId = &#63;.
603            *
604            * @param groupId the group ID
605            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
606            * @return the last matching team, or <code>null</code> if a matching team could not be found
607            */
608            public static Team fetchByGroupId_Last(long groupId,
609                    OrderByComparator<Team> orderByComparator) {
610                    return getPersistence().fetchByGroupId_Last(groupId, orderByComparator);
611            }
612    
613            /**
614            * Returns the teams before and after the current team in the ordered set where groupId = &#63;.
615            *
616            * @param teamId the primary key of the current team
617            * @param groupId the group ID
618            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
619            * @return the previous, current, and next team
620            * @throws NoSuchTeamException if a team with the primary key could not be found
621            */
622            public static Team[] findByGroupId_PrevAndNext(long teamId, long groupId,
623                    OrderByComparator<Team> orderByComparator)
624                    throws com.liferay.portal.kernel.exception.NoSuchTeamException {
625                    return getPersistence()
626                                       .findByGroupId_PrevAndNext(teamId, groupId, orderByComparator);
627            }
628    
629            /**
630            * Returns all the teams that the user has permission to view where groupId = &#63;.
631            *
632            * @param groupId the group ID
633            * @return the matching teams that the user has permission to view
634            */
635            public static List<Team> filterFindByGroupId(long groupId) {
636                    return getPersistence().filterFindByGroupId(groupId);
637            }
638    
639            /**
640            * Returns a range of all the teams that the user has permission to view where groupId = &#63;.
641            *
642            * <p>
643            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link TeamModelImpl}. 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.
644            * </p>
645            *
646            * @param groupId the group ID
647            * @param start the lower bound of the range of teams
648            * @param end the upper bound of the range of teams (not inclusive)
649            * @return the range of matching teams that the user has permission to view
650            */
651            public static List<Team> filterFindByGroupId(long groupId, int start,
652                    int end) {
653                    return getPersistence().filterFindByGroupId(groupId, start, end);
654            }
655    
656            /**
657            * Returns an ordered range of all the teams that the user has permissions to view where groupId = &#63;.
658            *
659            * <p>
660            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link TeamModelImpl}. 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.
661            * </p>
662            *
663            * @param groupId the group ID
664            * @param start the lower bound of the range of teams
665            * @param end the upper bound of the range of teams (not inclusive)
666            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
667            * @return the ordered range of matching teams that the user has permission to view
668            */
669            public static List<Team> filterFindByGroupId(long groupId, int start,
670                    int end, OrderByComparator<Team> orderByComparator) {
671                    return getPersistence()
672                                       .filterFindByGroupId(groupId, start, end, orderByComparator);
673            }
674    
675            /**
676            * Returns the teams before and after the current team in the ordered set of teams that the user has permission to view where groupId = &#63;.
677            *
678            * @param teamId the primary key of the current team
679            * @param groupId the group ID
680            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
681            * @return the previous, current, and next team
682            * @throws NoSuchTeamException if a team with the primary key could not be found
683            */
684            public static Team[] filterFindByGroupId_PrevAndNext(long teamId,
685                    long groupId, OrderByComparator<Team> orderByComparator)
686                    throws com.liferay.portal.kernel.exception.NoSuchTeamException {
687                    return getPersistence()
688                                       .filterFindByGroupId_PrevAndNext(teamId, groupId,
689                            orderByComparator);
690            }
691    
692            /**
693            * Removes all the teams where groupId = &#63; from the database.
694            *
695            * @param groupId the group ID
696            */
697            public static void removeByGroupId(long groupId) {
698                    getPersistence().removeByGroupId(groupId);
699            }
700    
701            /**
702            * Returns the number of teams where groupId = &#63;.
703            *
704            * @param groupId the group ID
705            * @return the number of matching teams
706            */
707            public static int countByGroupId(long groupId) {
708                    return getPersistence().countByGroupId(groupId);
709            }
710    
711            /**
712            * Returns the number of teams that the user has permission to view where groupId = &#63;.
713            *
714            * @param groupId the group ID
715            * @return the number of matching teams that the user has permission to view
716            */
717            public static int filterCountByGroupId(long groupId) {
718                    return getPersistence().filterCountByGroupId(groupId);
719            }
720    
721            /**
722            * Returns the team where groupId = &#63; and name = &#63; or throws a {@link NoSuchTeamException} if it could not be found.
723            *
724            * @param groupId the group ID
725            * @param name the name
726            * @return the matching team
727            * @throws NoSuchTeamException if a matching team could not be found
728            */
729            public static Team findByG_N(long groupId, java.lang.String name)
730                    throws com.liferay.portal.kernel.exception.NoSuchTeamException {
731                    return getPersistence().findByG_N(groupId, name);
732            }
733    
734            /**
735            * Returns the team where groupId = &#63; and name = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
736            *
737            * @param groupId the group ID
738            * @param name the name
739            * @return the matching team, or <code>null</code> if a matching team could not be found
740            */
741            public static Team fetchByG_N(long groupId, java.lang.String name) {
742                    return getPersistence().fetchByG_N(groupId, name);
743            }
744    
745            /**
746            * Returns the team where groupId = &#63; and name = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
747            *
748            * @param groupId the group ID
749            * @param name the name
750            * @param retrieveFromCache whether to retrieve from the finder cache
751            * @return the matching team, or <code>null</code> if a matching team could not be found
752            */
753            public static Team fetchByG_N(long groupId, java.lang.String name,
754                    boolean retrieveFromCache) {
755                    return getPersistence().fetchByG_N(groupId, name, retrieveFromCache);
756            }
757    
758            /**
759            * Removes the team where groupId = &#63; and name = &#63; from the database.
760            *
761            * @param groupId the group ID
762            * @param name the name
763            * @return the team that was removed
764            */
765            public static Team removeByG_N(long groupId, java.lang.String name)
766                    throws com.liferay.portal.kernel.exception.NoSuchTeamException {
767                    return getPersistence().removeByG_N(groupId, name);
768            }
769    
770            /**
771            * Returns the number of teams where groupId = &#63; and name = &#63;.
772            *
773            * @param groupId the group ID
774            * @param name the name
775            * @return the number of matching teams
776            */
777            public static int countByG_N(long groupId, java.lang.String name) {
778                    return getPersistence().countByG_N(groupId, name);
779            }
780    
781            /**
782            * Caches the team in the entity cache if it is enabled.
783            *
784            * @param team the team
785            */
786            public static void cacheResult(Team team) {
787                    getPersistence().cacheResult(team);
788            }
789    
790            /**
791            * Caches the teams in the entity cache if it is enabled.
792            *
793            * @param teams the teams
794            */
795            public static void cacheResult(List<Team> teams) {
796                    getPersistence().cacheResult(teams);
797            }
798    
799            /**
800            * Creates a new team with the primary key. Does not add the team to the database.
801            *
802            * @param teamId the primary key for the new team
803            * @return the new team
804            */
805            public static Team create(long teamId) {
806                    return getPersistence().create(teamId);
807            }
808    
809            /**
810            * Removes the team with the primary key from the database. Also notifies the appropriate model listeners.
811            *
812            * @param teamId the primary key of the team
813            * @return the team that was removed
814            * @throws NoSuchTeamException if a team with the primary key could not be found
815            */
816            public static Team remove(long teamId)
817                    throws com.liferay.portal.kernel.exception.NoSuchTeamException {
818                    return getPersistence().remove(teamId);
819            }
820    
821            public static Team updateImpl(Team team) {
822                    return getPersistence().updateImpl(team);
823            }
824    
825            /**
826            * Returns the team with the primary key or throws a {@link NoSuchTeamException} if it could not be found.
827            *
828            * @param teamId the primary key of the team
829            * @return the team
830            * @throws NoSuchTeamException if a team with the primary key could not be found
831            */
832            public static Team findByPrimaryKey(long teamId)
833                    throws com.liferay.portal.kernel.exception.NoSuchTeamException {
834                    return getPersistence().findByPrimaryKey(teamId);
835            }
836    
837            /**
838            * Returns the team with the primary key or returns <code>null</code> if it could not be found.
839            *
840            * @param teamId the primary key of the team
841            * @return the team, or <code>null</code> if a team with the primary key could not be found
842            */
843            public static Team fetchByPrimaryKey(long teamId) {
844                    return getPersistence().fetchByPrimaryKey(teamId);
845            }
846    
847            public static java.util.Map<java.io.Serializable, Team> fetchByPrimaryKeys(
848                    java.util.Set<java.io.Serializable> primaryKeys) {
849                    return getPersistence().fetchByPrimaryKeys(primaryKeys);
850            }
851    
852            /**
853            * Returns all the teams.
854            *
855            * @return the teams
856            */
857            public static List<Team> findAll() {
858                    return getPersistence().findAll();
859            }
860    
861            /**
862            * Returns a range of all the teams.
863            *
864            * <p>
865            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link TeamModelImpl}. 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.
866            * </p>
867            *
868            * @param start the lower bound of the range of teams
869            * @param end the upper bound of the range of teams (not inclusive)
870            * @return the range of teams
871            */
872            public static List<Team> findAll(int start, int end) {
873                    return getPersistence().findAll(start, end);
874            }
875    
876            /**
877            * Returns an ordered range of all the teams.
878            *
879            * <p>
880            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link TeamModelImpl}. 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.
881            * </p>
882            *
883            * @param start the lower bound of the range of teams
884            * @param end the upper bound of the range of teams (not inclusive)
885            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
886            * @return the ordered range of teams
887            */
888            public static List<Team> findAll(int start, int end,
889                    OrderByComparator<Team> orderByComparator) {
890                    return getPersistence().findAll(start, end, orderByComparator);
891            }
892    
893            /**
894            * Returns an ordered range of all the teams.
895            *
896            * <p>
897            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link TeamModelImpl}. 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.
898            * </p>
899            *
900            * @param start the lower bound of the range of teams
901            * @param end the upper bound of the range of teams (not inclusive)
902            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
903            * @param retrieveFromCache whether to retrieve from the finder cache
904            * @return the ordered range of teams
905            */
906            public static List<Team> findAll(int start, int end,
907                    OrderByComparator<Team> orderByComparator, boolean retrieveFromCache) {
908                    return getPersistence()
909                                       .findAll(start, end, orderByComparator, retrieveFromCache);
910            }
911    
912            /**
913            * Removes all the teams from the database.
914            */
915            public static void removeAll() {
916                    getPersistence().removeAll();
917            }
918    
919            /**
920            * Returns the number of teams.
921            *
922            * @return the number of teams
923            */
924            public static int countAll() {
925                    return getPersistence().countAll();
926            }
927    
928            /**
929            * Returns the primaryKeys of users associated with the team.
930            *
931            * @param pk the primary key of the team
932            * @return long[] of the primaryKeys of users associated with the team
933            */
934            public static long[] getUserPrimaryKeys(long pk) {
935                    return getPersistence().getUserPrimaryKeys(pk);
936            }
937    
938            /**
939            * Returns all the users associated with the team.
940            *
941            * @param pk the primary key of the team
942            * @return the users associated with the team
943            */
944            public static List<com.liferay.portal.kernel.model.User> getUsers(long pk) {
945                    return getPersistence().getUsers(pk);
946            }
947    
948            /**
949            * Returns a range of all the users associated with the team.
950            *
951            * <p>
952            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link TeamModelImpl}. 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.
953            * </p>
954            *
955            * @param pk the primary key of the team
956            * @param start the lower bound of the range of teams
957            * @param end the upper bound of the range of teams (not inclusive)
958            * @return the range of users associated with the team
959            */
960            public static List<com.liferay.portal.kernel.model.User> getUsers(long pk,
961                    int start, int end) {
962                    return getPersistence().getUsers(pk, start, end);
963            }
964    
965            /**
966            * Returns an ordered range of all the users associated with the team.
967            *
968            * <p>
969            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link TeamModelImpl}. 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.
970            * </p>
971            *
972            * @param pk the primary key of the team
973            * @param start the lower bound of the range of teams
974            * @param end the upper bound of the range of teams (not inclusive)
975            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
976            * @return the ordered range of users associated with the team
977            */
978            public static List<com.liferay.portal.kernel.model.User> getUsers(long pk,
979                    int start, int end,
980                    OrderByComparator<com.liferay.portal.kernel.model.User> orderByComparator) {
981                    return getPersistence().getUsers(pk, start, end, orderByComparator);
982            }
983    
984            /**
985            * Returns the number of users associated with the team.
986            *
987            * @param pk the primary key of the team
988            * @return the number of users associated with the team
989            */
990            public static int getUsersSize(long pk) {
991                    return getPersistence().getUsersSize(pk);
992            }
993    
994            /**
995            * Returns <code>true</code> if the user is associated with the team.
996            *
997            * @param pk the primary key of the team
998            * @param userPK the primary key of the user
999            * @return <code>true</code> if the user is associated with the team; <code>false</code> otherwise
1000            */
1001            public static boolean containsUser(long pk, long userPK) {
1002                    return getPersistence().containsUser(pk, userPK);
1003            }
1004    
1005            /**
1006            * Returns <code>true</code> if the team has any users associated with it.
1007            *
1008            * @param pk the primary key of the team to check for associations with users
1009            * @return <code>true</code> if the team has any users associated with it; <code>false</code> otherwise
1010            */
1011            public static boolean containsUsers(long pk) {
1012                    return getPersistence().containsUsers(pk);
1013            }
1014    
1015            /**
1016            * Adds an association between the team and the user. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1017            *
1018            * @param pk the primary key of the team
1019            * @param userPK the primary key of the user
1020            */
1021            public static void addUser(long pk, long userPK) {
1022                    getPersistence().addUser(pk, userPK);
1023            }
1024    
1025            /**
1026            * Adds an association between the team and the user. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1027            *
1028            * @param pk the primary key of the team
1029            * @param user the user
1030            */
1031            public static void addUser(long pk,
1032                    com.liferay.portal.kernel.model.User user) {
1033                    getPersistence().addUser(pk, user);
1034            }
1035    
1036            /**
1037            * Adds an association between the team and the users. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1038            *
1039            * @param pk the primary key of the team
1040            * @param userPKs the primary keys of the users
1041            */
1042            public static void addUsers(long pk, long[] userPKs) {
1043                    getPersistence().addUsers(pk, userPKs);
1044            }
1045    
1046            /**
1047            * Adds an association between the team and the users. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1048            *
1049            * @param pk the primary key of the team
1050            * @param users the users
1051            */
1052            public static void addUsers(long pk,
1053                    List<com.liferay.portal.kernel.model.User> users) {
1054                    getPersistence().addUsers(pk, users);
1055            }
1056    
1057            /**
1058            * Clears all associations between the team and its users. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1059            *
1060            * @param pk the primary key of the team to clear the associated users from
1061            */
1062            public static void clearUsers(long pk) {
1063                    getPersistence().clearUsers(pk);
1064            }
1065    
1066            /**
1067            * Removes the association between the team and the user. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1068            *
1069            * @param pk the primary key of the team
1070            * @param userPK the primary key of the user
1071            */
1072            public static void removeUser(long pk, long userPK) {
1073                    getPersistence().removeUser(pk, userPK);
1074            }
1075    
1076            /**
1077            * Removes the association between the team and the user. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1078            *
1079            * @param pk the primary key of the team
1080            * @param user the user
1081            */
1082            public static void removeUser(long pk,
1083                    com.liferay.portal.kernel.model.User user) {
1084                    getPersistence().removeUser(pk, user);
1085            }
1086    
1087            /**
1088            * Removes the association between the team and the users. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1089            *
1090            * @param pk the primary key of the team
1091            * @param userPKs the primary keys of the users
1092            */
1093            public static void removeUsers(long pk, long[] userPKs) {
1094                    getPersistence().removeUsers(pk, userPKs);
1095            }
1096    
1097            /**
1098            * Removes the association between the team and the users. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1099            *
1100            * @param pk the primary key of the team
1101            * @param users the users
1102            */
1103            public static void removeUsers(long pk,
1104                    List<com.liferay.portal.kernel.model.User> users) {
1105                    getPersistence().removeUsers(pk, users);
1106            }
1107    
1108            /**
1109            * Sets the users associated with the team, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1110            *
1111            * @param pk the primary key of the team
1112            * @param userPKs the primary keys of the users to be associated with the team
1113            */
1114            public static void setUsers(long pk, long[] userPKs) {
1115                    getPersistence().setUsers(pk, userPKs);
1116            }
1117    
1118            /**
1119            * Sets the users associated with the team, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1120            *
1121            * @param pk the primary key of the team
1122            * @param users the users to be associated with the team
1123            */
1124            public static void setUsers(long pk,
1125                    List<com.liferay.portal.kernel.model.User> users) {
1126                    getPersistence().setUsers(pk, users);
1127            }
1128    
1129            /**
1130            * Returns the primaryKeys of user groups associated with the team.
1131            *
1132            * @param pk the primary key of the team
1133            * @return long[] of the primaryKeys of user groups associated with the team
1134            */
1135            public static long[] getUserGroupPrimaryKeys(long pk) {
1136                    return getPersistence().getUserGroupPrimaryKeys(pk);
1137            }
1138    
1139            /**
1140            * Returns all the user groups associated with the team.
1141            *
1142            * @param pk the primary key of the team
1143            * @return the user groups associated with the team
1144            */
1145            public static List<com.liferay.portal.kernel.model.UserGroup> getUserGroups(
1146                    long pk) {
1147                    return getPersistence().getUserGroups(pk);
1148            }
1149    
1150            /**
1151            * Returns a range of all the user groups associated with the team.
1152            *
1153            * <p>
1154            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link TeamModelImpl}. 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.
1155            * </p>
1156            *
1157            * @param pk the primary key of the team
1158            * @param start the lower bound of the range of teams
1159            * @param end the upper bound of the range of teams (not inclusive)
1160            * @return the range of user groups associated with the team
1161            */
1162            public static List<com.liferay.portal.kernel.model.UserGroup> getUserGroups(
1163                    long pk, int start, int end) {
1164                    return getPersistence().getUserGroups(pk, start, end);
1165            }
1166    
1167            /**
1168            * Returns an ordered range of all the user groups associated with the team.
1169            *
1170            * <p>
1171            * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link TeamModelImpl}. 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.
1172            * </p>
1173            *
1174            * @param pk the primary key of the team
1175            * @param start the lower bound of the range of teams
1176            * @param end the upper bound of the range of teams (not inclusive)
1177            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1178            * @return the ordered range of user groups associated with the team
1179            */
1180            public static List<com.liferay.portal.kernel.model.UserGroup> getUserGroups(
1181                    long pk, int start, int end,
1182                    OrderByComparator<com.liferay.portal.kernel.model.UserGroup> orderByComparator) {
1183                    return getPersistence().getUserGroups(pk, start, end, orderByComparator);
1184            }
1185    
1186            /**
1187            * Returns the number of user groups associated with the team.
1188            *
1189            * @param pk the primary key of the team
1190            * @return the number of user groups associated with the team
1191            */
1192            public static int getUserGroupsSize(long pk) {
1193                    return getPersistence().getUserGroupsSize(pk);
1194            }
1195    
1196            /**
1197            * Returns <code>true</code> if the user group is associated with the team.
1198            *
1199            * @param pk the primary key of the team
1200            * @param userGroupPK the primary key of the user group
1201            * @return <code>true</code> if the user group is associated with the team; <code>false</code> otherwise
1202            */
1203            public static boolean containsUserGroup(long pk, long userGroupPK) {
1204                    return getPersistence().containsUserGroup(pk, userGroupPK);
1205            }
1206    
1207            /**
1208            * Returns <code>true</code> if the team has any user groups associated with it.
1209            *
1210            * @param pk the primary key of the team to check for associations with user groups
1211            * @return <code>true</code> if the team has any user groups associated with it; <code>false</code> otherwise
1212            */
1213            public static boolean containsUserGroups(long pk) {
1214                    return getPersistence().containsUserGroups(pk);
1215            }
1216    
1217            /**
1218            * Adds an association between the team and the user group. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1219            *
1220            * @param pk the primary key of the team
1221            * @param userGroupPK the primary key of the user group
1222            */
1223            public static void addUserGroup(long pk, long userGroupPK) {
1224                    getPersistence().addUserGroup(pk, userGroupPK);
1225            }
1226    
1227            /**
1228            * Adds an association between the team and the user group. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1229            *
1230            * @param pk the primary key of the team
1231            * @param userGroup the user group
1232            */
1233            public static void addUserGroup(long pk,
1234                    com.liferay.portal.kernel.model.UserGroup userGroup) {
1235                    getPersistence().addUserGroup(pk, userGroup);
1236            }
1237    
1238            /**
1239            * Adds an association between the team and the user groups. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1240            *
1241            * @param pk the primary key of the team
1242            * @param userGroupPKs the primary keys of the user groups
1243            */
1244            public static void addUserGroups(long pk, long[] userGroupPKs) {
1245                    getPersistence().addUserGroups(pk, userGroupPKs);
1246            }
1247    
1248            /**
1249            * Adds an association between the team and the user groups. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1250            *
1251            * @param pk the primary key of the team
1252            * @param userGroups the user groups
1253            */
1254            public static void addUserGroups(long pk,
1255                    List<com.liferay.portal.kernel.model.UserGroup> userGroups) {
1256                    getPersistence().addUserGroups(pk, userGroups);
1257            }
1258    
1259            /**
1260            * Clears all associations between the team and its user groups. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1261            *
1262            * @param pk the primary key of the team to clear the associated user groups from
1263            */
1264            public static void clearUserGroups(long pk) {
1265                    getPersistence().clearUserGroups(pk);
1266            }
1267    
1268            /**
1269            * Removes the association between the team and the user group. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1270            *
1271            * @param pk the primary key of the team
1272            * @param userGroupPK the primary key of the user group
1273            */
1274            public static void removeUserGroup(long pk, long userGroupPK) {
1275                    getPersistence().removeUserGroup(pk, userGroupPK);
1276            }
1277    
1278            /**
1279            * Removes the association between the team and the user group. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1280            *
1281            * @param pk the primary key of the team
1282            * @param userGroup the user group
1283            */
1284            public static void removeUserGroup(long pk,
1285                    com.liferay.portal.kernel.model.UserGroup userGroup) {
1286                    getPersistence().removeUserGroup(pk, userGroup);
1287            }
1288    
1289            /**
1290            * Removes the association between the team and the user groups. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1291            *
1292            * @param pk the primary key of the team
1293            * @param userGroupPKs the primary keys of the user groups
1294            */
1295            public static void removeUserGroups(long pk, long[] userGroupPKs) {
1296                    getPersistence().removeUserGroups(pk, userGroupPKs);
1297            }
1298    
1299            /**
1300            * Removes the association between the team and the user groups. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1301            *
1302            * @param pk the primary key of the team
1303            * @param userGroups the user groups
1304            */
1305            public static void removeUserGroups(long pk,
1306                    List<com.liferay.portal.kernel.model.UserGroup> userGroups) {
1307                    getPersistence().removeUserGroups(pk, userGroups);
1308            }
1309    
1310            /**
1311            * Sets the user groups associated with the team, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1312            *
1313            * @param pk the primary key of the team
1314            * @param userGroupPKs the primary keys of the user groups to be associated with the team
1315            */
1316            public static void setUserGroups(long pk, long[] userGroupPKs) {
1317                    getPersistence().setUserGroups(pk, userGroupPKs);
1318            }
1319    
1320            /**
1321            * Sets the user groups associated with the team, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1322            *
1323            * @param pk the primary key of the team
1324            * @param userGroups the user groups to be associated with the team
1325            */
1326            public static void setUserGroups(long pk,
1327                    List<com.liferay.portal.kernel.model.UserGroup> userGroups) {
1328                    getPersistence().setUserGroups(pk, userGroups);
1329            }
1330    
1331            public static java.util.Set<java.lang.String> getBadColumnNames() {
1332                    return getPersistence().getBadColumnNames();
1333            }
1334    
1335            public static TeamPersistence getPersistence() {
1336                    if (_persistence == null) {
1337                            _persistence = (TeamPersistence)PortalBeanLocatorUtil.locate(TeamPersistence.class.getName());
1338    
1339                            ReferenceRegistry.registerReference(TeamUtil.class, "_persistence");
1340                    }
1341    
1342                    return _persistence;
1343            }
1344    
1345            private static TeamPersistence _persistence;
1346    }