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.exception.NoSuchUserException;
020    import com.liferay.portal.kernel.model.User;
021    
022    import java.util.Date;
023    
024    /**
025     * The persistence interface for the user service.
026     *
027     * <p>
028     * Caching information and settings can be found in <code>portal.properties</code>
029     * </p>
030     *
031     * @author Brian Wing Shun Chan
032     * @see com.liferay.portal.service.persistence.impl.UserPersistenceImpl
033     * @see UserUtil
034     * @generated
035     */
036    @ProviderType
037    public interface UserPersistence extends BasePersistence<User> {
038            /*
039             * NOTE FOR DEVELOPERS:
040             *
041             * Never modify or reference this interface directly. Always use {@link UserUtil} to access the user persistence. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this interface.
042             */
043    
044            /**
045            * Returns all the users where uuid = &#63;.
046            *
047            * @param uuid the uuid
048            * @return the matching users
049            */
050            public java.util.List<User> findByUuid(java.lang.String uuid);
051    
052            /**
053            * Returns a range of all the users where uuid = &#63;.
054            *
055            * <p>
056            * 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 UserModelImpl}. 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.
057            * </p>
058            *
059            * @param uuid the uuid
060            * @param start the lower bound of the range of users
061            * @param end the upper bound of the range of users (not inclusive)
062            * @return the range of matching users
063            */
064            public java.util.List<User> findByUuid(java.lang.String uuid, int start,
065                    int end);
066    
067            /**
068            * Returns an ordered range of all the users where uuid = &#63;.
069            *
070            * <p>
071            * 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 UserModelImpl}. 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.
072            * </p>
073            *
074            * @param uuid the uuid
075            * @param start the lower bound of the range of users
076            * @param end the upper bound of the range of users (not inclusive)
077            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
078            * @return the ordered range of matching users
079            */
080            public java.util.List<User> findByUuid(java.lang.String uuid, int start,
081                    int end,
082                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
083    
084            /**
085            * Returns an ordered range of all the users where uuid = &#63;.
086            *
087            * <p>
088            * 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 UserModelImpl}. 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.
089            * </p>
090            *
091            * @param uuid the uuid
092            * @param start the lower bound of the range of users
093            * @param end the upper bound of the range of users (not inclusive)
094            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
095            * @param retrieveFromCache whether to retrieve from the finder cache
096            * @return the ordered range of matching users
097            */
098            public java.util.List<User> findByUuid(java.lang.String uuid, int start,
099                    int end,
100                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator,
101                    boolean retrieveFromCache);
102    
103            /**
104            * Returns the first user in the ordered set where uuid = &#63;.
105            *
106            * @param uuid the uuid
107            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
108            * @return the first matching user
109            * @throws NoSuchUserException if a matching user could not be found
110            */
111            public User findByUuid_First(java.lang.String uuid,
112                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
113                    throws NoSuchUserException;
114    
115            /**
116            * Returns the first user in the ordered set where uuid = &#63;.
117            *
118            * @param uuid the uuid
119            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
120            * @return the first matching user, or <code>null</code> if a matching user could not be found
121            */
122            public User fetchByUuid_First(java.lang.String uuid,
123                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
124    
125            /**
126            * Returns the last user in the ordered set where uuid = &#63;.
127            *
128            * @param uuid the uuid
129            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
130            * @return the last matching user
131            * @throws NoSuchUserException if a matching user could not be found
132            */
133            public User findByUuid_Last(java.lang.String uuid,
134                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
135                    throws NoSuchUserException;
136    
137            /**
138            * Returns the last user in the ordered set where uuid = &#63;.
139            *
140            * @param uuid the uuid
141            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
142            * @return the last matching user, or <code>null</code> if a matching user could not be found
143            */
144            public User fetchByUuid_Last(java.lang.String uuid,
145                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
146    
147            /**
148            * Returns the users before and after the current user in the ordered set where uuid = &#63;.
149            *
150            * @param userId the primary key of the current user
151            * @param uuid the uuid
152            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
153            * @return the previous, current, and next user
154            * @throws NoSuchUserException if a user with the primary key could not be found
155            */
156            public User[] findByUuid_PrevAndNext(long userId, java.lang.String uuid,
157                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
158                    throws NoSuchUserException;
159    
160            /**
161            * Removes all the users where uuid = &#63; from the database.
162            *
163            * @param uuid the uuid
164            */
165            public void removeByUuid(java.lang.String uuid);
166    
167            /**
168            * Returns the number of users where uuid = &#63;.
169            *
170            * @param uuid the uuid
171            * @return the number of matching users
172            */
173            public int countByUuid(java.lang.String uuid);
174    
175            /**
176            * Returns all the users where uuid = &#63; and companyId = &#63;.
177            *
178            * @param uuid the uuid
179            * @param companyId the company ID
180            * @return the matching users
181            */
182            public java.util.List<User> findByUuid_C(java.lang.String uuid,
183                    long companyId);
184    
185            /**
186            * Returns a range of all the users where uuid = &#63; and companyId = &#63;.
187            *
188            * <p>
189            * 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 UserModelImpl}. 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.
190            * </p>
191            *
192            * @param uuid the uuid
193            * @param companyId the company ID
194            * @param start the lower bound of the range of users
195            * @param end the upper bound of the range of users (not inclusive)
196            * @return the range of matching users
197            */
198            public java.util.List<User> findByUuid_C(java.lang.String uuid,
199                    long companyId, int start, int end);
200    
201            /**
202            * Returns an ordered range of all the users where uuid = &#63; and companyId = &#63;.
203            *
204            * <p>
205            * 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 UserModelImpl}. 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.
206            * </p>
207            *
208            * @param uuid the uuid
209            * @param companyId the company ID
210            * @param start the lower bound of the range of users
211            * @param end the upper bound of the range of users (not inclusive)
212            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
213            * @return the ordered range of matching users
214            */
215            public java.util.List<User> findByUuid_C(java.lang.String uuid,
216                    long companyId, int start, int end,
217                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
218    
219            /**
220            * Returns an ordered range of all the users where uuid = &#63; and companyId = &#63;.
221            *
222            * <p>
223            * 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 UserModelImpl}. 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.
224            * </p>
225            *
226            * @param uuid the uuid
227            * @param companyId the company ID
228            * @param start the lower bound of the range of users
229            * @param end the upper bound of the range of users (not inclusive)
230            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
231            * @param retrieveFromCache whether to retrieve from the finder cache
232            * @return the ordered range of matching users
233            */
234            public java.util.List<User> findByUuid_C(java.lang.String uuid,
235                    long companyId, int start, int end,
236                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator,
237                    boolean retrieveFromCache);
238    
239            /**
240            * Returns the first user in the ordered set where uuid = &#63; and companyId = &#63;.
241            *
242            * @param uuid the uuid
243            * @param companyId the company ID
244            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
245            * @return the first matching user
246            * @throws NoSuchUserException if a matching user could not be found
247            */
248            public User findByUuid_C_First(java.lang.String uuid, long companyId,
249                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
250                    throws NoSuchUserException;
251    
252            /**
253            * Returns the first user in the ordered set where uuid = &#63; and companyId = &#63;.
254            *
255            * @param uuid the uuid
256            * @param companyId the company ID
257            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
258            * @return the first matching user, or <code>null</code> if a matching user could not be found
259            */
260            public User fetchByUuid_C_First(java.lang.String uuid, long companyId,
261                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
262    
263            /**
264            * Returns the last user in the ordered set where uuid = &#63; and companyId = &#63;.
265            *
266            * @param uuid the uuid
267            * @param companyId the company ID
268            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
269            * @return the last matching user
270            * @throws NoSuchUserException if a matching user could not be found
271            */
272            public User findByUuid_C_Last(java.lang.String uuid, long companyId,
273                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
274                    throws NoSuchUserException;
275    
276            /**
277            * Returns the last user in the ordered set where uuid = &#63; and companyId = &#63;.
278            *
279            * @param uuid the uuid
280            * @param companyId the company ID
281            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
282            * @return the last matching user, or <code>null</code> if a matching user could not be found
283            */
284            public User fetchByUuid_C_Last(java.lang.String uuid, long companyId,
285                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
286    
287            /**
288            * Returns the users before and after the current user in the ordered set where uuid = &#63; and companyId = &#63;.
289            *
290            * @param userId the primary key of the current user
291            * @param uuid the uuid
292            * @param companyId the company ID
293            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
294            * @return the previous, current, and next user
295            * @throws NoSuchUserException if a user with the primary key could not be found
296            */
297            public User[] findByUuid_C_PrevAndNext(long userId, java.lang.String uuid,
298                    long companyId,
299                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
300                    throws NoSuchUserException;
301    
302            /**
303            * Removes all the users where uuid = &#63; and companyId = &#63; from the database.
304            *
305            * @param uuid the uuid
306            * @param companyId the company ID
307            */
308            public void removeByUuid_C(java.lang.String uuid, long companyId);
309    
310            /**
311            * Returns the number of users where uuid = &#63; and companyId = &#63;.
312            *
313            * @param uuid the uuid
314            * @param companyId the company ID
315            * @return the number of matching users
316            */
317            public int countByUuid_C(java.lang.String uuid, long companyId);
318    
319            /**
320            * Returns all the users where companyId = &#63;.
321            *
322            * @param companyId the company ID
323            * @return the matching users
324            */
325            public java.util.List<User> findByCompanyId(long companyId);
326    
327            /**
328            * Returns a range of all the users where companyId = &#63;.
329            *
330            * <p>
331            * 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 UserModelImpl}. 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.
332            * </p>
333            *
334            * @param companyId the company ID
335            * @param start the lower bound of the range of users
336            * @param end the upper bound of the range of users (not inclusive)
337            * @return the range of matching users
338            */
339            public java.util.List<User> findByCompanyId(long companyId, int start,
340                    int end);
341    
342            /**
343            * Returns an ordered range of all the users where companyId = &#63;.
344            *
345            * <p>
346            * 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 UserModelImpl}. 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.
347            * </p>
348            *
349            * @param companyId the company ID
350            * @param start the lower bound of the range of users
351            * @param end the upper bound of the range of users (not inclusive)
352            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
353            * @return the ordered range of matching users
354            */
355            public java.util.List<User> findByCompanyId(long companyId, int start,
356                    int end,
357                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
358    
359            /**
360            * Returns an ordered range of all the users where companyId = &#63;.
361            *
362            * <p>
363            * 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 UserModelImpl}. 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.
364            * </p>
365            *
366            * @param companyId the company ID
367            * @param start the lower bound of the range of users
368            * @param end the upper bound of the range of users (not inclusive)
369            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
370            * @param retrieveFromCache whether to retrieve from the finder cache
371            * @return the ordered range of matching users
372            */
373            public java.util.List<User> findByCompanyId(long companyId, int start,
374                    int end,
375                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator,
376                    boolean retrieveFromCache);
377    
378            /**
379            * Returns the first user in the ordered set where companyId = &#63;.
380            *
381            * @param companyId the company ID
382            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
383            * @return the first matching user
384            * @throws NoSuchUserException if a matching user could not be found
385            */
386            public User findByCompanyId_First(long companyId,
387                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
388                    throws NoSuchUserException;
389    
390            /**
391            * Returns the first user in the ordered set where companyId = &#63;.
392            *
393            * @param companyId the company ID
394            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
395            * @return the first matching user, or <code>null</code> if a matching user could not be found
396            */
397            public User fetchByCompanyId_First(long companyId,
398                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
399    
400            /**
401            * Returns the last user in the ordered set where companyId = &#63;.
402            *
403            * @param companyId the company ID
404            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
405            * @return the last matching user
406            * @throws NoSuchUserException if a matching user could not be found
407            */
408            public User findByCompanyId_Last(long companyId,
409                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
410                    throws NoSuchUserException;
411    
412            /**
413            * Returns the last user in the ordered set where companyId = &#63;.
414            *
415            * @param companyId the company ID
416            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
417            * @return the last matching user, or <code>null</code> if a matching user could not be found
418            */
419            public User fetchByCompanyId_Last(long companyId,
420                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
421    
422            /**
423            * Returns the users before and after the current user in the ordered set where companyId = &#63;.
424            *
425            * @param userId the primary key of the current user
426            * @param companyId the company ID
427            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
428            * @return the previous, current, and next user
429            * @throws NoSuchUserException if a user with the primary key could not be found
430            */
431            public User[] findByCompanyId_PrevAndNext(long userId, long companyId,
432                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
433                    throws NoSuchUserException;
434    
435            /**
436            * Removes all the users where companyId = &#63; from the database.
437            *
438            * @param companyId the company ID
439            */
440            public void removeByCompanyId(long companyId);
441    
442            /**
443            * Returns the number of users where companyId = &#63;.
444            *
445            * @param companyId the company ID
446            * @return the number of matching users
447            */
448            public int countByCompanyId(long companyId);
449    
450            /**
451            * Returns the user where contactId = &#63; or throws a {@link NoSuchUserException} if it could not be found.
452            *
453            * @param contactId the contact ID
454            * @return the matching user
455            * @throws NoSuchUserException if a matching user could not be found
456            */
457            public User findByContactId(long contactId) throws NoSuchUserException;
458    
459            /**
460            * Returns the user where contactId = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
461            *
462            * @param contactId the contact ID
463            * @return the matching user, or <code>null</code> if a matching user could not be found
464            */
465            public User fetchByContactId(long contactId);
466    
467            /**
468            * Returns the user where contactId = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
469            *
470            * @param contactId the contact ID
471            * @param retrieveFromCache whether to retrieve from the finder cache
472            * @return the matching user, or <code>null</code> if a matching user could not be found
473            */
474            public User fetchByContactId(long contactId, boolean retrieveFromCache);
475    
476            /**
477            * Removes the user where contactId = &#63; from the database.
478            *
479            * @param contactId the contact ID
480            * @return the user that was removed
481            */
482            public User removeByContactId(long contactId) throws NoSuchUserException;
483    
484            /**
485            * Returns the number of users where contactId = &#63;.
486            *
487            * @param contactId the contact ID
488            * @return the number of matching users
489            */
490            public int countByContactId(long contactId);
491    
492            /**
493            * Returns all the users where emailAddress = &#63;.
494            *
495            * @param emailAddress the email address
496            * @return the matching users
497            */
498            public java.util.List<User> findByEmailAddress(
499                    java.lang.String emailAddress);
500    
501            /**
502            * Returns a range of all the users where emailAddress = &#63;.
503            *
504            * <p>
505            * 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 UserModelImpl}. 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.
506            * </p>
507            *
508            * @param emailAddress the email address
509            * @param start the lower bound of the range of users
510            * @param end the upper bound of the range of users (not inclusive)
511            * @return the range of matching users
512            */
513            public java.util.List<User> findByEmailAddress(
514                    java.lang.String emailAddress, int start, int end);
515    
516            /**
517            * Returns an ordered range of all the users where emailAddress = &#63;.
518            *
519            * <p>
520            * 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 UserModelImpl}. 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.
521            * </p>
522            *
523            * @param emailAddress the email address
524            * @param start the lower bound of the range of users
525            * @param end the upper bound of the range of users (not inclusive)
526            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
527            * @return the ordered range of matching users
528            */
529            public java.util.List<User> findByEmailAddress(
530                    java.lang.String emailAddress, int start, int end,
531                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
532    
533            /**
534            * Returns an ordered range of all the users where emailAddress = &#63;.
535            *
536            * <p>
537            * 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 UserModelImpl}. 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.
538            * </p>
539            *
540            * @param emailAddress the email address
541            * @param start the lower bound of the range of users
542            * @param end the upper bound of the range of users (not inclusive)
543            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
544            * @param retrieveFromCache whether to retrieve from the finder cache
545            * @return the ordered range of matching users
546            */
547            public java.util.List<User> findByEmailAddress(
548                    java.lang.String emailAddress, int start, int end,
549                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator,
550                    boolean retrieveFromCache);
551    
552            /**
553            * Returns the first user in the ordered set where emailAddress = &#63;.
554            *
555            * @param emailAddress the email address
556            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
557            * @return the first matching user
558            * @throws NoSuchUserException if a matching user could not be found
559            */
560            public User findByEmailAddress_First(java.lang.String emailAddress,
561                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
562                    throws NoSuchUserException;
563    
564            /**
565            * Returns the first user in the ordered set where emailAddress = &#63;.
566            *
567            * @param emailAddress the email address
568            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
569            * @return the first matching user, or <code>null</code> if a matching user could not be found
570            */
571            public User fetchByEmailAddress_First(java.lang.String emailAddress,
572                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
573    
574            /**
575            * Returns the last user in the ordered set where emailAddress = &#63;.
576            *
577            * @param emailAddress the email address
578            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
579            * @return the last matching user
580            * @throws NoSuchUserException if a matching user could not be found
581            */
582            public User findByEmailAddress_Last(java.lang.String emailAddress,
583                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
584                    throws NoSuchUserException;
585    
586            /**
587            * Returns the last user in the ordered set where emailAddress = &#63;.
588            *
589            * @param emailAddress the email address
590            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
591            * @return the last matching user, or <code>null</code> if a matching user could not be found
592            */
593            public User fetchByEmailAddress_Last(java.lang.String emailAddress,
594                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
595    
596            /**
597            * Returns the users before and after the current user in the ordered set where emailAddress = &#63;.
598            *
599            * @param userId the primary key of the current user
600            * @param emailAddress the email address
601            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
602            * @return the previous, current, and next user
603            * @throws NoSuchUserException if a user with the primary key could not be found
604            */
605            public User[] findByEmailAddress_PrevAndNext(long userId,
606                    java.lang.String emailAddress,
607                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
608                    throws NoSuchUserException;
609    
610            /**
611            * Removes all the users where emailAddress = &#63; from the database.
612            *
613            * @param emailAddress the email address
614            */
615            public void removeByEmailAddress(java.lang.String emailAddress);
616    
617            /**
618            * Returns the number of users where emailAddress = &#63;.
619            *
620            * @param emailAddress the email address
621            * @return the number of matching users
622            */
623            public int countByEmailAddress(java.lang.String emailAddress);
624    
625            /**
626            * Returns the user where portraitId = &#63; or throws a {@link NoSuchUserException} if it could not be found.
627            *
628            * @param portraitId the portrait ID
629            * @return the matching user
630            * @throws NoSuchUserException if a matching user could not be found
631            */
632            public User findByPortraitId(long portraitId) throws NoSuchUserException;
633    
634            /**
635            * Returns the user where portraitId = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
636            *
637            * @param portraitId the portrait ID
638            * @return the matching user, or <code>null</code> if a matching user could not be found
639            */
640            public User fetchByPortraitId(long portraitId);
641    
642            /**
643            * Returns the user where portraitId = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
644            *
645            * @param portraitId the portrait ID
646            * @param retrieveFromCache whether to retrieve from the finder cache
647            * @return the matching user, or <code>null</code> if a matching user could not be found
648            */
649            public User fetchByPortraitId(long portraitId, boolean retrieveFromCache);
650    
651            /**
652            * Removes the user where portraitId = &#63; from the database.
653            *
654            * @param portraitId the portrait ID
655            * @return the user that was removed
656            */
657            public User removeByPortraitId(long portraitId) throws NoSuchUserException;
658    
659            /**
660            * Returns the number of users where portraitId = &#63;.
661            *
662            * @param portraitId the portrait ID
663            * @return the number of matching users
664            */
665            public int countByPortraitId(long portraitId);
666    
667            /**
668            * Returns the user where companyId = &#63; and userId = &#63; or throws a {@link NoSuchUserException} if it could not be found.
669            *
670            * @param companyId the company ID
671            * @param userId the user ID
672            * @return the matching user
673            * @throws NoSuchUserException if a matching user could not be found
674            */
675            public User findByC_U(long companyId, long userId)
676                    throws NoSuchUserException;
677    
678            /**
679            * Returns the user where companyId = &#63; and userId = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
680            *
681            * @param companyId the company ID
682            * @param userId the user ID
683            * @return the matching user, or <code>null</code> if a matching user could not be found
684            */
685            public User fetchByC_U(long companyId, long userId);
686    
687            /**
688            * Returns the user where companyId = &#63; and userId = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
689            *
690            * @param companyId the company ID
691            * @param userId the user ID
692            * @param retrieveFromCache whether to retrieve from the finder cache
693            * @return the matching user, or <code>null</code> if a matching user could not be found
694            */
695            public User fetchByC_U(long companyId, long userId,
696                    boolean retrieveFromCache);
697    
698            /**
699            * Removes the user where companyId = &#63; and userId = &#63; from the database.
700            *
701            * @param companyId the company ID
702            * @param userId the user ID
703            * @return the user that was removed
704            */
705            public User removeByC_U(long companyId, long userId)
706                    throws NoSuchUserException;
707    
708            /**
709            * Returns the number of users where companyId = &#63; and userId = &#63;.
710            *
711            * @param companyId the company ID
712            * @param userId the user ID
713            * @return the number of matching users
714            */
715            public int countByC_U(long companyId, long userId);
716    
717            /**
718            * Returns all the users where companyId = &#63; and createDate = &#63;.
719            *
720            * @param companyId the company ID
721            * @param createDate the create date
722            * @return the matching users
723            */
724            public java.util.List<User> findByC_CD(long companyId, Date createDate);
725    
726            /**
727            * Returns a range of all the users where companyId = &#63; and createDate = &#63;.
728            *
729            * <p>
730            * 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 UserModelImpl}. 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.
731            * </p>
732            *
733            * @param companyId the company ID
734            * @param createDate the create date
735            * @param start the lower bound of the range of users
736            * @param end the upper bound of the range of users (not inclusive)
737            * @return the range of matching users
738            */
739            public java.util.List<User> findByC_CD(long companyId, Date createDate,
740                    int start, int end);
741    
742            /**
743            * Returns an ordered range of all the users where companyId = &#63; and createDate = &#63;.
744            *
745            * <p>
746            * 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 UserModelImpl}. 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.
747            * </p>
748            *
749            * @param companyId the company ID
750            * @param createDate the create date
751            * @param start the lower bound of the range of users
752            * @param end the upper bound of the range of users (not inclusive)
753            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
754            * @return the ordered range of matching users
755            */
756            public java.util.List<User> findByC_CD(long companyId, Date createDate,
757                    int start, int end,
758                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
759    
760            /**
761            * Returns an ordered range of all the users where companyId = &#63; and createDate = &#63;.
762            *
763            * <p>
764            * 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 UserModelImpl}. 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.
765            * </p>
766            *
767            * @param companyId the company ID
768            * @param createDate the create date
769            * @param start the lower bound of the range of users
770            * @param end the upper bound of the range of users (not inclusive)
771            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
772            * @param retrieveFromCache whether to retrieve from the finder cache
773            * @return the ordered range of matching users
774            */
775            public java.util.List<User> findByC_CD(long companyId, Date createDate,
776                    int start, int end,
777                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator,
778                    boolean retrieveFromCache);
779    
780            /**
781            * Returns the first user in the ordered set where companyId = &#63; and createDate = &#63;.
782            *
783            * @param companyId the company ID
784            * @param createDate the create date
785            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
786            * @return the first matching user
787            * @throws NoSuchUserException if a matching user could not be found
788            */
789            public User findByC_CD_First(long companyId, Date createDate,
790                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
791                    throws NoSuchUserException;
792    
793            /**
794            * Returns the first user in the ordered set where companyId = &#63; and createDate = &#63;.
795            *
796            * @param companyId the company ID
797            * @param createDate the create date
798            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
799            * @return the first matching user, or <code>null</code> if a matching user could not be found
800            */
801            public User fetchByC_CD_First(long companyId, Date createDate,
802                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
803    
804            /**
805            * Returns the last user in the ordered set where companyId = &#63; and createDate = &#63;.
806            *
807            * @param companyId the company ID
808            * @param createDate the create date
809            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
810            * @return the last matching user
811            * @throws NoSuchUserException if a matching user could not be found
812            */
813            public User findByC_CD_Last(long companyId, Date createDate,
814                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
815                    throws NoSuchUserException;
816    
817            /**
818            * Returns the last user in the ordered set where companyId = &#63; and createDate = &#63;.
819            *
820            * @param companyId the company ID
821            * @param createDate the create date
822            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
823            * @return the last matching user, or <code>null</code> if a matching user could not be found
824            */
825            public User fetchByC_CD_Last(long companyId, Date createDate,
826                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
827    
828            /**
829            * Returns the users before and after the current user in the ordered set where companyId = &#63; and createDate = &#63;.
830            *
831            * @param userId the primary key of the current user
832            * @param companyId the company ID
833            * @param createDate the create date
834            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
835            * @return the previous, current, and next user
836            * @throws NoSuchUserException if a user with the primary key could not be found
837            */
838            public User[] findByC_CD_PrevAndNext(long userId, long companyId,
839                    Date createDate,
840                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
841                    throws NoSuchUserException;
842    
843            /**
844            * Removes all the users where companyId = &#63; and createDate = &#63; from the database.
845            *
846            * @param companyId the company ID
847            * @param createDate the create date
848            */
849            public void removeByC_CD(long companyId, Date createDate);
850    
851            /**
852            * Returns the number of users where companyId = &#63; and createDate = &#63;.
853            *
854            * @param companyId the company ID
855            * @param createDate the create date
856            * @return the number of matching users
857            */
858            public int countByC_CD(long companyId, Date createDate);
859    
860            /**
861            * Returns all the users where companyId = &#63; and modifiedDate = &#63;.
862            *
863            * @param companyId the company ID
864            * @param modifiedDate the modified date
865            * @return the matching users
866            */
867            public java.util.List<User> findByC_MD(long companyId, Date modifiedDate);
868    
869            /**
870            * Returns a range of all the users where companyId = &#63; and modifiedDate = &#63;.
871            *
872            * <p>
873            * 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 UserModelImpl}. 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.
874            * </p>
875            *
876            * @param companyId the company ID
877            * @param modifiedDate the modified date
878            * @param start the lower bound of the range of users
879            * @param end the upper bound of the range of users (not inclusive)
880            * @return the range of matching users
881            */
882            public java.util.List<User> findByC_MD(long companyId, Date modifiedDate,
883                    int start, int end);
884    
885            /**
886            * Returns an ordered range of all the users where companyId = &#63; and modifiedDate = &#63;.
887            *
888            * <p>
889            * 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 UserModelImpl}. 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.
890            * </p>
891            *
892            * @param companyId the company ID
893            * @param modifiedDate the modified date
894            * @param start the lower bound of the range of users
895            * @param end the upper bound of the range of users (not inclusive)
896            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
897            * @return the ordered range of matching users
898            */
899            public java.util.List<User> findByC_MD(long companyId, Date modifiedDate,
900                    int start, int end,
901                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
902    
903            /**
904            * Returns an ordered range of all the users where companyId = &#63; and modifiedDate = &#63;.
905            *
906            * <p>
907            * 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 UserModelImpl}. 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.
908            * </p>
909            *
910            * @param companyId the company ID
911            * @param modifiedDate the modified date
912            * @param start the lower bound of the range of users
913            * @param end the upper bound of the range of users (not inclusive)
914            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
915            * @param retrieveFromCache whether to retrieve from the finder cache
916            * @return the ordered range of matching users
917            */
918            public java.util.List<User> findByC_MD(long companyId, Date modifiedDate,
919                    int start, int end,
920                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator,
921                    boolean retrieveFromCache);
922    
923            /**
924            * Returns the first user in the ordered set where companyId = &#63; and modifiedDate = &#63;.
925            *
926            * @param companyId the company ID
927            * @param modifiedDate the modified date
928            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
929            * @return the first matching user
930            * @throws NoSuchUserException if a matching user could not be found
931            */
932            public User findByC_MD_First(long companyId, Date modifiedDate,
933                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
934                    throws NoSuchUserException;
935    
936            /**
937            * Returns the first user in the ordered set where companyId = &#63; and modifiedDate = &#63;.
938            *
939            * @param companyId the company ID
940            * @param modifiedDate the modified date
941            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
942            * @return the first matching user, or <code>null</code> if a matching user could not be found
943            */
944            public User fetchByC_MD_First(long companyId, Date modifiedDate,
945                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
946    
947            /**
948            * Returns the last user in the ordered set where companyId = &#63; and modifiedDate = &#63;.
949            *
950            * @param companyId the company ID
951            * @param modifiedDate the modified date
952            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
953            * @return the last matching user
954            * @throws NoSuchUserException if a matching user could not be found
955            */
956            public User findByC_MD_Last(long companyId, Date modifiedDate,
957                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
958                    throws NoSuchUserException;
959    
960            /**
961            * Returns the last user in the ordered set where companyId = &#63; and modifiedDate = &#63;.
962            *
963            * @param companyId the company ID
964            * @param modifiedDate the modified date
965            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
966            * @return the last matching user, or <code>null</code> if a matching user could not be found
967            */
968            public User fetchByC_MD_Last(long companyId, Date modifiedDate,
969                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
970    
971            /**
972            * Returns the users before and after the current user in the ordered set where companyId = &#63; and modifiedDate = &#63;.
973            *
974            * @param userId the primary key of the current user
975            * @param companyId the company ID
976            * @param modifiedDate the modified date
977            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
978            * @return the previous, current, and next user
979            * @throws NoSuchUserException if a user with the primary key could not be found
980            */
981            public User[] findByC_MD_PrevAndNext(long userId, long companyId,
982                    Date modifiedDate,
983                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
984                    throws NoSuchUserException;
985    
986            /**
987            * Removes all the users where companyId = &#63; and modifiedDate = &#63; from the database.
988            *
989            * @param companyId the company ID
990            * @param modifiedDate the modified date
991            */
992            public void removeByC_MD(long companyId, Date modifiedDate);
993    
994            /**
995            * Returns the number of users where companyId = &#63; and modifiedDate = &#63;.
996            *
997            * @param companyId the company ID
998            * @param modifiedDate the modified date
999            * @return the number of matching users
1000            */
1001            public int countByC_MD(long companyId, Date modifiedDate);
1002    
1003            /**
1004            * Returns the user where companyId = &#63; and defaultUser = &#63; or throws a {@link NoSuchUserException} if it could not be found.
1005            *
1006            * @param companyId the company ID
1007            * @param defaultUser the default user
1008            * @return the matching user
1009            * @throws NoSuchUserException if a matching user could not be found
1010            */
1011            public User findByC_DU(long companyId, boolean defaultUser)
1012                    throws NoSuchUserException;
1013    
1014            /**
1015            * Returns the user where companyId = &#63; and defaultUser = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
1016            *
1017            * @param companyId the company ID
1018            * @param defaultUser the default user
1019            * @return the matching user, or <code>null</code> if a matching user could not be found
1020            */
1021            public User fetchByC_DU(long companyId, boolean defaultUser);
1022    
1023            /**
1024            * Returns the user where companyId = &#63; and defaultUser = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
1025            *
1026            * @param companyId the company ID
1027            * @param defaultUser the default user
1028            * @param retrieveFromCache whether to retrieve from the finder cache
1029            * @return the matching user, or <code>null</code> if a matching user could not be found
1030            */
1031            public User fetchByC_DU(long companyId, boolean defaultUser,
1032                    boolean retrieveFromCache);
1033    
1034            /**
1035            * Removes the user where companyId = &#63; and defaultUser = &#63; from the database.
1036            *
1037            * @param companyId the company ID
1038            * @param defaultUser the default user
1039            * @return the user that was removed
1040            */
1041            public User removeByC_DU(long companyId, boolean defaultUser)
1042                    throws NoSuchUserException;
1043    
1044            /**
1045            * Returns the number of users where companyId = &#63; and defaultUser = &#63;.
1046            *
1047            * @param companyId the company ID
1048            * @param defaultUser the default user
1049            * @return the number of matching users
1050            */
1051            public int countByC_DU(long companyId, boolean defaultUser);
1052    
1053            /**
1054            * Returns the user where companyId = &#63; and screenName = &#63; or throws a {@link NoSuchUserException} if it could not be found.
1055            *
1056            * @param companyId the company ID
1057            * @param screenName the screen name
1058            * @return the matching user
1059            * @throws NoSuchUserException if a matching user could not be found
1060            */
1061            public User findByC_SN(long companyId, java.lang.String screenName)
1062                    throws NoSuchUserException;
1063    
1064            /**
1065            * Returns the user where companyId = &#63; and screenName = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
1066            *
1067            * @param companyId the company ID
1068            * @param screenName the screen name
1069            * @return the matching user, or <code>null</code> if a matching user could not be found
1070            */
1071            public User fetchByC_SN(long companyId, java.lang.String screenName);
1072    
1073            /**
1074            * Returns the user where companyId = &#63; and screenName = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
1075            *
1076            * @param companyId the company ID
1077            * @param screenName the screen name
1078            * @param retrieveFromCache whether to retrieve from the finder cache
1079            * @return the matching user, or <code>null</code> if a matching user could not be found
1080            */
1081            public User fetchByC_SN(long companyId, java.lang.String screenName,
1082                    boolean retrieveFromCache);
1083    
1084            /**
1085            * Removes the user where companyId = &#63; and screenName = &#63; from the database.
1086            *
1087            * @param companyId the company ID
1088            * @param screenName the screen name
1089            * @return the user that was removed
1090            */
1091            public User removeByC_SN(long companyId, java.lang.String screenName)
1092                    throws NoSuchUserException;
1093    
1094            /**
1095            * Returns the number of users where companyId = &#63; and screenName = &#63;.
1096            *
1097            * @param companyId the company ID
1098            * @param screenName the screen name
1099            * @return the number of matching users
1100            */
1101            public int countByC_SN(long companyId, java.lang.String screenName);
1102    
1103            /**
1104            * Returns the user where companyId = &#63; and emailAddress = &#63; or throws a {@link NoSuchUserException} if it could not be found.
1105            *
1106            * @param companyId the company ID
1107            * @param emailAddress the email address
1108            * @return the matching user
1109            * @throws NoSuchUserException if a matching user could not be found
1110            */
1111            public User findByC_EA(long companyId, java.lang.String emailAddress)
1112                    throws NoSuchUserException;
1113    
1114            /**
1115            * Returns the user where companyId = &#63; and emailAddress = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
1116            *
1117            * @param companyId the company ID
1118            * @param emailAddress the email address
1119            * @return the matching user, or <code>null</code> if a matching user could not be found
1120            */
1121            public User fetchByC_EA(long companyId, java.lang.String emailAddress);
1122    
1123            /**
1124            * Returns the user where companyId = &#63; and emailAddress = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
1125            *
1126            * @param companyId the company ID
1127            * @param emailAddress the email address
1128            * @param retrieveFromCache whether to retrieve from the finder cache
1129            * @return the matching user, or <code>null</code> if a matching user could not be found
1130            */
1131            public User fetchByC_EA(long companyId, java.lang.String emailAddress,
1132                    boolean retrieveFromCache);
1133    
1134            /**
1135            * Removes the user where companyId = &#63; and emailAddress = &#63; from the database.
1136            *
1137            * @param companyId the company ID
1138            * @param emailAddress the email address
1139            * @return the user that was removed
1140            */
1141            public User removeByC_EA(long companyId, java.lang.String emailAddress)
1142                    throws NoSuchUserException;
1143    
1144            /**
1145            * Returns the number of users where companyId = &#63; and emailAddress = &#63;.
1146            *
1147            * @param companyId the company ID
1148            * @param emailAddress the email address
1149            * @return the number of matching users
1150            */
1151            public int countByC_EA(long companyId, java.lang.String emailAddress);
1152    
1153            /**
1154            * Returns the user where companyId = &#63; and facebookId = &#63; or throws a {@link NoSuchUserException} if it could not be found.
1155            *
1156            * @param companyId the company ID
1157            * @param facebookId the facebook ID
1158            * @return the matching user
1159            * @throws NoSuchUserException if a matching user could not be found
1160            */
1161            public User findByC_FID(long companyId, long facebookId)
1162                    throws NoSuchUserException;
1163    
1164            /**
1165            * Returns the user where companyId = &#63; and facebookId = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
1166            *
1167            * @param companyId the company ID
1168            * @param facebookId the facebook ID
1169            * @return the matching user, or <code>null</code> if a matching user could not be found
1170            */
1171            public User fetchByC_FID(long companyId, long facebookId);
1172    
1173            /**
1174            * Returns the user where companyId = &#63; and facebookId = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
1175            *
1176            * @param companyId the company ID
1177            * @param facebookId the facebook ID
1178            * @param retrieveFromCache whether to retrieve from the finder cache
1179            * @return the matching user, or <code>null</code> if a matching user could not be found
1180            */
1181            public User fetchByC_FID(long companyId, long facebookId,
1182                    boolean retrieveFromCache);
1183    
1184            /**
1185            * Removes the user where companyId = &#63; and facebookId = &#63; from the database.
1186            *
1187            * @param companyId the company ID
1188            * @param facebookId the facebook ID
1189            * @return the user that was removed
1190            */
1191            public User removeByC_FID(long companyId, long facebookId)
1192                    throws NoSuchUserException;
1193    
1194            /**
1195            * Returns the number of users where companyId = &#63; and facebookId = &#63;.
1196            *
1197            * @param companyId the company ID
1198            * @param facebookId the facebook ID
1199            * @return the number of matching users
1200            */
1201            public int countByC_FID(long companyId, long facebookId);
1202    
1203            /**
1204            * Returns the user where companyId = &#63; and googleUserId = &#63; or throws a {@link NoSuchUserException} if it could not be found.
1205            *
1206            * @param companyId the company ID
1207            * @param googleUserId the google user ID
1208            * @return the matching user
1209            * @throws NoSuchUserException if a matching user could not be found
1210            */
1211            public User findByC_GUID(long companyId, java.lang.String googleUserId)
1212                    throws NoSuchUserException;
1213    
1214            /**
1215            * Returns the user where companyId = &#63; and googleUserId = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
1216            *
1217            * @param companyId the company ID
1218            * @param googleUserId the google user ID
1219            * @return the matching user, or <code>null</code> if a matching user could not be found
1220            */
1221            public User fetchByC_GUID(long companyId, java.lang.String googleUserId);
1222    
1223            /**
1224            * Returns the user where companyId = &#63; and googleUserId = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
1225            *
1226            * @param companyId the company ID
1227            * @param googleUserId the google user ID
1228            * @param retrieveFromCache whether to retrieve from the finder cache
1229            * @return the matching user, or <code>null</code> if a matching user could not be found
1230            */
1231            public User fetchByC_GUID(long companyId, java.lang.String googleUserId,
1232                    boolean retrieveFromCache);
1233    
1234            /**
1235            * Removes the user where companyId = &#63; and googleUserId = &#63; from the database.
1236            *
1237            * @param companyId the company ID
1238            * @param googleUserId the google user ID
1239            * @return the user that was removed
1240            */
1241            public User removeByC_GUID(long companyId, java.lang.String googleUserId)
1242                    throws NoSuchUserException;
1243    
1244            /**
1245            * Returns the number of users where companyId = &#63; and googleUserId = &#63;.
1246            *
1247            * @param companyId the company ID
1248            * @param googleUserId the google user ID
1249            * @return the number of matching users
1250            */
1251            public int countByC_GUID(long companyId, java.lang.String googleUserId);
1252    
1253            /**
1254            * Returns the user where companyId = &#63; and openId = &#63; or throws a {@link NoSuchUserException} if it could not be found.
1255            *
1256            * @param companyId the company ID
1257            * @param openId the open ID
1258            * @return the matching user
1259            * @throws NoSuchUserException if a matching user could not be found
1260            */
1261            public User findByC_O(long companyId, java.lang.String openId)
1262                    throws NoSuchUserException;
1263    
1264            /**
1265            * Returns the user where companyId = &#63; and openId = &#63; or returns <code>null</code> if it could not be found. Uses the finder cache.
1266            *
1267            * @param companyId the company ID
1268            * @param openId the open ID
1269            * @return the matching user, or <code>null</code> if a matching user could not be found
1270            */
1271            public User fetchByC_O(long companyId, java.lang.String openId);
1272    
1273            /**
1274            * Returns the user where companyId = &#63; and openId = &#63; or returns <code>null</code> if it could not be found, optionally using the finder cache.
1275            *
1276            * @param companyId the company ID
1277            * @param openId the open ID
1278            * @param retrieveFromCache whether to retrieve from the finder cache
1279            * @return the matching user, or <code>null</code> if a matching user could not be found
1280            */
1281            public User fetchByC_O(long companyId, java.lang.String openId,
1282                    boolean retrieveFromCache);
1283    
1284            /**
1285            * Removes the user where companyId = &#63; and openId = &#63; from the database.
1286            *
1287            * @param companyId the company ID
1288            * @param openId the open ID
1289            * @return the user that was removed
1290            */
1291            public User removeByC_O(long companyId, java.lang.String openId)
1292                    throws NoSuchUserException;
1293    
1294            /**
1295            * Returns the number of users where companyId = &#63; and openId = &#63;.
1296            *
1297            * @param companyId the company ID
1298            * @param openId the open ID
1299            * @return the number of matching users
1300            */
1301            public int countByC_O(long companyId, java.lang.String openId);
1302    
1303            /**
1304            * Returns all the users where companyId = &#63; and status = &#63;.
1305            *
1306            * @param companyId the company ID
1307            * @param status the status
1308            * @return the matching users
1309            */
1310            public java.util.List<User> findByC_S(long companyId, int status);
1311    
1312            /**
1313            * Returns a range of all the users where companyId = &#63; and status = &#63;.
1314            *
1315            * <p>
1316            * 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 UserModelImpl}. 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.
1317            * </p>
1318            *
1319            * @param companyId the company ID
1320            * @param status the status
1321            * @param start the lower bound of the range of users
1322            * @param end the upper bound of the range of users (not inclusive)
1323            * @return the range of matching users
1324            */
1325            public java.util.List<User> findByC_S(long companyId, int status,
1326                    int start, int end);
1327    
1328            /**
1329            * Returns an ordered range of all the users where companyId = &#63; and status = &#63;.
1330            *
1331            * <p>
1332            * 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 UserModelImpl}. 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.
1333            * </p>
1334            *
1335            * @param companyId the company ID
1336            * @param status the status
1337            * @param start the lower bound of the range of users
1338            * @param end the upper bound of the range of users (not inclusive)
1339            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1340            * @return the ordered range of matching users
1341            */
1342            public java.util.List<User> findByC_S(long companyId, int status,
1343                    int start, int end,
1344                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
1345    
1346            /**
1347            * Returns an ordered range of all the users where companyId = &#63; and status = &#63;.
1348            *
1349            * <p>
1350            * 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 UserModelImpl}. 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.
1351            * </p>
1352            *
1353            * @param companyId the company ID
1354            * @param status the status
1355            * @param start the lower bound of the range of users
1356            * @param end the upper bound of the range of users (not inclusive)
1357            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1358            * @param retrieveFromCache whether to retrieve from the finder cache
1359            * @return the ordered range of matching users
1360            */
1361            public java.util.List<User> findByC_S(long companyId, int status,
1362                    int start, int end,
1363                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator,
1364                    boolean retrieveFromCache);
1365    
1366            /**
1367            * Returns the first user in the ordered set where companyId = &#63; and status = &#63;.
1368            *
1369            * @param companyId the company ID
1370            * @param status the status
1371            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1372            * @return the first matching user
1373            * @throws NoSuchUserException if a matching user could not be found
1374            */
1375            public User findByC_S_First(long companyId, int status,
1376                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
1377                    throws NoSuchUserException;
1378    
1379            /**
1380            * Returns the first user in the ordered set where companyId = &#63; and status = &#63;.
1381            *
1382            * @param companyId the company ID
1383            * @param status the status
1384            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1385            * @return the first matching user, or <code>null</code> if a matching user could not be found
1386            */
1387            public User fetchByC_S_First(long companyId, int status,
1388                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
1389    
1390            /**
1391            * Returns the last user in the ordered set where companyId = &#63; and status = &#63;.
1392            *
1393            * @param companyId the company ID
1394            * @param status the status
1395            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1396            * @return the last matching user
1397            * @throws NoSuchUserException if a matching user could not be found
1398            */
1399            public User findByC_S_Last(long companyId, int status,
1400                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
1401                    throws NoSuchUserException;
1402    
1403            /**
1404            * Returns the last user in the ordered set where companyId = &#63; and status = &#63;.
1405            *
1406            * @param companyId the company ID
1407            * @param status the status
1408            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1409            * @return the last matching user, or <code>null</code> if a matching user could not be found
1410            */
1411            public User fetchByC_S_Last(long companyId, int status,
1412                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
1413    
1414            /**
1415            * Returns the users before and after the current user in the ordered set where companyId = &#63; and status = &#63;.
1416            *
1417            * @param userId the primary key of the current user
1418            * @param companyId the company ID
1419            * @param status the status
1420            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1421            * @return the previous, current, and next user
1422            * @throws NoSuchUserException if a user with the primary key could not be found
1423            */
1424            public User[] findByC_S_PrevAndNext(long userId, long companyId,
1425                    int status,
1426                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
1427                    throws NoSuchUserException;
1428    
1429            /**
1430            * Removes all the users where companyId = &#63; and status = &#63; from the database.
1431            *
1432            * @param companyId the company ID
1433            * @param status the status
1434            */
1435            public void removeByC_S(long companyId, int status);
1436    
1437            /**
1438            * Returns the number of users where companyId = &#63; and status = &#63;.
1439            *
1440            * @param companyId the company ID
1441            * @param status the status
1442            * @return the number of matching users
1443            */
1444            public int countByC_S(long companyId, int status);
1445    
1446            /**
1447            * Returns all the users where companyId = &#63; and createDate = &#63; and modifiedDate = &#63;.
1448            *
1449            * @param companyId the company ID
1450            * @param createDate the create date
1451            * @param modifiedDate the modified date
1452            * @return the matching users
1453            */
1454            public java.util.List<User> findByC_CD_MD(long companyId, Date createDate,
1455                    Date modifiedDate);
1456    
1457            /**
1458            * Returns a range of all the users where companyId = &#63; and createDate = &#63; and modifiedDate = &#63;.
1459            *
1460            * <p>
1461            * 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 UserModelImpl}. 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.
1462            * </p>
1463            *
1464            * @param companyId the company ID
1465            * @param createDate the create date
1466            * @param modifiedDate the modified date
1467            * @param start the lower bound of the range of users
1468            * @param end the upper bound of the range of users (not inclusive)
1469            * @return the range of matching users
1470            */
1471            public java.util.List<User> findByC_CD_MD(long companyId, Date createDate,
1472                    Date modifiedDate, int start, int end);
1473    
1474            /**
1475            * Returns an ordered range of all the users where companyId = &#63; and createDate = &#63; and modifiedDate = &#63;.
1476            *
1477            * <p>
1478            * 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 UserModelImpl}. 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.
1479            * </p>
1480            *
1481            * @param companyId the company ID
1482            * @param createDate the create date
1483            * @param modifiedDate the modified date
1484            * @param start the lower bound of the range of users
1485            * @param end the upper bound of the range of users (not inclusive)
1486            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1487            * @return the ordered range of matching users
1488            */
1489            public java.util.List<User> findByC_CD_MD(long companyId, Date createDate,
1490                    Date modifiedDate, int start, int end,
1491                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
1492    
1493            /**
1494            * Returns an ordered range of all the users where companyId = &#63; and createDate = &#63; and modifiedDate = &#63;.
1495            *
1496            * <p>
1497            * 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 UserModelImpl}. 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.
1498            * </p>
1499            *
1500            * @param companyId the company ID
1501            * @param createDate the create date
1502            * @param modifiedDate the modified date
1503            * @param start the lower bound of the range of users
1504            * @param end the upper bound of the range of users (not inclusive)
1505            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1506            * @param retrieveFromCache whether to retrieve from the finder cache
1507            * @return the ordered range of matching users
1508            */
1509            public java.util.List<User> findByC_CD_MD(long companyId, Date createDate,
1510                    Date modifiedDate, int start, int end,
1511                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator,
1512                    boolean retrieveFromCache);
1513    
1514            /**
1515            * Returns the first user in the ordered set where companyId = &#63; and createDate = &#63; and modifiedDate = &#63;.
1516            *
1517            * @param companyId the company ID
1518            * @param createDate the create date
1519            * @param modifiedDate the modified date
1520            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1521            * @return the first matching user
1522            * @throws NoSuchUserException if a matching user could not be found
1523            */
1524            public User findByC_CD_MD_First(long companyId, Date createDate,
1525                    Date modifiedDate,
1526                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
1527                    throws NoSuchUserException;
1528    
1529            /**
1530            * Returns the first user in the ordered set where companyId = &#63; and createDate = &#63; and modifiedDate = &#63;.
1531            *
1532            * @param companyId the company ID
1533            * @param createDate the create date
1534            * @param modifiedDate the modified date
1535            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1536            * @return the first matching user, or <code>null</code> if a matching user could not be found
1537            */
1538            public User fetchByC_CD_MD_First(long companyId, Date createDate,
1539                    Date modifiedDate,
1540                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
1541    
1542            /**
1543            * Returns the last user in the ordered set where companyId = &#63; and createDate = &#63; and modifiedDate = &#63;.
1544            *
1545            * @param companyId the company ID
1546            * @param createDate the create date
1547            * @param modifiedDate the modified date
1548            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1549            * @return the last matching user
1550            * @throws NoSuchUserException if a matching user could not be found
1551            */
1552            public User findByC_CD_MD_Last(long companyId, Date createDate,
1553                    Date modifiedDate,
1554                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
1555                    throws NoSuchUserException;
1556    
1557            /**
1558            * Returns the last user in the ordered set where companyId = &#63; and createDate = &#63; and modifiedDate = &#63;.
1559            *
1560            * @param companyId the company ID
1561            * @param createDate the create date
1562            * @param modifiedDate the modified date
1563            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1564            * @return the last matching user, or <code>null</code> if a matching user could not be found
1565            */
1566            public User fetchByC_CD_MD_Last(long companyId, Date createDate,
1567                    Date modifiedDate,
1568                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
1569    
1570            /**
1571            * Returns the users before and after the current user in the ordered set where companyId = &#63; and createDate = &#63; and modifiedDate = &#63;.
1572            *
1573            * @param userId the primary key of the current user
1574            * @param companyId the company ID
1575            * @param createDate the create date
1576            * @param modifiedDate the modified date
1577            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1578            * @return the previous, current, and next user
1579            * @throws NoSuchUserException if a user with the primary key could not be found
1580            */
1581            public User[] findByC_CD_MD_PrevAndNext(long userId, long companyId,
1582                    Date createDate, Date modifiedDate,
1583                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
1584                    throws NoSuchUserException;
1585    
1586            /**
1587            * Removes all the users where companyId = &#63; and createDate = &#63; and modifiedDate = &#63; from the database.
1588            *
1589            * @param companyId the company ID
1590            * @param createDate the create date
1591            * @param modifiedDate the modified date
1592            */
1593            public void removeByC_CD_MD(long companyId, Date createDate,
1594                    Date modifiedDate);
1595    
1596            /**
1597            * Returns the number of users where companyId = &#63; and createDate = &#63; and modifiedDate = &#63;.
1598            *
1599            * @param companyId the company ID
1600            * @param createDate the create date
1601            * @param modifiedDate the modified date
1602            * @return the number of matching users
1603            */
1604            public int countByC_CD_MD(long companyId, Date createDate, Date modifiedDate);
1605    
1606            /**
1607            * Returns all the users where companyId = &#63; and defaultUser = &#63; and status = &#63;.
1608            *
1609            * @param companyId the company ID
1610            * @param defaultUser the default user
1611            * @param status the status
1612            * @return the matching users
1613            */
1614            public java.util.List<User> findByC_DU_S(long companyId,
1615                    boolean defaultUser, int status);
1616    
1617            /**
1618            * Returns a range of all the users where companyId = &#63; and defaultUser = &#63; and status = &#63;.
1619            *
1620            * <p>
1621            * 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 UserModelImpl}. 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.
1622            * </p>
1623            *
1624            * @param companyId the company ID
1625            * @param defaultUser the default user
1626            * @param status the status
1627            * @param start the lower bound of the range of users
1628            * @param end the upper bound of the range of users (not inclusive)
1629            * @return the range of matching users
1630            */
1631            public java.util.List<User> findByC_DU_S(long companyId,
1632                    boolean defaultUser, int status, int start, int end);
1633    
1634            /**
1635            * Returns an ordered range of all the users where companyId = &#63; and defaultUser = &#63; and status = &#63;.
1636            *
1637            * <p>
1638            * 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 UserModelImpl}. 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.
1639            * </p>
1640            *
1641            * @param companyId the company ID
1642            * @param defaultUser the default user
1643            * @param status the status
1644            * @param start the lower bound of the range of users
1645            * @param end the upper bound of the range of users (not inclusive)
1646            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1647            * @return the ordered range of matching users
1648            */
1649            public java.util.List<User> findByC_DU_S(long companyId,
1650                    boolean defaultUser, int status, int start, int end,
1651                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
1652    
1653            /**
1654            * Returns an ordered range of all the users where companyId = &#63; and defaultUser = &#63; and status = &#63;.
1655            *
1656            * <p>
1657            * 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 UserModelImpl}. 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.
1658            * </p>
1659            *
1660            * @param companyId the company ID
1661            * @param defaultUser the default user
1662            * @param status the status
1663            * @param start the lower bound of the range of users
1664            * @param end the upper bound of the range of users (not inclusive)
1665            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1666            * @param retrieveFromCache whether to retrieve from the finder cache
1667            * @return the ordered range of matching users
1668            */
1669            public java.util.List<User> findByC_DU_S(long companyId,
1670                    boolean defaultUser, int status, int start, int end,
1671                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator,
1672                    boolean retrieveFromCache);
1673    
1674            /**
1675            * Returns the first user in the ordered set where companyId = &#63; and defaultUser = &#63; and status = &#63;.
1676            *
1677            * @param companyId the company ID
1678            * @param defaultUser the default user
1679            * @param status the status
1680            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1681            * @return the first matching user
1682            * @throws NoSuchUserException if a matching user could not be found
1683            */
1684            public User findByC_DU_S_First(long companyId, boolean defaultUser,
1685                    int status,
1686                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
1687                    throws NoSuchUserException;
1688    
1689            /**
1690            * Returns the first user in the ordered set where companyId = &#63; and defaultUser = &#63; and status = &#63;.
1691            *
1692            * @param companyId the company ID
1693            * @param defaultUser the default user
1694            * @param status the status
1695            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1696            * @return the first matching user, or <code>null</code> if a matching user could not be found
1697            */
1698            public User fetchByC_DU_S_First(long companyId, boolean defaultUser,
1699                    int status,
1700                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
1701    
1702            /**
1703            * Returns the last user in the ordered set where companyId = &#63; and defaultUser = &#63; and status = &#63;.
1704            *
1705            * @param companyId the company ID
1706            * @param defaultUser the default user
1707            * @param status the status
1708            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1709            * @return the last matching user
1710            * @throws NoSuchUserException if a matching user could not be found
1711            */
1712            public User findByC_DU_S_Last(long companyId, boolean defaultUser,
1713                    int status,
1714                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
1715                    throws NoSuchUserException;
1716    
1717            /**
1718            * Returns the last user in the ordered set where companyId = &#63; and defaultUser = &#63; and status = &#63;.
1719            *
1720            * @param companyId the company ID
1721            * @param defaultUser the default user
1722            * @param status the status
1723            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1724            * @return the last matching user, or <code>null</code> if a matching user could not be found
1725            */
1726            public User fetchByC_DU_S_Last(long companyId, boolean defaultUser,
1727                    int status,
1728                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
1729    
1730            /**
1731            * Returns the users before and after the current user in the ordered set where companyId = &#63; and defaultUser = &#63; and status = &#63;.
1732            *
1733            * @param userId the primary key of the current user
1734            * @param companyId the company ID
1735            * @param defaultUser the default user
1736            * @param status the status
1737            * @param orderByComparator the comparator to order the set by (optionally <code>null</code>)
1738            * @return the previous, current, and next user
1739            * @throws NoSuchUserException if a user with the primary key could not be found
1740            */
1741            public User[] findByC_DU_S_PrevAndNext(long userId, long companyId,
1742                    boolean defaultUser, int status,
1743                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator)
1744                    throws NoSuchUserException;
1745    
1746            /**
1747            * Removes all the users where companyId = &#63; and defaultUser = &#63; and status = &#63; from the database.
1748            *
1749            * @param companyId the company ID
1750            * @param defaultUser the default user
1751            * @param status the status
1752            */
1753            public void removeByC_DU_S(long companyId, boolean defaultUser, int status);
1754    
1755            /**
1756            * Returns the number of users where companyId = &#63; and defaultUser = &#63; and status = &#63;.
1757            *
1758            * @param companyId the company ID
1759            * @param defaultUser the default user
1760            * @param status the status
1761            * @return the number of matching users
1762            */
1763            public int countByC_DU_S(long companyId, boolean defaultUser, int status);
1764    
1765            /**
1766            * Caches the user in the entity cache if it is enabled.
1767            *
1768            * @param user the user
1769            */
1770            public void cacheResult(User user);
1771    
1772            /**
1773            * Caches the users in the entity cache if it is enabled.
1774            *
1775            * @param users the users
1776            */
1777            public void cacheResult(java.util.List<User> users);
1778    
1779            /**
1780            * Creates a new user with the primary key. Does not add the user to the database.
1781            *
1782            * @param userId the primary key for the new user
1783            * @return the new user
1784            */
1785            public User create(long userId);
1786    
1787            /**
1788            * Removes the user with the primary key from the database. Also notifies the appropriate model listeners.
1789            *
1790            * @param userId the primary key of the user
1791            * @return the user that was removed
1792            * @throws NoSuchUserException if a user with the primary key could not be found
1793            */
1794            public User remove(long userId) throws NoSuchUserException;
1795    
1796            public User updateImpl(User user);
1797    
1798            /**
1799            * Returns the user with the primary key or throws a {@link NoSuchUserException} if it could not be found.
1800            *
1801            * @param userId the primary key of the user
1802            * @return the user
1803            * @throws NoSuchUserException if a user with the primary key could not be found
1804            */
1805            public User findByPrimaryKey(long userId) throws NoSuchUserException;
1806    
1807            /**
1808            * Returns the user with the primary key or returns <code>null</code> if it could not be found.
1809            *
1810            * @param userId the primary key of the user
1811            * @return the user, or <code>null</code> if a user with the primary key could not be found
1812            */
1813            public User fetchByPrimaryKey(long userId);
1814    
1815            @Override
1816            public java.util.Map<java.io.Serializable, User> fetchByPrimaryKeys(
1817                    java.util.Set<java.io.Serializable> primaryKeys);
1818    
1819            /**
1820            * Returns all the users.
1821            *
1822            * @return the users
1823            */
1824            public java.util.List<User> findAll();
1825    
1826            /**
1827            * Returns a range of all the users.
1828            *
1829            * <p>
1830            * 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 UserModelImpl}. 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.
1831            * </p>
1832            *
1833            * @param start the lower bound of the range of users
1834            * @param end the upper bound of the range of users (not inclusive)
1835            * @return the range of users
1836            */
1837            public java.util.List<User> findAll(int start, int end);
1838    
1839            /**
1840            * Returns an ordered range of all the users.
1841            *
1842            * <p>
1843            * 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 UserModelImpl}. 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.
1844            * </p>
1845            *
1846            * @param start the lower bound of the range of users
1847            * @param end the upper bound of the range of users (not inclusive)
1848            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1849            * @return the ordered range of users
1850            */
1851            public java.util.List<User> findAll(int start, int end,
1852                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator);
1853    
1854            /**
1855            * Returns an ordered range of all the users.
1856            *
1857            * <p>
1858            * 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 UserModelImpl}. 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.
1859            * </p>
1860            *
1861            * @param start the lower bound of the range of users
1862            * @param end the upper bound of the range of users (not inclusive)
1863            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1864            * @param retrieveFromCache whether to retrieve from the finder cache
1865            * @return the ordered range of users
1866            */
1867            public java.util.List<User> findAll(int start, int end,
1868                    com.liferay.portal.kernel.util.OrderByComparator<User> orderByComparator,
1869                    boolean retrieveFromCache);
1870    
1871            /**
1872            * Removes all the users from the database.
1873            */
1874            public void removeAll();
1875    
1876            /**
1877            * Returns the number of users.
1878            *
1879            * @return the number of users
1880            */
1881            public int countAll();
1882    
1883            /**
1884            * Returns the primaryKeys of groups associated with the user.
1885            *
1886            * @param pk the primary key of the user
1887            * @return long[] of the primaryKeys of groups associated with the user
1888            */
1889            public long[] getGroupPrimaryKeys(long pk);
1890    
1891            /**
1892            * Returns all the groups associated with the user.
1893            *
1894            * @param pk the primary key of the user
1895            * @return the groups associated with the user
1896            */
1897            public java.util.List<com.liferay.portal.kernel.model.Group> getGroups(
1898                    long pk);
1899    
1900            /**
1901            * Returns a range of all the groups associated with the user.
1902            *
1903            * <p>
1904            * 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 UserModelImpl}. 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.
1905            * </p>
1906            *
1907            * @param pk the primary key of the user
1908            * @param start the lower bound of the range of users
1909            * @param end the upper bound of the range of users (not inclusive)
1910            * @return the range of groups associated with the user
1911            */
1912            public java.util.List<com.liferay.portal.kernel.model.Group> getGroups(
1913                    long pk, int start, int end);
1914    
1915            /**
1916            * Returns an ordered range of all the groups associated with the user.
1917            *
1918            * <p>
1919            * 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 UserModelImpl}. 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.
1920            * </p>
1921            *
1922            * @param pk the primary key of the user
1923            * @param start the lower bound of the range of users
1924            * @param end the upper bound of the range of users (not inclusive)
1925            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
1926            * @return the ordered range of groups associated with the user
1927            */
1928            public java.util.List<com.liferay.portal.kernel.model.Group> getGroups(
1929                    long pk, int start, int end,
1930                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.kernel.model.Group> orderByComparator);
1931    
1932            /**
1933            * Returns the number of groups associated with the user.
1934            *
1935            * @param pk the primary key of the user
1936            * @return the number of groups associated with the user
1937            */
1938            public int getGroupsSize(long pk);
1939    
1940            /**
1941            * Returns <code>true</code> if the group is associated with the user.
1942            *
1943            * @param pk the primary key of the user
1944            * @param groupPK the primary key of the group
1945            * @return <code>true</code> if the group is associated with the user; <code>false</code> otherwise
1946            */
1947            public boolean containsGroup(long pk, long groupPK);
1948    
1949            /**
1950            * Returns <code>true</code> if the user has any groups associated with it.
1951            *
1952            * @param pk the primary key of the user to check for associations with groups
1953            * @return <code>true</code> if the user has any groups associated with it; <code>false</code> otherwise
1954            */
1955            public boolean containsGroups(long pk);
1956    
1957            /**
1958            * Adds an association between the user and the group. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1959            *
1960            * @param pk the primary key of the user
1961            * @param groupPK the primary key of the group
1962            */
1963            public void addGroup(long pk, long groupPK);
1964    
1965            /**
1966            * Adds an association between the user and the group. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1967            *
1968            * @param pk the primary key of the user
1969            * @param group the group
1970            */
1971            public void addGroup(long pk, com.liferay.portal.kernel.model.Group group);
1972    
1973            /**
1974            * Adds an association between the user and the groups. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1975            *
1976            * @param pk the primary key of the user
1977            * @param groupPKs the primary keys of the groups
1978            */
1979            public void addGroups(long pk, long[] groupPKs);
1980    
1981            /**
1982            * Adds an association between the user and the groups. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1983            *
1984            * @param pk the primary key of the user
1985            * @param groups the groups
1986            */
1987            public void addGroups(long pk,
1988                    java.util.List<com.liferay.portal.kernel.model.Group> groups);
1989    
1990            /**
1991            * Clears all associations between the user and its groups. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1992            *
1993            * @param pk the primary key of the user to clear the associated groups from
1994            */
1995            public void clearGroups(long pk);
1996    
1997            /**
1998            * Removes the association between the user and the group. Also notifies the appropriate model listeners and clears the mapping table finder cache.
1999            *
2000            * @param pk the primary key of the user
2001            * @param groupPK the primary key of the group
2002            */
2003            public void removeGroup(long pk, long groupPK);
2004    
2005            /**
2006            * Removes the association between the user and the group. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2007            *
2008            * @param pk the primary key of the user
2009            * @param group the group
2010            */
2011            public void removeGroup(long pk, com.liferay.portal.kernel.model.Group group);
2012    
2013            /**
2014            * Removes the association between the user and the groups. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2015            *
2016            * @param pk the primary key of the user
2017            * @param groupPKs the primary keys of the groups
2018            */
2019            public void removeGroups(long pk, long[] groupPKs);
2020    
2021            /**
2022            * Removes the association between the user and the groups. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2023            *
2024            * @param pk the primary key of the user
2025            * @param groups the groups
2026            */
2027            public void removeGroups(long pk,
2028                    java.util.List<com.liferay.portal.kernel.model.Group> groups);
2029    
2030            /**
2031            * Sets the groups associated with the user, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2032            *
2033            * @param pk the primary key of the user
2034            * @param groupPKs the primary keys of the groups to be associated with the user
2035            */
2036            public void setGroups(long pk, long[] groupPKs);
2037    
2038            /**
2039            * Sets the groups associated with the user, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2040            *
2041            * @param pk the primary key of the user
2042            * @param groups the groups to be associated with the user
2043            */
2044            public void setGroups(long pk,
2045                    java.util.List<com.liferay.portal.kernel.model.Group> groups);
2046    
2047            /**
2048            * Returns the primaryKeys of organizations associated with the user.
2049            *
2050            * @param pk the primary key of the user
2051            * @return long[] of the primaryKeys of organizations associated with the user
2052            */
2053            public long[] getOrganizationPrimaryKeys(long pk);
2054    
2055            /**
2056            * Returns all the organizations associated with the user.
2057            *
2058            * @param pk the primary key of the user
2059            * @return the organizations associated with the user
2060            */
2061            public java.util.List<com.liferay.portal.kernel.model.Organization> getOrganizations(
2062                    long pk);
2063    
2064            /**
2065            * Returns a range of all the organizations associated with the user.
2066            *
2067            * <p>
2068            * 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 UserModelImpl}. 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.
2069            * </p>
2070            *
2071            * @param pk the primary key of the user
2072            * @param start the lower bound of the range of users
2073            * @param end the upper bound of the range of users (not inclusive)
2074            * @return the range of organizations associated with the user
2075            */
2076            public java.util.List<com.liferay.portal.kernel.model.Organization> getOrganizations(
2077                    long pk, int start, int end);
2078    
2079            /**
2080            * Returns an ordered range of all the organizations associated with the user.
2081            *
2082            * <p>
2083            * 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 UserModelImpl}. 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.
2084            * </p>
2085            *
2086            * @param pk the primary key of the user
2087            * @param start the lower bound of the range of users
2088            * @param end the upper bound of the range of users (not inclusive)
2089            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
2090            * @return the ordered range of organizations associated with the user
2091            */
2092            public java.util.List<com.liferay.portal.kernel.model.Organization> getOrganizations(
2093                    long pk, int start, int end,
2094                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.kernel.model.Organization> orderByComparator);
2095    
2096            /**
2097            * Returns the number of organizations associated with the user.
2098            *
2099            * @param pk the primary key of the user
2100            * @return the number of organizations associated with the user
2101            */
2102            public int getOrganizationsSize(long pk);
2103    
2104            /**
2105            * Returns <code>true</code> if the organization is associated with the user.
2106            *
2107            * @param pk the primary key of the user
2108            * @param organizationPK the primary key of the organization
2109            * @return <code>true</code> if the organization is associated with the user; <code>false</code> otherwise
2110            */
2111            public boolean containsOrganization(long pk, long organizationPK);
2112    
2113            /**
2114            * Returns <code>true</code> if the user has any organizations associated with it.
2115            *
2116            * @param pk the primary key of the user to check for associations with organizations
2117            * @return <code>true</code> if the user has any organizations associated with it; <code>false</code> otherwise
2118            */
2119            public boolean containsOrganizations(long pk);
2120    
2121            /**
2122            * Adds an association between the user and the organization. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2123            *
2124            * @param pk the primary key of the user
2125            * @param organizationPK the primary key of the organization
2126            */
2127            public void addOrganization(long pk, long organizationPK);
2128    
2129            /**
2130            * Adds an association between the user and the organization. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2131            *
2132            * @param pk the primary key of the user
2133            * @param organization the organization
2134            */
2135            public void addOrganization(long pk,
2136                    com.liferay.portal.kernel.model.Organization organization);
2137    
2138            /**
2139            * Adds an association between the user and the organizations. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2140            *
2141            * @param pk the primary key of the user
2142            * @param organizationPKs the primary keys of the organizations
2143            */
2144            public void addOrganizations(long pk, long[] organizationPKs);
2145    
2146            /**
2147            * Adds an association between the user and the organizations. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2148            *
2149            * @param pk the primary key of the user
2150            * @param organizations the organizations
2151            */
2152            public void addOrganizations(long pk,
2153                    java.util.List<com.liferay.portal.kernel.model.Organization> organizations);
2154    
2155            /**
2156            * Clears all associations between the user and its organizations. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2157            *
2158            * @param pk the primary key of the user to clear the associated organizations from
2159            */
2160            public void clearOrganizations(long pk);
2161    
2162            /**
2163            * Removes the association between the user and the organization. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2164            *
2165            * @param pk the primary key of the user
2166            * @param organizationPK the primary key of the organization
2167            */
2168            public void removeOrganization(long pk, long organizationPK);
2169    
2170            /**
2171            * Removes the association between the user and the organization. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2172            *
2173            * @param pk the primary key of the user
2174            * @param organization the organization
2175            */
2176            public void removeOrganization(long pk,
2177                    com.liferay.portal.kernel.model.Organization organization);
2178    
2179            /**
2180            * Removes the association between the user and the organizations. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2181            *
2182            * @param pk the primary key of the user
2183            * @param organizationPKs the primary keys of the organizations
2184            */
2185            public void removeOrganizations(long pk, long[] organizationPKs);
2186    
2187            /**
2188            * Removes the association between the user and the organizations. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2189            *
2190            * @param pk the primary key of the user
2191            * @param organizations the organizations
2192            */
2193            public void removeOrganizations(long pk,
2194                    java.util.List<com.liferay.portal.kernel.model.Organization> organizations);
2195    
2196            /**
2197            * Sets the organizations associated with the user, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2198            *
2199            * @param pk the primary key of the user
2200            * @param organizationPKs the primary keys of the organizations to be associated with the user
2201            */
2202            public void setOrganizations(long pk, long[] organizationPKs);
2203    
2204            /**
2205            * Sets the organizations associated with the user, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2206            *
2207            * @param pk the primary key of the user
2208            * @param organizations the organizations to be associated with the user
2209            */
2210            public void setOrganizations(long pk,
2211                    java.util.List<com.liferay.portal.kernel.model.Organization> organizations);
2212    
2213            /**
2214            * Returns the primaryKeys of roles associated with the user.
2215            *
2216            * @param pk the primary key of the user
2217            * @return long[] of the primaryKeys of roles associated with the user
2218            */
2219            public long[] getRolePrimaryKeys(long pk);
2220    
2221            /**
2222            * Returns all the roles associated with the user.
2223            *
2224            * @param pk the primary key of the user
2225            * @return the roles associated with the user
2226            */
2227            public java.util.List<com.liferay.portal.kernel.model.Role> getRoles(
2228                    long pk);
2229    
2230            /**
2231            * Returns a range of all the roles associated with the user.
2232            *
2233            * <p>
2234            * 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 UserModelImpl}. 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.
2235            * </p>
2236            *
2237            * @param pk the primary key of the user
2238            * @param start the lower bound of the range of users
2239            * @param end the upper bound of the range of users (not inclusive)
2240            * @return the range of roles associated with the user
2241            */
2242            public java.util.List<com.liferay.portal.kernel.model.Role> getRoles(
2243                    long pk, int start, int end);
2244    
2245            /**
2246            * Returns an ordered range of all the roles associated with the user.
2247            *
2248            * <p>
2249            * 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 UserModelImpl}. 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.
2250            * </p>
2251            *
2252            * @param pk the primary key of the user
2253            * @param start the lower bound of the range of users
2254            * @param end the upper bound of the range of users (not inclusive)
2255            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
2256            * @return the ordered range of roles associated with the user
2257            */
2258            public java.util.List<com.liferay.portal.kernel.model.Role> getRoles(
2259                    long pk, int start, int end,
2260                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.kernel.model.Role> orderByComparator);
2261    
2262            /**
2263            * Returns the number of roles associated with the user.
2264            *
2265            * @param pk the primary key of the user
2266            * @return the number of roles associated with the user
2267            */
2268            public int getRolesSize(long pk);
2269    
2270            /**
2271            * Returns <code>true</code> if the role is associated with the user.
2272            *
2273            * @param pk the primary key of the user
2274            * @param rolePK the primary key of the role
2275            * @return <code>true</code> if the role is associated with the user; <code>false</code> otherwise
2276            */
2277            public boolean containsRole(long pk, long rolePK);
2278    
2279            /**
2280            * Returns <code>true</code> if the user has any roles associated with it.
2281            *
2282            * @param pk the primary key of the user to check for associations with roles
2283            * @return <code>true</code> if the user has any roles associated with it; <code>false</code> otherwise
2284            */
2285            public boolean containsRoles(long pk);
2286    
2287            /**
2288            * Adds an association between the user and the role. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2289            *
2290            * @param pk the primary key of the user
2291            * @param rolePK the primary key of the role
2292            */
2293            public void addRole(long pk, long rolePK);
2294    
2295            /**
2296            * Adds an association between the user and the role. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2297            *
2298            * @param pk the primary key of the user
2299            * @param role the role
2300            */
2301            public void addRole(long pk, com.liferay.portal.kernel.model.Role role);
2302    
2303            /**
2304            * Adds an association between the user and the roles. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2305            *
2306            * @param pk the primary key of the user
2307            * @param rolePKs the primary keys of the roles
2308            */
2309            public void addRoles(long pk, long[] rolePKs);
2310    
2311            /**
2312            * Adds an association between the user and the roles. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2313            *
2314            * @param pk the primary key of the user
2315            * @param roles the roles
2316            */
2317            public void addRoles(long pk,
2318                    java.util.List<com.liferay.portal.kernel.model.Role> roles);
2319    
2320            /**
2321            * Clears all associations between the user and its roles. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2322            *
2323            * @param pk the primary key of the user to clear the associated roles from
2324            */
2325            public void clearRoles(long pk);
2326    
2327            /**
2328            * Removes the association between the user and the role. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2329            *
2330            * @param pk the primary key of the user
2331            * @param rolePK the primary key of the role
2332            */
2333            public void removeRole(long pk, long rolePK);
2334    
2335            /**
2336            * Removes the association between the user and the role. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2337            *
2338            * @param pk the primary key of the user
2339            * @param role the role
2340            */
2341            public void removeRole(long pk, com.liferay.portal.kernel.model.Role role);
2342    
2343            /**
2344            * Removes the association between the user and the roles. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2345            *
2346            * @param pk the primary key of the user
2347            * @param rolePKs the primary keys of the roles
2348            */
2349            public void removeRoles(long pk, long[] rolePKs);
2350    
2351            /**
2352            * Removes the association between the user and the roles. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2353            *
2354            * @param pk the primary key of the user
2355            * @param roles the roles
2356            */
2357            public void removeRoles(long pk,
2358                    java.util.List<com.liferay.portal.kernel.model.Role> roles);
2359    
2360            /**
2361            * Sets the roles associated with the user, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2362            *
2363            * @param pk the primary key of the user
2364            * @param rolePKs the primary keys of the roles to be associated with the user
2365            */
2366            public void setRoles(long pk, long[] rolePKs);
2367    
2368            /**
2369            * Sets the roles associated with the user, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2370            *
2371            * @param pk the primary key of the user
2372            * @param roles the roles to be associated with the user
2373            */
2374            public void setRoles(long pk,
2375                    java.util.List<com.liferay.portal.kernel.model.Role> roles);
2376    
2377            /**
2378            * Returns the primaryKeys of teams associated with the user.
2379            *
2380            * @param pk the primary key of the user
2381            * @return long[] of the primaryKeys of teams associated with the user
2382            */
2383            public long[] getTeamPrimaryKeys(long pk);
2384    
2385            /**
2386            * Returns all the teams associated with the user.
2387            *
2388            * @param pk the primary key of the user
2389            * @return the teams associated with the user
2390            */
2391            public java.util.List<com.liferay.portal.kernel.model.Team> getTeams(
2392                    long pk);
2393    
2394            /**
2395            * Returns a range of all the teams associated with the user.
2396            *
2397            * <p>
2398            * 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 UserModelImpl}. 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.
2399            * </p>
2400            *
2401            * @param pk the primary key of the user
2402            * @param start the lower bound of the range of users
2403            * @param end the upper bound of the range of users (not inclusive)
2404            * @return the range of teams associated with the user
2405            */
2406            public java.util.List<com.liferay.portal.kernel.model.Team> getTeams(
2407                    long pk, int start, int end);
2408    
2409            /**
2410            * Returns an ordered range of all the teams associated with the user.
2411            *
2412            * <p>
2413            * 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 UserModelImpl}. 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.
2414            * </p>
2415            *
2416            * @param pk the primary key of the user
2417            * @param start the lower bound of the range of users
2418            * @param end the upper bound of the range of users (not inclusive)
2419            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
2420            * @return the ordered range of teams associated with the user
2421            */
2422            public java.util.List<com.liferay.portal.kernel.model.Team> getTeams(
2423                    long pk, int start, int end,
2424                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.kernel.model.Team> orderByComparator);
2425    
2426            /**
2427            * Returns the number of teams associated with the user.
2428            *
2429            * @param pk the primary key of the user
2430            * @return the number of teams associated with the user
2431            */
2432            public int getTeamsSize(long pk);
2433    
2434            /**
2435            * Returns <code>true</code> if the team is associated with the user.
2436            *
2437            * @param pk the primary key of the user
2438            * @param teamPK the primary key of the team
2439            * @return <code>true</code> if the team is associated with the user; <code>false</code> otherwise
2440            */
2441            public boolean containsTeam(long pk, long teamPK);
2442    
2443            /**
2444            * Returns <code>true</code> if the user has any teams associated with it.
2445            *
2446            * @param pk the primary key of the user to check for associations with teams
2447            * @return <code>true</code> if the user has any teams associated with it; <code>false</code> otherwise
2448            */
2449            public boolean containsTeams(long pk);
2450    
2451            /**
2452            * Adds an association between the user and the team. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2453            *
2454            * @param pk the primary key of the user
2455            * @param teamPK the primary key of the team
2456            */
2457            public void addTeam(long pk, long teamPK);
2458    
2459            /**
2460            * Adds an association between the user and the team. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2461            *
2462            * @param pk the primary key of the user
2463            * @param team the team
2464            */
2465            public void addTeam(long pk, com.liferay.portal.kernel.model.Team team);
2466    
2467            /**
2468            * Adds an association between the user and the teams. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2469            *
2470            * @param pk the primary key of the user
2471            * @param teamPKs the primary keys of the teams
2472            */
2473            public void addTeams(long pk, long[] teamPKs);
2474    
2475            /**
2476            * Adds an association between the user and the teams. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2477            *
2478            * @param pk the primary key of the user
2479            * @param teams the teams
2480            */
2481            public void addTeams(long pk,
2482                    java.util.List<com.liferay.portal.kernel.model.Team> teams);
2483    
2484            /**
2485            * Clears all associations between the user and its teams. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2486            *
2487            * @param pk the primary key of the user to clear the associated teams from
2488            */
2489            public void clearTeams(long pk);
2490    
2491            /**
2492            * Removes the association between the user and the team. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2493            *
2494            * @param pk the primary key of the user
2495            * @param teamPK the primary key of the team
2496            */
2497            public void removeTeam(long pk, long teamPK);
2498    
2499            /**
2500            * Removes the association between the user and the team. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2501            *
2502            * @param pk the primary key of the user
2503            * @param team the team
2504            */
2505            public void removeTeam(long pk, com.liferay.portal.kernel.model.Team team);
2506    
2507            /**
2508            * Removes the association between the user and the teams. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2509            *
2510            * @param pk the primary key of the user
2511            * @param teamPKs the primary keys of the teams
2512            */
2513            public void removeTeams(long pk, long[] teamPKs);
2514    
2515            /**
2516            * Removes the association between the user and the teams. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2517            *
2518            * @param pk the primary key of the user
2519            * @param teams the teams
2520            */
2521            public void removeTeams(long pk,
2522                    java.util.List<com.liferay.portal.kernel.model.Team> teams);
2523    
2524            /**
2525            * Sets the teams associated with the user, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2526            *
2527            * @param pk the primary key of the user
2528            * @param teamPKs the primary keys of the teams to be associated with the user
2529            */
2530            public void setTeams(long pk, long[] teamPKs);
2531    
2532            /**
2533            * Sets the teams associated with the user, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2534            *
2535            * @param pk the primary key of the user
2536            * @param teams the teams to be associated with the user
2537            */
2538            public void setTeams(long pk,
2539                    java.util.List<com.liferay.portal.kernel.model.Team> teams);
2540    
2541            /**
2542            * Returns the primaryKeys of user groups associated with the user.
2543            *
2544            * @param pk the primary key of the user
2545            * @return long[] of the primaryKeys of user groups associated with the user
2546            */
2547            public long[] getUserGroupPrimaryKeys(long pk);
2548    
2549            /**
2550            * Returns all the user groups associated with the user.
2551            *
2552            * @param pk the primary key of the user
2553            * @return the user groups associated with the user
2554            */
2555            public java.util.List<com.liferay.portal.kernel.model.UserGroup> getUserGroups(
2556                    long pk);
2557    
2558            /**
2559            * Returns a range of all the user groups associated with the user.
2560            *
2561            * <p>
2562            * 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 UserModelImpl}. 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.
2563            * </p>
2564            *
2565            * @param pk the primary key of the user
2566            * @param start the lower bound of the range of users
2567            * @param end the upper bound of the range of users (not inclusive)
2568            * @return the range of user groups associated with the user
2569            */
2570            public java.util.List<com.liferay.portal.kernel.model.UserGroup> getUserGroups(
2571                    long pk, int start, int end);
2572    
2573            /**
2574            * Returns an ordered range of all the user groups associated with the user.
2575            *
2576            * <p>
2577            * 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 UserModelImpl}. 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.
2578            * </p>
2579            *
2580            * @param pk the primary key of the user
2581            * @param start the lower bound of the range of users
2582            * @param end the upper bound of the range of users (not inclusive)
2583            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
2584            * @return the ordered range of user groups associated with the user
2585            */
2586            public java.util.List<com.liferay.portal.kernel.model.UserGroup> getUserGroups(
2587                    long pk, int start, int end,
2588                    com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.kernel.model.UserGroup> orderByComparator);
2589    
2590            /**
2591            * Returns the number of user groups associated with the user.
2592            *
2593            * @param pk the primary key of the user
2594            * @return the number of user groups associated with the user
2595            */
2596            public int getUserGroupsSize(long pk);
2597    
2598            /**
2599            * Returns <code>true</code> if the user group is associated with the user.
2600            *
2601            * @param pk the primary key of the user
2602            * @param userGroupPK the primary key of the user group
2603            * @return <code>true</code> if the user group is associated with the user; <code>false</code> otherwise
2604            */
2605            public boolean containsUserGroup(long pk, long userGroupPK);
2606    
2607            /**
2608            * Returns <code>true</code> if the user has any user groups associated with it.
2609            *
2610            * @param pk the primary key of the user to check for associations with user groups
2611            * @return <code>true</code> if the user has any user groups associated with it; <code>false</code> otherwise
2612            */
2613            public boolean containsUserGroups(long pk);
2614    
2615            /**
2616            * Adds an association between the user and the user group. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2617            *
2618            * @param pk the primary key of the user
2619            * @param userGroupPK the primary key of the user group
2620            */
2621            public void addUserGroup(long pk, long userGroupPK);
2622    
2623            /**
2624            * Adds an association between the user and the user group. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2625            *
2626            * @param pk the primary key of the user
2627            * @param userGroup the user group
2628            */
2629            public void addUserGroup(long pk,
2630                    com.liferay.portal.kernel.model.UserGroup userGroup);
2631    
2632            /**
2633            * Adds an association between the user and the user groups. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2634            *
2635            * @param pk the primary key of the user
2636            * @param userGroupPKs the primary keys of the user groups
2637            */
2638            public void addUserGroups(long pk, long[] userGroupPKs);
2639    
2640            /**
2641            * Adds an association between the user and the user groups. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2642            *
2643            * @param pk the primary key of the user
2644            * @param userGroups the user groups
2645            */
2646            public void addUserGroups(long pk,
2647                    java.util.List<com.liferay.portal.kernel.model.UserGroup> userGroups);
2648    
2649            /**
2650            * Clears all associations between the user and its user groups. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2651            *
2652            * @param pk the primary key of the user to clear the associated user groups from
2653            */
2654            public void clearUserGroups(long pk);
2655    
2656            /**
2657            * Removes the association between the user and the user group. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2658            *
2659            * @param pk the primary key of the user
2660            * @param userGroupPK the primary key of the user group
2661            */
2662            public void removeUserGroup(long pk, long userGroupPK);
2663    
2664            /**
2665            * Removes the association between the user and the user group. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2666            *
2667            * @param pk the primary key of the user
2668            * @param userGroup the user group
2669            */
2670            public void removeUserGroup(long pk,
2671                    com.liferay.portal.kernel.model.UserGroup userGroup);
2672    
2673            /**
2674            * Removes the association between the user and the user groups. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2675            *
2676            * @param pk the primary key of the user
2677            * @param userGroupPKs the primary keys of the user groups
2678            */
2679            public void removeUserGroups(long pk, long[] userGroupPKs);
2680    
2681            /**
2682            * Removes the association between the user and the user groups. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2683            *
2684            * @param pk the primary key of the user
2685            * @param userGroups the user groups
2686            */
2687            public void removeUserGroups(long pk,
2688                    java.util.List<com.liferay.portal.kernel.model.UserGroup> userGroups);
2689    
2690            /**
2691            * Sets the user groups associated with the user, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2692            *
2693            * @param pk the primary key of the user
2694            * @param userGroupPKs the primary keys of the user groups to be associated with the user
2695            */
2696            public void setUserGroups(long pk, long[] userGroupPKs);
2697    
2698            /**
2699            * Sets the user groups associated with the user, removing and adding associations as necessary. Also notifies the appropriate model listeners and clears the mapping table finder cache.
2700            *
2701            * @param pk the primary key of the user
2702            * @param userGroups the user groups to be associated with the user
2703            */
2704            public void setUserGroups(long pk,
2705                    java.util.List<com.liferay.portal.kernel.model.UserGroup> userGroups);
2706    
2707            @Override
2708            public java.util.Set<java.lang.String> getBadColumnNames();
2709    }