001 /** 002 * Copyright (c) 2000-present Liferay, Inc. All rights reserved. 003 * 004 * This library is free software; you can redistribute it and/or modify it under 005 * the terms of the GNU Lesser General Public License as published by the Free 006 * Software Foundation; either version 2.1 of the License, or (at your option) 007 * any later version. 008 * 009 * This library is distributed in the hope that it will be useful, but WITHOUT 010 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS 011 * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more 012 * details. 013 */ 014 015 package com.liferay.portal.kernel.service.persistence; 016 017 import aQute.bnd.annotation.ProviderType; 018 019 import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil; 020 import com.liferay.portal.kernel.dao.orm.DynamicQuery; 021 import com.liferay.portal.kernel.model.User; 022 import com.liferay.portal.kernel.service.ServiceContext; 023 import com.liferay.portal.kernel.util.OrderByComparator; 024 import com.liferay.portal.kernel.util.ReferenceRegistry; 025 026 import java.util.Date; 027 import java.util.List; 028 029 /** 030 * The persistence utility for the user service. This utility wraps {@link com.liferay.portal.service.persistence.impl.UserPersistenceImpl} and provides direct access to the database for CRUD operations. This utility should only be used by the service layer, as it must operate within a transaction. Never access this utility in a JSP, controller, model, or other front-end class. 031 * 032 * <p> 033 * Caching information and settings can be found in <code>portal.properties</code> 034 * </p> 035 * 036 * @author Brian Wing Shun Chan 037 * @see UserPersistence 038 * @see com.liferay.portal.service.persistence.impl.UserPersistenceImpl 039 * @generated 040 */ 041 @ProviderType 042 public class UserUtil { 043 /* 044 * NOTE FOR DEVELOPERS: 045 * 046 * Never modify this class directly. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this class. 047 */ 048 049 /** 050 * @see com.liferay.portal.kernel.service.persistence.BasePersistence#clearCache() 051 */ 052 public static void clearCache() { 053 getPersistence().clearCache(); 054 } 055 056 /** 057 * @see com.liferay.portal.kernel.service.persistence.BasePersistence#clearCache(com.liferay.portal.kernel.model.BaseModel) 058 */ 059 public static void clearCache(User user) { 060 getPersistence().clearCache(user); 061 } 062 063 /** 064 * @see com.liferay.portal.kernel.service.persistence.BasePersistence#countWithDynamicQuery(DynamicQuery) 065 */ 066 public static long countWithDynamicQuery(DynamicQuery dynamicQuery) { 067 return getPersistence().countWithDynamicQuery(dynamicQuery); 068 } 069 070 /** 071 * @see com.liferay.portal.kernel.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery) 072 */ 073 public static List<User> findWithDynamicQuery(DynamicQuery dynamicQuery) { 074 return getPersistence().findWithDynamicQuery(dynamicQuery); 075 } 076 077 /** 078 * @see com.liferay.portal.kernel.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int) 079 */ 080 public static List<User> findWithDynamicQuery(DynamicQuery dynamicQuery, 081 int start, int end) { 082 return getPersistence().findWithDynamicQuery(dynamicQuery, start, end); 083 } 084 085 /** 086 * @see com.liferay.portal.kernel.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int, OrderByComparator) 087 */ 088 public static List<User> findWithDynamicQuery(DynamicQuery dynamicQuery, 089 int start, int end, OrderByComparator<User> orderByComparator) { 090 return getPersistence() 091 .findWithDynamicQuery(dynamicQuery, start, end, 092 orderByComparator); 093 } 094 095 /** 096 * @see com.liferay.portal.kernel.service.persistence.BasePersistence#update(com.liferay.portal.kernel.model.BaseModel) 097 */ 098 public static User update(User user) { 099 return getPersistence().update(user); 100 } 101 102 /** 103 * @see com.liferay.portal.kernel.service.persistence.BasePersistence#update(com.liferay.portal.kernel.model.BaseModel, ServiceContext) 104 */ 105 public static User update(User user, ServiceContext serviceContext) { 106 return getPersistence().update(user, serviceContext); 107 } 108 109 /** 110 * Returns all the users where uuid = ?. 111 * 112 * @param uuid the uuid 113 * @return the matching users 114 */ 115 public static List<User> findByUuid(java.lang.String uuid) { 116 return getPersistence().findByUuid(uuid); 117 } 118 119 /** 120 * Returns a range of all the users where uuid = ?. 121 * 122 * <p> 123 * 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. 124 * </p> 125 * 126 * @param uuid the uuid 127 * @param start the lower bound of the range of users 128 * @param end the upper bound of the range of users (not inclusive) 129 * @return the range of matching users 130 */ 131 public static List<User> findByUuid(java.lang.String uuid, int start, 132 int end) { 133 return getPersistence().findByUuid(uuid, start, end); 134 } 135 136 /** 137 * Returns an ordered range of all the users where uuid = ?. 138 * 139 * <p> 140 * 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. 141 * </p> 142 * 143 * @param uuid the uuid 144 * @param start the lower bound of the range of users 145 * @param end the upper bound of the range of users (not inclusive) 146 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 147 * @return the ordered range of matching users 148 */ 149 public static List<User> findByUuid(java.lang.String uuid, int start, 150 int end, OrderByComparator<User> orderByComparator) { 151 return getPersistence().findByUuid(uuid, start, end, orderByComparator); 152 } 153 154 /** 155 * Returns an ordered range of all the users where uuid = ?. 156 * 157 * <p> 158 * 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. 159 * </p> 160 * 161 * @param uuid the uuid 162 * @param start the lower bound of the range of users 163 * @param end the upper bound of the range of users (not inclusive) 164 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 165 * @param retrieveFromCache whether to retrieve from the finder cache 166 * @return the ordered range of matching users 167 */ 168 public static List<User> findByUuid(java.lang.String uuid, int start, 169 int end, OrderByComparator<User> orderByComparator, 170 boolean retrieveFromCache) { 171 return getPersistence() 172 .findByUuid(uuid, start, end, orderByComparator, 173 retrieveFromCache); 174 } 175 176 /** 177 * Returns the first user in the ordered set where uuid = ?. 178 * 179 * @param uuid the uuid 180 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 181 * @return the first matching user 182 * @throws NoSuchUserException if a matching user could not be found 183 */ 184 public static User findByUuid_First(java.lang.String uuid, 185 OrderByComparator<User> orderByComparator) 186 throws com.liferay.portal.kernel.exception.NoSuchUserException { 187 return getPersistence().findByUuid_First(uuid, orderByComparator); 188 } 189 190 /** 191 * Returns the first user in the ordered set where uuid = ?. 192 * 193 * @param uuid the uuid 194 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 195 * @return the first matching user, or <code>null</code> if a matching user could not be found 196 */ 197 public static User fetchByUuid_First(java.lang.String uuid, 198 OrderByComparator<User> orderByComparator) { 199 return getPersistence().fetchByUuid_First(uuid, orderByComparator); 200 } 201 202 /** 203 * Returns the last user in the ordered set where uuid = ?. 204 * 205 * @param uuid the uuid 206 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 207 * @return the last matching user 208 * @throws NoSuchUserException if a matching user could not be found 209 */ 210 public static User findByUuid_Last(java.lang.String uuid, 211 OrderByComparator<User> orderByComparator) 212 throws com.liferay.portal.kernel.exception.NoSuchUserException { 213 return getPersistence().findByUuid_Last(uuid, orderByComparator); 214 } 215 216 /** 217 * Returns the last user in the ordered set where uuid = ?. 218 * 219 * @param uuid the uuid 220 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 221 * @return the last matching user, or <code>null</code> if a matching user could not be found 222 */ 223 public static User fetchByUuid_Last(java.lang.String uuid, 224 OrderByComparator<User> orderByComparator) { 225 return getPersistence().fetchByUuid_Last(uuid, orderByComparator); 226 } 227 228 /** 229 * Returns the users before and after the current user in the ordered set where uuid = ?. 230 * 231 * @param userId the primary key of the current user 232 * @param uuid the uuid 233 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 234 * @return the previous, current, and next user 235 * @throws NoSuchUserException if a user with the primary key could not be found 236 */ 237 public static User[] findByUuid_PrevAndNext(long userId, 238 java.lang.String uuid, OrderByComparator<User> orderByComparator) 239 throws com.liferay.portal.kernel.exception.NoSuchUserException { 240 return getPersistence() 241 .findByUuid_PrevAndNext(userId, uuid, orderByComparator); 242 } 243 244 /** 245 * Removes all the users where uuid = ? from the database. 246 * 247 * @param uuid the uuid 248 */ 249 public static void removeByUuid(java.lang.String uuid) { 250 getPersistence().removeByUuid(uuid); 251 } 252 253 /** 254 * Returns the number of users where uuid = ?. 255 * 256 * @param uuid the uuid 257 * @return the number of matching users 258 */ 259 public static int countByUuid(java.lang.String uuid) { 260 return getPersistence().countByUuid(uuid); 261 } 262 263 /** 264 * Returns all the users where uuid = ? and companyId = ?. 265 * 266 * @param uuid the uuid 267 * @param companyId the company ID 268 * @return the matching users 269 */ 270 public static List<User> findByUuid_C(java.lang.String uuid, long companyId) { 271 return getPersistence().findByUuid_C(uuid, companyId); 272 } 273 274 /** 275 * Returns a range of all the users where uuid = ? and companyId = ?. 276 * 277 * <p> 278 * 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. 279 * </p> 280 * 281 * @param uuid the uuid 282 * @param companyId the company ID 283 * @param start the lower bound of the range of users 284 * @param end the upper bound of the range of users (not inclusive) 285 * @return the range of matching users 286 */ 287 public static List<User> findByUuid_C(java.lang.String uuid, 288 long companyId, int start, int end) { 289 return getPersistence().findByUuid_C(uuid, companyId, start, end); 290 } 291 292 /** 293 * Returns an ordered range of all the users where uuid = ? and companyId = ?. 294 * 295 * <p> 296 * 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. 297 * </p> 298 * 299 * @param uuid the uuid 300 * @param companyId the company ID 301 * @param start the lower bound of the range of users 302 * @param end the upper bound of the range of users (not inclusive) 303 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 304 * @return the ordered range of matching users 305 */ 306 public static List<User> findByUuid_C(java.lang.String uuid, 307 long companyId, int start, int end, 308 OrderByComparator<User> orderByComparator) { 309 return getPersistence() 310 .findByUuid_C(uuid, companyId, start, end, orderByComparator); 311 } 312 313 /** 314 * Returns an ordered range of all the users where uuid = ? and companyId = ?. 315 * 316 * <p> 317 * 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. 318 * </p> 319 * 320 * @param uuid the uuid 321 * @param companyId the company ID 322 * @param start the lower bound of the range of users 323 * @param end the upper bound of the range of users (not inclusive) 324 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 325 * @param retrieveFromCache whether to retrieve from the finder cache 326 * @return the ordered range of matching users 327 */ 328 public static List<User> findByUuid_C(java.lang.String uuid, 329 long companyId, int start, int end, 330 OrderByComparator<User> orderByComparator, boolean retrieveFromCache) { 331 return getPersistence() 332 .findByUuid_C(uuid, companyId, start, end, 333 orderByComparator, retrieveFromCache); 334 } 335 336 /** 337 * Returns the first user in the ordered set where uuid = ? and companyId = ?. 338 * 339 * @param uuid the uuid 340 * @param companyId the company ID 341 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 342 * @return the first matching user 343 * @throws NoSuchUserException if a matching user could not be found 344 */ 345 public static User findByUuid_C_First(java.lang.String uuid, 346 long companyId, OrderByComparator<User> orderByComparator) 347 throws com.liferay.portal.kernel.exception.NoSuchUserException { 348 return getPersistence() 349 .findByUuid_C_First(uuid, companyId, orderByComparator); 350 } 351 352 /** 353 * Returns the first user in the ordered set where uuid = ? and companyId = ?. 354 * 355 * @param uuid the uuid 356 * @param companyId the company ID 357 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 358 * @return the first matching user, or <code>null</code> if a matching user could not be found 359 */ 360 public static User fetchByUuid_C_First(java.lang.String uuid, 361 long companyId, OrderByComparator<User> orderByComparator) { 362 return getPersistence() 363 .fetchByUuid_C_First(uuid, companyId, orderByComparator); 364 } 365 366 /** 367 * Returns the last user in the ordered set where uuid = ? and companyId = ?. 368 * 369 * @param uuid the uuid 370 * @param companyId the company ID 371 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 372 * @return the last matching user 373 * @throws NoSuchUserException if a matching user could not be found 374 */ 375 public static User findByUuid_C_Last(java.lang.String uuid, long companyId, 376 OrderByComparator<User> orderByComparator) 377 throws com.liferay.portal.kernel.exception.NoSuchUserException { 378 return getPersistence() 379 .findByUuid_C_Last(uuid, companyId, orderByComparator); 380 } 381 382 /** 383 * Returns the last user in the ordered set where uuid = ? and companyId = ?. 384 * 385 * @param uuid the uuid 386 * @param companyId the company ID 387 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 388 * @return the last matching user, or <code>null</code> if a matching user could not be found 389 */ 390 public static User fetchByUuid_C_Last(java.lang.String uuid, 391 long companyId, OrderByComparator<User> orderByComparator) { 392 return getPersistence() 393 .fetchByUuid_C_Last(uuid, companyId, orderByComparator); 394 } 395 396 /** 397 * Returns the users before and after the current user in the ordered set where uuid = ? and companyId = ?. 398 * 399 * @param userId the primary key of the current user 400 * @param uuid the uuid 401 * @param companyId the company ID 402 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 403 * @return the previous, current, and next user 404 * @throws NoSuchUserException if a user with the primary key could not be found 405 */ 406 public static User[] findByUuid_C_PrevAndNext(long userId, 407 java.lang.String uuid, long companyId, 408 OrderByComparator<User> orderByComparator) 409 throws com.liferay.portal.kernel.exception.NoSuchUserException { 410 return getPersistence() 411 .findByUuid_C_PrevAndNext(userId, uuid, companyId, 412 orderByComparator); 413 } 414 415 /** 416 * Removes all the users where uuid = ? and companyId = ? from the database. 417 * 418 * @param uuid the uuid 419 * @param companyId the company ID 420 */ 421 public static void removeByUuid_C(java.lang.String uuid, long companyId) { 422 getPersistence().removeByUuid_C(uuid, companyId); 423 } 424 425 /** 426 * Returns the number of users where uuid = ? and companyId = ?. 427 * 428 * @param uuid the uuid 429 * @param companyId the company ID 430 * @return the number of matching users 431 */ 432 public static int countByUuid_C(java.lang.String uuid, long companyId) { 433 return getPersistence().countByUuid_C(uuid, companyId); 434 } 435 436 /** 437 * Returns all the users where companyId = ?. 438 * 439 * @param companyId the company ID 440 * @return the matching users 441 */ 442 public static List<User> findByCompanyId(long companyId) { 443 return getPersistence().findByCompanyId(companyId); 444 } 445 446 /** 447 * Returns a range of all the users where companyId = ?. 448 * 449 * <p> 450 * 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. 451 * </p> 452 * 453 * @param companyId the company ID 454 * @param start the lower bound of the range of users 455 * @param end the upper bound of the range of users (not inclusive) 456 * @return the range of matching users 457 */ 458 public static List<User> findByCompanyId(long companyId, int start, int end) { 459 return getPersistence().findByCompanyId(companyId, start, end); 460 } 461 462 /** 463 * Returns an ordered range of all the users where companyId = ?. 464 * 465 * <p> 466 * 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. 467 * </p> 468 * 469 * @param companyId the company ID 470 * @param start the lower bound of the range of users 471 * @param end the upper bound of the range of users (not inclusive) 472 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 473 * @return the ordered range of matching users 474 */ 475 public static List<User> findByCompanyId(long companyId, int start, 476 int end, OrderByComparator<User> orderByComparator) { 477 return getPersistence() 478 .findByCompanyId(companyId, start, end, orderByComparator); 479 } 480 481 /** 482 * Returns an ordered range of all the users where companyId = ?. 483 * 484 * <p> 485 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link 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. 486 * </p> 487 * 488 * @param companyId the company ID 489 * @param start the lower bound of the range of users 490 * @param end the upper bound of the range of users (not inclusive) 491 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 492 * @param retrieveFromCache whether to retrieve from the finder cache 493 * @return the ordered range of matching users 494 */ 495 public static List<User> findByCompanyId(long companyId, int start, 496 int end, OrderByComparator<User> orderByComparator, 497 boolean retrieveFromCache) { 498 return getPersistence() 499 .findByCompanyId(companyId, start, end, orderByComparator, 500 retrieveFromCache); 501 } 502 503 /** 504 * Returns the first user in the ordered set where companyId = ?. 505 * 506 * @param companyId the company ID 507 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 508 * @return the first matching user 509 * @throws NoSuchUserException if a matching user could not be found 510 */ 511 public static User findByCompanyId_First(long companyId, 512 OrderByComparator<User> orderByComparator) 513 throws com.liferay.portal.kernel.exception.NoSuchUserException { 514 return getPersistence() 515 .findByCompanyId_First(companyId, orderByComparator); 516 } 517 518 /** 519 * Returns the first user in the ordered set where companyId = ?. 520 * 521 * @param companyId the company ID 522 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 523 * @return the first matching user, or <code>null</code> if a matching user could not be found 524 */ 525 public static User fetchByCompanyId_First(long companyId, 526 OrderByComparator<User> orderByComparator) { 527 return getPersistence() 528 .fetchByCompanyId_First(companyId, orderByComparator); 529 } 530 531 /** 532 * Returns the last user in the ordered set where companyId = ?. 533 * 534 * @param companyId the company ID 535 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 536 * @return the last matching user 537 * @throws NoSuchUserException if a matching user could not be found 538 */ 539 public static User findByCompanyId_Last(long companyId, 540 OrderByComparator<User> orderByComparator) 541 throws com.liferay.portal.kernel.exception.NoSuchUserException { 542 return getPersistence() 543 .findByCompanyId_Last(companyId, orderByComparator); 544 } 545 546 /** 547 * Returns the last user in the ordered set where companyId = ?. 548 * 549 * @param companyId the company ID 550 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 551 * @return the last matching user, or <code>null</code> if a matching user could not be found 552 */ 553 public static User fetchByCompanyId_Last(long companyId, 554 OrderByComparator<User> orderByComparator) { 555 return getPersistence() 556 .fetchByCompanyId_Last(companyId, orderByComparator); 557 } 558 559 /** 560 * Returns the users before and after the current user in the ordered set where companyId = ?. 561 * 562 * @param userId the primary key of the current user 563 * @param companyId the company ID 564 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 565 * @return the previous, current, and next user 566 * @throws NoSuchUserException if a user with the primary key could not be found 567 */ 568 public static User[] findByCompanyId_PrevAndNext(long userId, 569 long companyId, OrderByComparator<User> orderByComparator) 570 throws com.liferay.portal.kernel.exception.NoSuchUserException { 571 return getPersistence() 572 .findByCompanyId_PrevAndNext(userId, companyId, 573 orderByComparator); 574 } 575 576 /** 577 * Removes all the users where companyId = ? from the database. 578 * 579 * @param companyId the company ID 580 */ 581 public static void removeByCompanyId(long companyId) { 582 getPersistence().removeByCompanyId(companyId); 583 } 584 585 /** 586 * Returns the number of users where companyId = ?. 587 * 588 * @param companyId the company ID 589 * @return the number of matching users 590 */ 591 public static int countByCompanyId(long companyId) { 592 return getPersistence().countByCompanyId(companyId); 593 } 594 595 /** 596 * Returns the user where contactId = ? or throws a {@link NoSuchUserException} if it could not be found. 597 * 598 * @param contactId the contact ID 599 * @return the matching user 600 * @throws NoSuchUserException if a matching user could not be found 601 */ 602 public static User findByContactId(long contactId) 603 throws com.liferay.portal.kernel.exception.NoSuchUserException { 604 return getPersistence().findByContactId(contactId); 605 } 606 607 /** 608 * Returns the user where contactId = ? or returns <code>null</code> if it could not be found. Uses the finder cache. 609 * 610 * @param contactId the contact ID 611 * @return the matching user, or <code>null</code> if a matching user could not be found 612 */ 613 public static User fetchByContactId(long contactId) { 614 return getPersistence().fetchByContactId(contactId); 615 } 616 617 /** 618 * Returns the user where contactId = ? or returns <code>null</code> if it could not be found, optionally using the finder cache. 619 * 620 * @param contactId the contact ID 621 * @param retrieveFromCache whether to retrieve from the finder cache 622 * @return the matching user, or <code>null</code> if a matching user could not be found 623 */ 624 public static User fetchByContactId(long contactId, 625 boolean retrieveFromCache) { 626 return getPersistence().fetchByContactId(contactId, retrieveFromCache); 627 } 628 629 /** 630 * Removes the user where contactId = ? from the database. 631 * 632 * @param contactId the contact ID 633 * @return the user that was removed 634 */ 635 public static User removeByContactId(long contactId) 636 throws com.liferay.portal.kernel.exception.NoSuchUserException { 637 return getPersistence().removeByContactId(contactId); 638 } 639 640 /** 641 * Returns the number of users where contactId = ?. 642 * 643 * @param contactId the contact ID 644 * @return the number of matching users 645 */ 646 public static int countByContactId(long contactId) { 647 return getPersistence().countByContactId(contactId); 648 } 649 650 /** 651 * Returns all the users where emailAddress = ?. 652 * 653 * @param emailAddress the email address 654 * @return the matching users 655 */ 656 public static List<User> findByEmailAddress(java.lang.String emailAddress) { 657 return getPersistence().findByEmailAddress(emailAddress); 658 } 659 660 /** 661 * Returns a range of all the users where emailAddress = ?. 662 * 663 * <p> 664 * 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. 665 * </p> 666 * 667 * @param emailAddress the email address 668 * @param start the lower bound of the range of users 669 * @param end the upper bound of the range of users (not inclusive) 670 * @return the range of matching users 671 */ 672 public static List<User> findByEmailAddress(java.lang.String emailAddress, 673 int start, int end) { 674 return getPersistence().findByEmailAddress(emailAddress, start, end); 675 } 676 677 /** 678 * Returns an ordered range of all the users where emailAddress = ?. 679 * 680 * <p> 681 * 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. 682 * </p> 683 * 684 * @param emailAddress the email address 685 * @param start the lower bound of the range of users 686 * @param end the upper bound of the range of users (not inclusive) 687 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 688 * @return the ordered range of matching users 689 */ 690 public static List<User> findByEmailAddress(java.lang.String emailAddress, 691 int start, int end, OrderByComparator<User> orderByComparator) { 692 return getPersistence() 693 .findByEmailAddress(emailAddress, start, end, 694 orderByComparator); 695 } 696 697 /** 698 * Returns an ordered range of all the users where emailAddress = ?. 699 * 700 * <p> 701 * 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. 702 * </p> 703 * 704 * @param emailAddress the email address 705 * @param start the lower bound of the range of users 706 * @param end the upper bound of the range of users (not inclusive) 707 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 708 * @param retrieveFromCache whether to retrieve from the finder cache 709 * @return the ordered range of matching users 710 */ 711 public static List<User> findByEmailAddress(java.lang.String emailAddress, 712 int start, int end, OrderByComparator<User> orderByComparator, 713 boolean retrieveFromCache) { 714 return getPersistence() 715 .findByEmailAddress(emailAddress, start, end, 716 orderByComparator, retrieveFromCache); 717 } 718 719 /** 720 * Returns the first user in the ordered set where emailAddress = ?. 721 * 722 * @param emailAddress the email address 723 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 724 * @return the first matching user 725 * @throws NoSuchUserException if a matching user could not be found 726 */ 727 public static User findByEmailAddress_First(java.lang.String emailAddress, 728 OrderByComparator<User> orderByComparator) 729 throws com.liferay.portal.kernel.exception.NoSuchUserException { 730 return getPersistence() 731 .findByEmailAddress_First(emailAddress, orderByComparator); 732 } 733 734 /** 735 * Returns the first user in the ordered set where emailAddress = ?. 736 * 737 * @param emailAddress the email address 738 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 739 * @return the first matching user, or <code>null</code> if a matching user could not be found 740 */ 741 public static User fetchByEmailAddress_First( 742 java.lang.String emailAddress, OrderByComparator<User> orderByComparator) { 743 return getPersistence() 744 .fetchByEmailAddress_First(emailAddress, orderByComparator); 745 } 746 747 /** 748 * Returns the last user in the ordered set where emailAddress = ?. 749 * 750 * @param emailAddress the email address 751 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 752 * @return the last matching user 753 * @throws NoSuchUserException if a matching user could not be found 754 */ 755 public static User findByEmailAddress_Last(java.lang.String emailAddress, 756 OrderByComparator<User> orderByComparator) 757 throws com.liferay.portal.kernel.exception.NoSuchUserException { 758 return getPersistence() 759 .findByEmailAddress_Last(emailAddress, orderByComparator); 760 } 761 762 /** 763 * Returns the last user in the ordered set where emailAddress = ?. 764 * 765 * @param emailAddress the email address 766 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 767 * @return the last matching user, or <code>null</code> if a matching user could not be found 768 */ 769 public static User fetchByEmailAddress_Last(java.lang.String emailAddress, 770 OrderByComparator<User> orderByComparator) { 771 return getPersistence() 772 .fetchByEmailAddress_Last(emailAddress, orderByComparator); 773 } 774 775 /** 776 * Returns the users before and after the current user in the ordered set where emailAddress = ?. 777 * 778 * @param userId the primary key of the current user 779 * @param emailAddress the email address 780 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 781 * @return the previous, current, and next user 782 * @throws NoSuchUserException if a user with the primary key could not be found 783 */ 784 public static User[] findByEmailAddress_PrevAndNext(long userId, 785 java.lang.String emailAddress, OrderByComparator<User> orderByComparator) 786 throws com.liferay.portal.kernel.exception.NoSuchUserException { 787 return getPersistence() 788 .findByEmailAddress_PrevAndNext(userId, emailAddress, 789 orderByComparator); 790 } 791 792 /** 793 * Removes all the users where emailAddress = ? from the database. 794 * 795 * @param emailAddress the email address 796 */ 797 public static void removeByEmailAddress(java.lang.String emailAddress) { 798 getPersistence().removeByEmailAddress(emailAddress); 799 } 800 801 /** 802 * Returns the number of users where emailAddress = ?. 803 * 804 * @param emailAddress the email address 805 * @return the number of matching users 806 */ 807 public static int countByEmailAddress(java.lang.String emailAddress) { 808 return getPersistence().countByEmailAddress(emailAddress); 809 } 810 811 /** 812 * Returns the user where portraitId = ? or throws a {@link NoSuchUserException} if it could not be found. 813 * 814 * @param portraitId the portrait ID 815 * @return the matching user 816 * @throws NoSuchUserException if a matching user could not be found 817 */ 818 public static User findByPortraitId(long portraitId) 819 throws com.liferay.portal.kernel.exception.NoSuchUserException { 820 return getPersistence().findByPortraitId(portraitId); 821 } 822 823 /** 824 * Returns the user where portraitId = ? or returns <code>null</code> if it could not be found. Uses the finder cache. 825 * 826 * @param portraitId the portrait ID 827 * @return the matching user, or <code>null</code> if a matching user could not be found 828 */ 829 public static User fetchByPortraitId(long portraitId) { 830 return getPersistence().fetchByPortraitId(portraitId); 831 } 832 833 /** 834 * Returns the user where portraitId = ? or returns <code>null</code> if it could not be found, optionally using the finder cache. 835 * 836 * @param portraitId the portrait ID 837 * @param retrieveFromCache whether to retrieve from the finder cache 838 * @return the matching user, or <code>null</code> if a matching user could not be found 839 */ 840 public static User fetchByPortraitId(long portraitId, 841 boolean retrieveFromCache) { 842 return getPersistence().fetchByPortraitId(portraitId, retrieveFromCache); 843 } 844 845 /** 846 * Removes the user where portraitId = ? from the database. 847 * 848 * @param portraitId the portrait ID 849 * @return the user that was removed 850 */ 851 public static User removeByPortraitId(long portraitId) 852 throws com.liferay.portal.kernel.exception.NoSuchUserException { 853 return getPersistence().removeByPortraitId(portraitId); 854 } 855 856 /** 857 * Returns the number of users where portraitId = ?. 858 * 859 * @param portraitId the portrait ID 860 * @return the number of matching users 861 */ 862 public static int countByPortraitId(long portraitId) { 863 return getPersistence().countByPortraitId(portraitId); 864 } 865 866 /** 867 * Returns the user where companyId = ? and userId = ? or throws a {@link NoSuchUserException} if it could not be found. 868 * 869 * @param companyId the company ID 870 * @param userId the user ID 871 * @return the matching user 872 * @throws NoSuchUserException if a matching user could not be found 873 */ 874 public static User findByC_U(long companyId, long userId) 875 throws com.liferay.portal.kernel.exception.NoSuchUserException { 876 return getPersistence().findByC_U(companyId, userId); 877 } 878 879 /** 880 * Returns the user where companyId = ? and userId = ? or returns <code>null</code> if it could not be found. Uses the finder cache. 881 * 882 * @param companyId the company ID 883 * @param userId the user ID 884 * @return the matching user, or <code>null</code> if a matching user could not be found 885 */ 886 public static User fetchByC_U(long companyId, long userId) { 887 return getPersistence().fetchByC_U(companyId, userId); 888 } 889 890 /** 891 * Returns the user where companyId = ? and userId = ? or returns <code>null</code> if it could not be found, optionally using the finder cache. 892 * 893 * @param companyId the company ID 894 * @param userId the user ID 895 * @param retrieveFromCache whether to retrieve from the finder cache 896 * @return the matching user, or <code>null</code> if a matching user could not be found 897 */ 898 public static User fetchByC_U(long companyId, long userId, 899 boolean retrieveFromCache) { 900 return getPersistence().fetchByC_U(companyId, userId, retrieveFromCache); 901 } 902 903 /** 904 * Removes the user where companyId = ? and userId = ? from the database. 905 * 906 * @param companyId the company ID 907 * @param userId the user ID 908 * @return the user that was removed 909 */ 910 public static User removeByC_U(long companyId, long userId) 911 throws com.liferay.portal.kernel.exception.NoSuchUserException { 912 return getPersistence().removeByC_U(companyId, userId); 913 } 914 915 /** 916 * Returns the number of users where companyId = ? and userId = ?. 917 * 918 * @param companyId the company ID 919 * @param userId the user ID 920 * @return the number of matching users 921 */ 922 public static int countByC_U(long companyId, long userId) { 923 return getPersistence().countByC_U(companyId, userId); 924 } 925 926 /** 927 * Returns all the users where companyId = ? and createDate = ?. 928 * 929 * @param companyId the company ID 930 * @param createDate the create date 931 * @return the matching users 932 */ 933 public static List<User> findByC_CD(long companyId, Date createDate) { 934 return getPersistence().findByC_CD(companyId, createDate); 935 } 936 937 /** 938 * Returns a range of all the users where companyId = ? and createDate = ?. 939 * 940 * <p> 941 * 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. 942 * </p> 943 * 944 * @param companyId the company ID 945 * @param createDate the create date 946 * @param start the lower bound of the range of users 947 * @param end the upper bound of the range of users (not inclusive) 948 * @return the range of matching users 949 */ 950 public static List<User> findByC_CD(long companyId, Date createDate, 951 int start, int end) { 952 return getPersistence().findByC_CD(companyId, createDate, start, end); 953 } 954 955 /** 956 * Returns an ordered range of all the users where companyId = ? and createDate = ?. 957 * 958 * <p> 959 * 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. 960 * </p> 961 * 962 * @param companyId the company ID 963 * @param createDate the create date 964 * @param start the lower bound of the range of users 965 * @param end the upper bound of the range of users (not inclusive) 966 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 967 * @return the ordered range of matching users 968 */ 969 public static List<User> findByC_CD(long companyId, Date createDate, 970 int start, int end, OrderByComparator<User> orderByComparator) { 971 return getPersistence() 972 .findByC_CD(companyId, createDate, start, end, 973 orderByComparator); 974 } 975 976 /** 977 * Returns an ordered range of all the users where companyId = ? and createDate = ?. 978 * 979 * <p> 980 * 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. 981 * </p> 982 * 983 * @param companyId the company ID 984 * @param createDate the create date 985 * @param start the lower bound of the range of users 986 * @param end the upper bound of the range of users (not inclusive) 987 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 988 * @param retrieveFromCache whether to retrieve from the finder cache 989 * @return the ordered range of matching users 990 */ 991 public static List<User> findByC_CD(long companyId, Date createDate, 992 int start, int end, OrderByComparator<User> orderByComparator, 993 boolean retrieveFromCache) { 994 return getPersistence() 995 .findByC_CD(companyId, createDate, start, end, 996 orderByComparator, retrieveFromCache); 997 } 998 999 /** 1000 * Returns the first user in the ordered set where companyId = ? and createDate = ?. 1001 * 1002 * @param companyId the company ID 1003 * @param createDate the create date 1004 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 1005 * @return the first matching user 1006 * @throws NoSuchUserException if a matching user could not be found 1007 */ 1008 public static User findByC_CD_First(long companyId, Date createDate, 1009 OrderByComparator<User> orderByComparator) 1010 throws com.liferay.portal.kernel.exception.NoSuchUserException { 1011 return getPersistence() 1012 .findByC_CD_First(companyId, createDate, orderByComparator); 1013 } 1014 1015 /** 1016 * Returns the first user in the ordered set where companyId = ? and createDate = ?. 1017 * 1018 * @param companyId the company ID 1019 * @param createDate the create date 1020 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 1021 * @return the first matching user, or <code>null</code> if a matching user could not be found 1022 */ 1023 public static User fetchByC_CD_First(long companyId, Date createDate, 1024 OrderByComparator<User> orderByComparator) { 1025 return getPersistence() 1026 .fetchByC_CD_First(companyId, createDate, orderByComparator); 1027 } 1028 1029 /** 1030 * Returns the last user in the ordered set where companyId = ? and createDate = ?. 1031 * 1032 * @param companyId the company ID 1033 * @param createDate the create date 1034 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 1035 * @return the last matching user 1036 * @throws NoSuchUserException if a matching user could not be found 1037 */ 1038 public static User findByC_CD_Last(long companyId, Date createDate, 1039 OrderByComparator<User> orderByComparator) 1040 throws com.liferay.portal.kernel.exception.NoSuchUserException { 1041 return getPersistence() 1042 .findByC_CD_Last(companyId, createDate, orderByComparator); 1043 } 1044 1045 /** 1046 * Returns the last user in the ordered set where companyId = ? and createDate = ?. 1047 * 1048 * @param companyId the company ID 1049 * @param createDate the create date 1050 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 1051 * @return the last matching user, or <code>null</code> if a matching user could not be found 1052 */ 1053 public static User fetchByC_CD_Last(long companyId, Date createDate, 1054 OrderByComparator<User> orderByComparator) { 1055 return getPersistence() 1056 .fetchByC_CD_Last(companyId, createDate, orderByComparator); 1057 } 1058 1059 /** 1060 * Returns the users before and after the current user in the ordered set where companyId = ? and createDate = ?. 1061 * 1062 * @param userId the primary key of the current user 1063 * @param companyId the company ID 1064 * @param createDate the create date 1065 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 1066 * @return the previous, current, and next user 1067 * @throws NoSuchUserException if a user with the primary key could not be found 1068 */ 1069 public static User[] findByC_CD_PrevAndNext(long userId, long companyId, 1070 Date createDate, OrderByComparator<User> orderByComparator) 1071 throws com.liferay.portal.kernel.exception.NoSuchUserException { 1072 return getPersistence() 1073 .findByC_CD_PrevAndNext(userId, companyId, createDate, 1074 orderByComparator); 1075 } 1076 1077 /** 1078 * Removes all the users where companyId = ? and createDate = ? from the database. 1079 * 1080 * @param companyId the company ID 1081 * @param createDate the create date 1082 */ 1083 public static void removeByC_CD(long companyId, Date createDate) { 1084 getPersistence().removeByC_CD(companyId, createDate); 1085 } 1086 1087 /** 1088 * Returns the number of users where companyId = ? and createDate = ?. 1089 * 1090 * @param companyId the company ID 1091 * @param createDate the create date 1092 * @return the number of matching users 1093 */ 1094 public static int countByC_CD(long companyId, Date createDate) { 1095 return getPersistence().countByC_CD(companyId, createDate); 1096 } 1097 1098 /** 1099 * Returns all the users where companyId = ? and modifiedDate = ?. 1100 * 1101 * @param companyId the company ID 1102 * @param modifiedDate the modified date 1103 * @return the matching users 1104 */ 1105 public static List<User> findByC_MD(long companyId, Date modifiedDate) { 1106 return getPersistence().findByC_MD(companyId, modifiedDate); 1107 } 1108 1109 /** 1110 * Returns a range of all the users where companyId = ? and modifiedDate = ?. 1111 * 1112 * <p> 1113 * 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. 1114 * </p> 1115 * 1116 * @param companyId the company ID 1117 * @param modifiedDate the modified date 1118 * @param start the lower bound of the range of users 1119 * @param end the upper bound of the range of users (not inclusive) 1120 * @return the range of matching users 1121 */ 1122 public static List<User> findByC_MD(long companyId, Date modifiedDate, 1123 int start, int end) { 1124 return getPersistence().findByC_MD(companyId, modifiedDate, start, end); 1125 } 1126 1127 /** 1128 * Returns an ordered range of all the users where companyId = ? and modifiedDate = ?. 1129 * 1130 * <p> 1131 * 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. 1132 * </p> 1133 * 1134 * @param companyId the company ID 1135 * @param modifiedDate the modified date 1136 * @param start the lower bound of the range of users 1137 * @param end the upper bound of the range of users (not inclusive) 1138 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 1139 * @return the ordered range of matching users 1140 */ 1141 public static List<User> findByC_MD(long companyId, Date modifiedDate, 1142 int start, int end, OrderByComparator<User> orderByComparator) { 1143 return getPersistence() 1144 .findByC_MD(companyId, modifiedDate, start, end, 1145 orderByComparator); 1146 } 1147 1148 /** 1149 * Returns an ordered range of all the users where companyId = ? and modifiedDate = ?. 1150 * 1151 * <p> 1152 * 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. 1153 * </p> 1154 * 1155 * @param companyId the company ID 1156 * @param modifiedDate the modified date 1157 * @param start the lower bound of the range of users 1158 * @param end the upper bound of the range of users (not inclusive) 1159 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 1160 * @param retrieveFromCache whether to retrieve from the finder cache 1161 * @return the ordered range of matching users 1162 */ 1163 public static List<User> findByC_MD(long companyId, Date modifiedDate, 1164 int start, int end, OrderByComparator<User> orderByComparator, 1165 boolean retrieveFromCache) { 1166 return getPersistence() 1167 .findByC_MD(companyId, modifiedDate, start, end, 1168 orderByComparator, retrieveFromCache); 1169 } 1170 1171 /** 1172 * Returns the first user in the ordered set where companyId = ? and modifiedDate = ?. 1173 * 1174 * @param companyId the company ID 1175 * @param modifiedDate the modified date 1176 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 1177 * @return the first matching user 1178 * @throws NoSuchUserException if a matching user could not be found 1179 */ 1180 public static User findByC_MD_First(long companyId, Date modifiedDate, 1181 OrderByComparator<User> orderByComparator) 1182 throws com.liferay.portal.kernel.exception.NoSuchUserException { 1183 return getPersistence() 1184 .findByC_MD_First(companyId, modifiedDate, orderByComparator); 1185 } 1186 1187 /** 1188 * Returns the first user in the ordered set where companyId = ? and modifiedDate = ?. 1189 * 1190 * @param companyId the company ID 1191 * @param modifiedDate the modified date 1192 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 1193 * @return the first matching user, or <code>null</code> if a matching user could not be found 1194 */ 1195 public static User fetchByC_MD_First(long companyId, Date modifiedDate, 1196 OrderByComparator<User> orderByComparator) { 1197 return getPersistence() 1198 .fetchByC_MD_First(companyId, modifiedDate, orderByComparator); 1199 } 1200 1201 /** 1202 * Returns the last user in the ordered set where companyId = ? and modifiedDate = ?. 1203 * 1204 * @param companyId the company ID 1205 * @param modifiedDate the modified date 1206 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 1207 * @return the last matching user 1208 * @throws NoSuchUserException if a matching user could not be found 1209 */ 1210 public static User findByC_MD_Last(long companyId, Date modifiedDate, 1211 OrderByComparator<User> orderByComparator) 1212 throws com.liferay.portal.kernel.exception.NoSuchUserException { 1213 return getPersistence() 1214 .findByC_MD_Last(companyId, modifiedDate, orderByComparator); 1215 } 1216 1217 /** 1218 * Returns the last user in the ordered set where companyId = ? and modifiedDate = ?. 1219 * 1220 * @param companyId the company ID 1221 * @param modifiedDate the modified date 1222 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 1223 * @return the last matching user, or <code>null</code> if a matching user could not be found 1224 */ 1225 public static User fetchByC_MD_Last(long companyId, Date modifiedDate, 1226 OrderByComparator<User> orderByComparator) { 1227 return getPersistence() 1228 .fetchByC_MD_Last(companyId, modifiedDate, orderByComparator); 1229 } 1230 1231 /** 1232 * Returns the users before and after the current user in the ordered set where companyId = ? and modifiedDate = ?. 1233 * 1234 * @param userId the primary key of the current user 1235 * @param companyId the company ID 1236 * @param modifiedDate the modified date 1237 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 1238 * @return the previous, current, and next user 1239 * @throws NoSuchUserException if a user with the primary key could not be found 1240 */ 1241 public static User[] findByC_MD_PrevAndNext(long userId, long companyId, 1242 Date modifiedDate, OrderByComparator<User> orderByComparator) 1243 throws com.liferay.portal.kernel.exception.NoSuchUserException { 1244 return getPersistence() 1245 .findByC_MD_PrevAndNext(userId, companyId, modifiedDate, 1246 orderByComparator); 1247 } 1248 1249 /** 1250 * Removes all the users where companyId = ? and modifiedDate = ? from the database. 1251 * 1252 * @param companyId the company ID 1253 * @param modifiedDate the modified date 1254 */ 1255 public static void removeByC_MD(long companyId, Date modifiedDate) { 1256 getPersistence().removeByC_MD(companyId, modifiedDate); 1257 } 1258 1259 /** 1260 * Returns the number of users where companyId = ? and modifiedDate = ?. 1261 * 1262 * @param companyId the company ID 1263 * @param modifiedDate the modified date 1264 * @return the number of matching users 1265 */ 1266 public static int countByC_MD(long companyId, Date modifiedDate) { 1267 return getPersistence().countByC_MD(companyId, modifiedDate); 1268 } 1269 1270 /** 1271 * Returns the user where companyId = ? and defaultUser = ? or throws a {@link NoSuchUserException} if it could not be found. 1272 * 1273 * @param companyId the company ID 1274 * @param defaultUser the default user 1275 * @return the matching user 1276 * @throws NoSuchUserException if a matching user could not be found 1277 */ 1278 public static User findByC_DU(long companyId, boolean defaultUser) 1279 throws com.liferay.portal.kernel.exception.NoSuchUserException { 1280 return getPersistence().findByC_DU(companyId, defaultUser); 1281 } 1282 1283 /** 1284 * Returns the user where companyId = ? and defaultUser = ? or returns <code>null</code> if it could not be found. Uses the finder cache. 1285 * 1286 * @param companyId the company ID 1287 * @param defaultUser the default user 1288 * @return the matching user, or <code>null</code> if a matching user could not be found 1289 */ 1290 public static User fetchByC_DU(long companyId, boolean defaultUser) { 1291 return getPersistence().fetchByC_DU(companyId, defaultUser); 1292 } 1293 1294 /** 1295 * Returns the user where companyId = ? and defaultUser = ? or returns <code>null</code> if it could not be found, optionally using the finder cache. 1296 * 1297 * @param companyId the company ID 1298 * @param defaultUser the default user 1299 * @param retrieveFromCache whether to retrieve from the finder cache 1300 * @return the matching user, or <code>null</code> if a matching user could not be found 1301 */ 1302 public static User fetchByC_DU(long companyId, boolean defaultUser, 1303 boolean retrieveFromCache) { 1304 return getPersistence() 1305 .fetchByC_DU(companyId, defaultUser, retrieveFromCache); 1306 } 1307 1308 /** 1309 * Removes the user where companyId = ? and defaultUser = ? from the database. 1310 * 1311 * @param companyId the company ID 1312 * @param defaultUser the default user 1313 * @return the user that was removed 1314 */ 1315 public static User removeByC_DU(long companyId, boolean defaultUser) 1316 throws com.liferay.portal.kernel.exception.NoSuchUserException { 1317 return getPersistence().removeByC_DU(companyId, defaultUser); 1318 } 1319 1320 /** 1321 * Returns the number of users where companyId = ? and defaultUser = ?. 1322 * 1323 * @param companyId the company ID 1324 * @param defaultUser the default user 1325 * @return the number of matching users 1326 */ 1327 public static int countByC_DU(long companyId, boolean defaultUser) { 1328 return getPersistence().countByC_DU(companyId, defaultUser); 1329 } 1330 1331 /** 1332 * Returns the user where companyId = ? and screenName = ? or throws a {@link NoSuchUserException} if it could not be found. 1333 * 1334 * @param companyId the company ID 1335 * @param screenName the screen name 1336 * @return the matching user 1337 * @throws NoSuchUserException if a matching user could not be found 1338 */ 1339 public static User findByC_SN(long companyId, java.lang.String screenName) 1340 throws com.liferay.portal.kernel.exception.NoSuchUserException { 1341 return getPersistence().findByC_SN(companyId, screenName); 1342 } 1343 1344 /** 1345 * Returns the user where companyId = ? and screenName = ? or returns <code>null</code> if it could not be found. Uses the finder cache. 1346 * 1347 * @param companyId the company ID 1348 * @param screenName the screen name 1349 * @return the matching user, or <code>null</code> if a matching user could not be found 1350 */ 1351 public static User fetchByC_SN(long companyId, java.lang.String screenName) { 1352 return getPersistence().fetchByC_SN(companyId, screenName); 1353 } 1354 1355 /** 1356 * Returns the user where companyId = ? and screenName = ? or returns <code>null</code> if it could not be found, optionally using the finder cache. 1357 * 1358 * @param companyId the company ID 1359 * @param screenName the screen name 1360 * @param retrieveFromCache whether to retrieve from the finder cache 1361 * @return the matching user, or <code>null</code> if a matching user could not be found 1362 */ 1363 public static User fetchByC_SN(long companyId, java.lang.String screenName, 1364 boolean retrieveFromCache) { 1365 return getPersistence() 1366 .fetchByC_SN(companyId, screenName, retrieveFromCache); 1367 } 1368 1369 /** 1370 * Removes the user where companyId = ? and screenName = ? from the database. 1371 * 1372 * @param companyId the company ID 1373 * @param screenName the screen name 1374 * @return the user that was removed 1375 */ 1376 public static User removeByC_SN(long companyId, java.lang.String screenName) 1377 throws com.liferay.portal.kernel.exception.NoSuchUserException { 1378 return getPersistence().removeByC_SN(companyId, screenName); 1379 } 1380 1381 /** 1382 * Returns the number of users where companyId = ? and screenName = ?. 1383 * 1384 * @param companyId the company ID 1385 * @param screenName the screen name 1386 * @return the number of matching users 1387 */ 1388 public static int countByC_SN(long companyId, java.lang.String screenName) { 1389 return getPersistence().countByC_SN(companyId, screenName); 1390 } 1391 1392 /** 1393 * Returns the user where companyId = ? and emailAddress = ? or throws a {@link NoSuchUserException} if it could not be found. 1394 * 1395 * @param companyId the company ID 1396 * @param emailAddress the email address 1397 * @return the matching user 1398 * @throws NoSuchUserException if a matching user could not be found 1399 */ 1400 public static User findByC_EA(long companyId, java.lang.String emailAddress) 1401 throws com.liferay.portal.kernel.exception.NoSuchUserException { 1402 return getPersistence().findByC_EA(companyId, emailAddress); 1403 } 1404 1405 /** 1406 * Returns the user where companyId = ? and emailAddress = ? or returns <code>null</code> if it could not be found. Uses the finder cache. 1407 * 1408 * @param companyId the company ID 1409 * @param emailAddress the email address 1410 * @return the matching user, or <code>null</code> if a matching user could not be found 1411 */ 1412 public static User fetchByC_EA(long companyId, java.lang.String emailAddress) { 1413 return getPersistence().fetchByC_EA(companyId, emailAddress); 1414 } 1415 1416 /** 1417 * Returns the user where companyId = ? and emailAddress = ? or returns <code>null</code> if it could not be found, optionally using the finder cache. 1418 * 1419 * @param companyId the company ID 1420 * @param emailAddress the email address 1421 * @param retrieveFromCache whether to retrieve from the finder cache 1422 * @return the matching user, or <code>null</code> if a matching user could not be found 1423 */ 1424 public static User fetchByC_EA(long companyId, 1425 java.lang.String emailAddress, boolean retrieveFromCache) { 1426 return getPersistence() 1427 .fetchByC_EA(companyId, emailAddress, retrieveFromCache); 1428 } 1429 1430 /** 1431 * Removes the user where companyId = ? and emailAddress = ? from the database. 1432 * 1433 * @param companyId the company ID 1434 * @param emailAddress the email address 1435 * @return the user that was removed 1436 */ 1437 public static User removeByC_EA(long companyId, 1438 java.lang.String emailAddress) 1439 throws com.liferay.portal.kernel.exception.NoSuchUserException { 1440 return getPersistence().removeByC_EA(companyId, emailAddress); 1441 } 1442 1443 /** 1444 * Returns the number of users where companyId = ? and emailAddress = ?. 1445 * 1446 * @param companyId the company ID 1447 * @param emailAddress the email address 1448 * @return the number of matching users 1449 */ 1450 public static int countByC_EA(long companyId, java.lang.String emailAddress) { 1451 return getPersistence().countByC_EA(companyId, emailAddress); 1452 } 1453 1454 /** 1455 * Returns the user where companyId = ? and facebookId = ? or throws a {@link NoSuchUserException} if it could not be found. 1456 * 1457 * @param companyId the company ID 1458 * @param facebookId the facebook ID 1459 * @return the matching user 1460 * @throws NoSuchUserException if a matching user could not be found 1461 */ 1462 public static User findByC_FID(long companyId, long facebookId) 1463 throws com.liferay.portal.kernel.exception.NoSuchUserException { 1464 return getPersistence().findByC_FID(companyId, facebookId); 1465 } 1466 1467 /** 1468 * Returns the user where companyId = ? and facebookId = ? or returns <code>null</code> if it could not be found. Uses the finder cache. 1469 * 1470 * @param companyId the company ID 1471 * @param facebookId the facebook ID 1472 * @return the matching user, or <code>null</code> if a matching user could not be found 1473 */ 1474 public static User fetchByC_FID(long companyId, long facebookId) { 1475 return getPersistence().fetchByC_FID(companyId, facebookId); 1476 } 1477 1478 /** 1479 * Returns the user where companyId = ? and facebookId = ? or returns <code>null</code> if it could not be found, optionally using the finder cache. 1480 * 1481 * @param companyId the company ID 1482 * @param facebookId the facebook ID 1483 * @param retrieveFromCache whether to retrieve from the finder cache 1484 * @return the matching user, or <code>null</code> if a matching user could not be found 1485 */ 1486 public static User fetchByC_FID(long companyId, long facebookId, 1487 boolean retrieveFromCache) { 1488 return getPersistence() 1489 .fetchByC_FID(companyId, facebookId, retrieveFromCache); 1490 } 1491 1492 /** 1493 * Removes the user where companyId = ? and facebookId = ? from the database. 1494 * 1495 * @param companyId the company ID 1496 * @param facebookId the facebook ID 1497 * @return the user that was removed 1498 */ 1499 public static User removeByC_FID(long companyId, long facebookId) 1500 throws com.liferay.portal.kernel.exception.NoSuchUserException { 1501 return getPersistence().removeByC_FID(companyId, facebookId); 1502 } 1503 1504 /** 1505 * Returns the number of users where companyId = ? and facebookId = ?. 1506 * 1507 * @param companyId the company ID 1508 * @param facebookId the facebook ID 1509 * @return the number of matching users 1510 */ 1511 public static int countByC_FID(long companyId, long facebookId) { 1512 return getPersistence().countByC_FID(companyId, facebookId); 1513 } 1514 1515 /** 1516 * Returns the user where companyId = ? and googleUserId = ? or throws a {@link NoSuchUserException} if it could not be found. 1517 * 1518 * @param companyId the company ID 1519 * @param googleUserId the google user ID 1520 * @return the matching user 1521 * @throws NoSuchUserException if a matching user could not be found 1522 */ 1523 public static User findByC_GUID(long companyId, 1524 java.lang.String googleUserId) 1525 throws com.liferay.portal.kernel.exception.NoSuchUserException { 1526 return getPersistence().findByC_GUID(companyId, googleUserId); 1527 } 1528 1529 /** 1530 * Returns the user where companyId = ? and googleUserId = ? or returns <code>null</code> if it could not be found. Uses the finder cache. 1531 * 1532 * @param companyId the company ID 1533 * @param googleUserId the google user ID 1534 * @return the matching user, or <code>null</code> if a matching user could not be found 1535 */ 1536 public static User fetchByC_GUID(long companyId, 1537 java.lang.String googleUserId) { 1538 return getPersistence().fetchByC_GUID(companyId, googleUserId); 1539 } 1540 1541 /** 1542 * Returns the user where companyId = ? and googleUserId = ? or returns <code>null</code> if it could not be found, optionally using the finder cache. 1543 * 1544 * @param companyId the company ID 1545 * @param googleUserId the google user ID 1546 * @param retrieveFromCache whether to retrieve from the finder cache 1547 * @return the matching user, or <code>null</code> if a matching user could not be found 1548 */ 1549 public static User fetchByC_GUID(long companyId, 1550 java.lang.String googleUserId, boolean retrieveFromCache) { 1551 return getPersistence() 1552 .fetchByC_GUID(companyId, googleUserId, retrieveFromCache); 1553 } 1554 1555 /** 1556 * Removes the user where companyId = ? and googleUserId = ? from the database. 1557 * 1558 * @param companyId the company ID 1559 * @param googleUserId the google user ID 1560 * @return the user that was removed 1561 */ 1562 public static User removeByC_GUID(long companyId, 1563 java.lang.String googleUserId) 1564 throws com.liferay.portal.kernel.exception.NoSuchUserException { 1565 return getPersistence().removeByC_GUID(companyId, googleUserId); 1566 } 1567 1568 /** 1569 * Returns the number of users where companyId = ? and googleUserId = ?. 1570 * 1571 * @param companyId the company ID 1572 * @param googleUserId the google user ID 1573 * @return the number of matching users 1574 */ 1575 public static int countByC_GUID(long companyId, 1576 java.lang.String googleUserId) { 1577 return getPersistence().countByC_GUID(companyId, googleUserId); 1578 } 1579 1580 /** 1581 * Returns the user where companyId = ? and openId = ? or throws a {@link NoSuchUserException} if it could not be found. 1582 * 1583 * @param companyId the company ID 1584 * @param openId the open ID 1585 * @return the matching user 1586 * @throws NoSuchUserException if a matching user could not be found 1587 */ 1588 public static User findByC_O(long companyId, java.lang.String openId) 1589 throws com.liferay.portal.kernel.exception.NoSuchUserException { 1590 return getPersistence().findByC_O(companyId, openId); 1591 } 1592 1593 /** 1594 * Returns the user where companyId = ? and openId = ? or returns <code>null</code> if it could not be found. Uses the finder cache. 1595 * 1596 * @param companyId the company ID 1597 * @param openId the open ID 1598 * @return the matching user, or <code>null</code> if a matching user could not be found 1599 */ 1600 public static User fetchByC_O(long companyId, java.lang.String openId) { 1601 return getPersistence().fetchByC_O(companyId, openId); 1602 } 1603 1604 /** 1605 * Returns the user where companyId = ? and openId = ? or returns <code>null</code> if it could not be found, optionally using the finder cache. 1606 * 1607 * @param companyId the company ID 1608 * @param openId the open ID 1609 * @param retrieveFromCache whether to retrieve from the finder cache 1610 * @return the matching user, or <code>null</code> if a matching user could not be found 1611 */ 1612 public static User fetchByC_O(long companyId, java.lang.String openId, 1613 boolean retrieveFromCache) { 1614 return getPersistence().fetchByC_O(companyId, openId, retrieveFromCache); 1615 } 1616 1617 /** 1618 * Removes the user where companyId = ? and openId = ? from the database. 1619 * 1620 * @param companyId the company ID 1621 * @param openId the open ID 1622 * @return the user that was removed 1623 */ 1624 public static User removeByC_O(long companyId, java.lang.String openId) 1625 throws com.liferay.portal.kernel.exception.NoSuchUserException { 1626 return getPersistence().removeByC_O(companyId, openId); 1627 } 1628 1629 /** 1630 * Returns the number of users where companyId = ? and openId = ?. 1631 * 1632 * @param companyId the company ID 1633 * @param openId the open ID 1634 * @return the number of matching users 1635 */ 1636 public static int countByC_O(long companyId, java.lang.String openId) { 1637 return getPersistence().countByC_O(companyId, openId); 1638 } 1639 1640 /** 1641 * Returns all the users where companyId = ? and status = ?. 1642 * 1643 * @param companyId the company ID 1644 * @param status the status 1645 * @return the matching users 1646 */ 1647 public static List<User> findByC_S(long companyId, int status) { 1648 return getPersistence().findByC_S(companyId, status); 1649 } 1650 1651 /** 1652 * Returns a range of all the users where companyId = ? and status = ?. 1653 * 1654 * <p> 1655 * 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. 1656 * </p> 1657 * 1658 * @param companyId the company ID 1659 * @param status the status 1660 * @param start the lower bound of the range of users 1661 * @param end the upper bound of the range of users (not inclusive) 1662 * @return the range of matching users 1663 */ 1664 public static List<User> findByC_S(long companyId, int status, int start, 1665 int end) { 1666 return getPersistence().findByC_S(companyId, status, start, end); 1667 } 1668 1669 /** 1670 * Returns an ordered range of all the users where companyId = ? and status = ?. 1671 * 1672 * <p> 1673 * 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. 1674 * </p> 1675 * 1676 * @param companyId the company ID 1677 * @param status the status 1678 * @param start the lower bound of the range of users 1679 * @param end the upper bound of the range of users (not inclusive) 1680 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 1681 * @return the ordered range of matching users 1682 */ 1683 public static List<User> findByC_S(long companyId, int status, int start, 1684 int end, OrderByComparator<User> orderByComparator) { 1685 return getPersistence() 1686 .findByC_S(companyId, status, start, end, orderByComparator); 1687 } 1688 1689 /** 1690 * Returns an ordered range of all the users where companyId = ? and status = ?. 1691 * 1692 * <p> 1693 * 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. 1694 * </p> 1695 * 1696 * @param companyId the company ID 1697 * @param status the status 1698 * @param start the lower bound of the range of users 1699 * @param end the upper bound of the range of users (not inclusive) 1700 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 1701 * @param retrieveFromCache whether to retrieve from the finder cache 1702 * @return the ordered range of matching users 1703 */ 1704 public static List<User> findByC_S(long companyId, int status, int start, 1705 int end, OrderByComparator<User> orderByComparator, 1706 boolean retrieveFromCache) { 1707 return getPersistence() 1708 .findByC_S(companyId, status, start, end, orderByComparator, 1709 retrieveFromCache); 1710 } 1711 1712 /** 1713 * Returns the first user in the ordered set where companyId = ? and status = ?. 1714 * 1715 * @param companyId the company ID 1716 * @param status the status 1717 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 1718 * @return the first matching user 1719 * @throws NoSuchUserException if a matching user could not be found 1720 */ 1721 public static User findByC_S_First(long companyId, int status, 1722 OrderByComparator<User> orderByComparator) 1723 throws com.liferay.portal.kernel.exception.NoSuchUserException { 1724 return getPersistence() 1725 .findByC_S_First(companyId, status, orderByComparator); 1726 } 1727 1728 /** 1729 * Returns the first user in the ordered set where companyId = ? and status = ?. 1730 * 1731 * @param companyId the company ID 1732 * @param status the status 1733 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 1734 * @return the first matching user, or <code>null</code> if a matching user could not be found 1735 */ 1736 public static User fetchByC_S_First(long companyId, int status, 1737 OrderByComparator<User> orderByComparator) { 1738 return getPersistence() 1739 .fetchByC_S_First(companyId, status, orderByComparator); 1740 } 1741 1742 /** 1743 * Returns the last user in the ordered set where companyId = ? and status = ?. 1744 * 1745 * @param companyId the company ID 1746 * @param status the status 1747 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 1748 * @return the last matching user 1749 * @throws NoSuchUserException if a matching user could not be found 1750 */ 1751 public static User findByC_S_Last(long companyId, int status, 1752 OrderByComparator<User> orderByComparator) 1753 throws com.liferay.portal.kernel.exception.NoSuchUserException { 1754 return getPersistence() 1755 .findByC_S_Last(companyId, status, orderByComparator); 1756 } 1757 1758 /** 1759 * Returns the last user in the ordered set where companyId = ? and status = ?. 1760 * 1761 * @param companyId the company ID 1762 * @param status the status 1763 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 1764 * @return the last matching user, or <code>null</code> if a matching user could not be found 1765 */ 1766 public static User fetchByC_S_Last(long companyId, int status, 1767 OrderByComparator<User> orderByComparator) { 1768 return getPersistence() 1769 .fetchByC_S_Last(companyId, status, orderByComparator); 1770 } 1771 1772 /** 1773 * Returns the users before and after the current user in the ordered set where companyId = ? and status = ?. 1774 * 1775 * @param userId the primary key of the current user 1776 * @param companyId the company ID 1777 * @param status the status 1778 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 1779 * @return the previous, current, and next user 1780 * @throws NoSuchUserException if a user with the primary key could not be found 1781 */ 1782 public static User[] findByC_S_PrevAndNext(long userId, long companyId, 1783 int status, OrderByComparator<User> orderByComparator) 1784 throws com.liferay.portal.kernel.exception.NoSuchUserException { 1785 return getPersistence() 1786 .findByC_S_PrevAndNext(userId, companyId, status, 1787 orderByComparator); 1788 } 1789 1790 /** 1791 * Removes all the users where companyId = ? and status = ? from the database. 1792 * 1793 * @param companyId the company ID 1794 * @param status the status 1795 */ 1796 public static void removeByC_S(long companyId, int status) { 1797 getPersistence().removeByC_S(companyId, status); 1798 } 1799 1800 /** 1801 * Returns the number of users where companyId = ? and status = ?. 1802 * 1803 * @param companyId the company ID 1804 * @param status the status 1805 * @return the number of matching users 1806 */ 1807 public static int countByC_S(long companyId, int status) { 1808 return getPersistence().countByC_S(companyId, status); 1809 } 1810 1811 /** 1812 * Returns all the users where companyId = ? and createDate = ? and modifiedDate = ?. 1813 * 1814 * @param companyId the company ID 1815 * @param createDate the create date 1816 * @param modifiedDate the modified date 1817 * @return the matching users 1818 */ 1819 public static List<User> findByC_CD_MD(long companyId, Date createDate, 1820 Date modifiedDate) { 1821 return getPersistence() 1822 .findByC_CD_MD(companyId, createDate, modifiedDate); 1823 } 1824 1825 /** 1826 * Returns a range of all the users where companyId = ? and createDate = ? and modifiedDate = ?. 1827 * 1828 * <p> 1829 * 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. 1830 * </p> 1831 * 1832 * @param companyId the company ID 1833 * @param createDate the create date 1834 * @param modifiedDate the modified date 1835 * @param start the lower bound of the range of users 1836 * @param end the upper bound of the range of users (not inclusive) 1837 * @return the range of matching users 1838 */ 1839 public static List<User> findByC_CD_MD(long companyId, Date createDate, 1840 Date modifiedDate, int start, int end) { 1841 return getPersistence() 1842 .findByC_CD_MD(companyId, createDate, modifiedDate, start, 1843 end); 1844 } 1845 1846 /** 1847 * Returns an ordered range of all the users where companyId = ? and createDate = ? and modifiedDate = ?. 1848 * 1849 * <p> 1850 * 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. 1851 * </p> 1852 * 1853 * @param companyId the company ID 1854 * @param createDate the create date 1855 * @param modifiedDate the modified date 1856 * @param start the lower bound of the range of users 1857 * @param end the upper bound of the range of users (not inclusive) 1858 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 1859 * @return the ordered range of matching users 1860 */ 1861 public static List<User> findByC_CD_MD(long companyId, Date createDate, 1862 Date modifiedDate, int start, int end, 1863 OrderByComparator<User> orderByComparator) { 1864 return getPersistence() 1865 .findByC_CD_MD(companyId, createDate, modifiedDate, start, 1866 end, orderByComparator); 1867 } 1868 1869 /** 1870 * Returns an ordered range of all the users where companyId = ? and createDate = ? and modifiedDate = ?. 1871 * 1872 * <p> 1873 * 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. 1874 * </p> 1875 * 1876 * @param companyId the company ID 1877 * @param createDate the create date 1878 * @param modifiedDate the modified date 1879 * @param start the lower bound of the range of users 1880 * @param end the upper bound of the range of users (not inclusive) 1881 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 1882 * @param retrieveFromCache whether to retrieve from the finder cache 1883 * @return the ordered range of matching users 1884 */ 1885 public static List<User> findByC_CD_MD(long companyId, Date createDate, 1886 Date modifiedDate, int start, int end, 1887 OrderByComparator<User> orderByComparator, boolean retrieveFromCache) { 1888 return getPersistence() 1889 .findByC_CD_MD(companyId, createDate, modifiedDate, start, 1890 end, orderByComparator, retrieveFromCache); 1891 } 1892 1893 /** 1894 * Returns the first user in the ordered set where companyId = ? and createDate = ? and modifiedDate = ?. 1895 * 1896 * @param companyId the company ID 1897 * @param createDate the create date 1898 * @param modifiedDate the modified date 1899 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 1900 * @return the first matching user 1901 * @throws NoSuchUserException if a matching user could not be found 1902 */ 1903 public static User findByC_CD_MD_First(long companyId, Date createDate, 1904 Date modifiedDate, OrderByComparator<User> orderByComparator) 1905 throws com.liferay.portal.kernel.exception.NoSuchUserException { 1906 return getPersistence() 1907 .findByC_CD_MD_First(companyId, createDate, modifiedDate, 1908 orderByComparator); 1909 } 1910 1911 /** 1912 * Returns the first user in the ordered set where companyId = ? and createDate = ? and modifiedDate = ?. 1913 * 1914 * @param companyId the company ID 1915 * @param createDate the create date 1916 * @param modifiedDate the modified date 1917 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 1918 * @return the first matching user, or <code>null</code> if a matching user could not be found 1919 */ 1920 public static User fetchByC_CD_MD_First(long companyId, Date createDate, 1921 Date modifiedDate, OrderByComparator<User> orderByComparator) { 1922 return getPersistence() 1923 .fetchByC_CD_MD_First(companyId, createDate, modifiedDate, 1924 orderByComparator); 1925 } 1926 1927 /** 1928 * Returns the last user in the ordered set where companyId = ? and createDate = ? and modifiedDate = ?. 1929 * 1930 * @param companyId the company ID 1931 * @param createDate the create date 1932 * @param modifiedDate the modified date 1933 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 1934 * @return the last matching user 1935 * @throws NoSuchUserException if a matching user could not be found 1936 */ 1937 public static User findByC_CD_MD_Last(long companyId, Date createDate, 1938 Date modifiedDate, OrderByComparator<User> orderByComparator) 1939 throws com.liferay.portal.kernel.exception.NoSuchUserException { 1940 return getPersistence() 1941 .findByC_CD_MD_Last(companyId, createDate, modifiedDate, 1942 orderByComparator); 1943 } 1944 1945 /** 1946 * Returns the last user in the ordered set where companyId = ? and createDate = ? and modifiedDate = ?. 1947 * 1948 * @param companyId the company ID 1949 * @param createDate the create date 1950 * @param modifiedDate the modified date 1951 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 1952 * @return the last matching user, or <code>null</code> if a matching user could not be found 1953 */ 1954 public static User fetchByC_CD_MD_Last(long companyId, Date createDate, 1955 Date modifiedDate, OrderByComparator<User> orderByComparator) { 1956 return getPersistence() 1957 .fetchByC_CD_MD_Last(companyId, createDate, modifiedDate, 1958 orderByComparator); 1959 } 1960 1961 /** 1962 * Returns the users before and after the current user in the ordered set where companyId = ? and createDate = ? and modifiedDate = ?. 1963 * 1964 * @param userId the primary key of the current user 1965 * @param companyId the company ID 1966 * @param createDate the create date 1967 * @param modifiedDate the modified date 1968 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 1969 * @return the previous, current, and next user 1970 * @throws NoSuchUserException if a user with the primary key could not be found 1971 */ 1972 public static User[] findByC_CD_MD_PrevAndNext(long userId, long companyId, 1973 Date createDate, Date modifiedDate, 1974 OrderByComparator<User> orderByComparator) 1975 throws com.liferay.portal.kernel.exception.NoSuchUserException { 1976 return getPersistence() 1977 .findByC_CD_MD_PrevAndNext(userId, companyId, createDate, 1978 modifiedDate, orderByComparator); 1979 } 1980 1981 /** 1982 * Removes all the users where companyId = ? and createDate = ? and modifiedDate = ? from the database. 1983 * 1984 * @param companyId the company ID 1985 * @param createDate the create date 1986 * @param modifiedDate the modified date 1987 */ 1988 public static void removeByC_CD_MD(long companyId, Date createDate, 1989 Date modifiedDate) { 1990 getPersistence().removeByC_CD_MD(companyId, createDate, modifiedDate); 1991 } 1992 1993 /** 1994 * Returns the number of users where companyId = ? and createDate = ? and modifiedDate = ?. 1995 * 1996 * @param companyId the company ID 1997 * @param createDate the create date 1998 * @param modifiedDate the modified date 1999 * @return the number of matching users 2000 */ 2001 public static int countByC_CD_MD(long companyId, Date createDate, 2002 Date modifiedDate) { 2003 return getPersistence() 2004 .countByC_CD_MD(companyId, createDate, modifiedDate); 2005 } 2006 2007 /** 2008 * Returns all the users where companyId = ? and defaultUser = ? and status = ?. 2009 * 2010 * @param companyId the company ID 2011 * @param defaultUser the default user 2012 * @param status the status 2013 * @return the matching users 2014 */ 2015 public static List<User> findByC_DU_S(long companyId, boolean defaultUser, 2016 int status) { 2017 return getPersistence().findByC_DU_S(companyId, defaultUser, status); 2018 } 2019 2020 /** 2021 * Returns a range of all the users where companyId = ? and defaultUser = ? and status = ?. 2022 * 2023 * <p> 2024 * 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. 2025 * </p> 2026 * 2027 * @param companyId the company ID 2028 * @param defaultUser the default user 2029 * @param status the status 2030 * @param start the lower bound of the range of users 2031 * @param end the upper bound of the range of users (not inclusive) 2032 * @return the range of matching users 2033 */ 2034 public static List<User> findByC_DU_S(long companyId, boolean defaultUser, 2035 int status, int start, int end) { 2036 return getPersistence() 2037 .findByC_DU_S(companyId, defaultUser, status, start, end); 2038 } 2039 2040 /** 2041 * Returns an ordered range of all the users where companyId = ? and defaultUser = ? and status = ?. 2042 * 2043 * <p> 2044 * 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. 2045 * </p> 2046 * 2047 * @param companyId the company ID 2048 * @param defaultUser the default user 2049 * @param status the status 2050 * @param start the lower bound of the range of users 2051 * @param end the upper bound of the range of users (not inclusive) 2052 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 2053 * @return the ordered range of matching users 2054 */ 2055 public static List<User> findByC_DU_S(long companyId, boolean defaultUser, 2056 int status, int start, int end, 2057 OrderByComparator<User> orderByComparator) { 2058 return getPersistence() 2059 .findByC_DU_S(companyId, defaultUser, status, start, end, 2060 orderByComparator); 2061 } 2062 2063 /** 2064 * Returns an ordered range of all the users where companyId = ? and defaultUser = ? and status = ?. 2065 * 2066 * <p> 2067 * 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. 2068 * </p> 2069 * 2070 * @param companyId the company ID 2071 * @param defaultUser the default user 2072 * @param status the status 2073 * @param start the lower bound of the range of users 2074 * @param end the upper bound of the range of users (not inclusive) 2075 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 2076 * @param retrieveFromCache whether to retrieve from the finder cache 2077 * @return the ordered range of matching users 2078 */ 2079 public static List<User> findByC_DU_S(long companyId, boolean defaultUser, 2080 int status, int start, int end, 2081 OrderByComparator<User> orderByComparator, boolean retrieveFromCache) { 2082 return getPersistence() 2083 .findByC_DU_S(companyId, defaultUser, status, start, end, 2084 orderByComparator, retrieveFromCache); 2085 } 2086 2087 /** 2088 * Returns the first user in the ordered set where companyId = ? and defaultUser = ? and status = ?. 2089 * 2090 * @param companyId the company ID 2091 * @param defaultUser the default user 2092 * @param status the status 2093 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 2094 * @return the first matching user 2095 * @throws NoSuchUserException if a matching user could not be found 2096 */ 2097 public static User findByC_DU_S_First(long companyId, boolean defaultUser, 2098 int status, OrderByComparator<User> orderByComparator) 2099 throws com.liferay.portal.kernel.exception.NoSuchUserException { 2100 return getPersistence() 2101 .findByC_DU_S_First(companyId, defaultUser, status, 2102 orderByComparator); 2103 } 2104 2105 /** 2106 * Returns the first user in the ordered set where companyId = ? and defaultUser = ? and status = ?. 2107 * 2108 * @param companyId the company ID 2109 * @param defaultUser the default user 2110 * @param status the status 2111 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 2112 * @return the first matching user, or <code>null</code> if a matching user could not be found 2113 */ 2114 public static User fetchByC_DU_S_First(long companyId, boolean defaultUser, 2115 int status, OrderByComparator<User> orderByComparator) { 2116 return getPersistence() 2117 .fetchByC_DU_S_First(companyId, defaultUser, status, 2118 orderByComparator); 2119 } 2120 2121 /** 2122 * Returns the last user in the ordered set where companyId = ? and defaultUser = ? and status = ?. 2123 * 2124 * @param companyId the company ID 2125 * @param defaultUser the default user 2126 * @param status the status 2127 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 2128 * @return the last matching user 2129 * @throws NoSuchUserException if a matching user could not be found 2130 */ 2131 public static User findByC_DU_S_Last(long companyId, boolean defaultUser, 2132 int status, OrderByComparator<User> orderByComparator) 2133 throws com.liferay.portal.kernel.exception.NoSuchUserException { 2134 return getPersistence() 2135 .findByC_DU_S_Last(companyId, defaultUser, status, 2136 orderByComparator); 2137 } 2138 2139 /** 2140 * Returns the last user in the ordered set where companyId = ? and defaultUser = ? and status = ?. 2141 * 2142 * @param companyId the company ID 2143 * @param defaultUser the default user 2144 * @param status the status 2145 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 2146 * @return the last matching user, or <code>null</code> if a matching user could not be found 2147 */ 2148 public static User fetchByC_DU_S_Last(long companyId, boolean defaultUser, 2149 int status, OrderByComparator<User> orderByComparator) { 2150 return getPersistence() 2151 .fetchByC_DU_S_Last(companyId, defaultUser, status, 2152 orderByComparator); 2153 } 2154 2155 /** 2156 * Returns the users before and after the current user in the ordered set where companyId = ? and defaultUser = ? and status = ?. 2157 * 2158 * @param userId the primary key of the current user 2159 * @param companyId the company ID 2160 * @param defaultUser the default user 2161 * @param status the status 2162 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 2163 * @return the previous, current, and next user 2164 * @throws NoSuchUserException if a user with the primary key could not be found 2165 */ 2166 public static User[] findByC_DU_S_PrevAndNext(long userId, long companyId, 2167 boolean defaultUser, int status, 2168 OrderByComparator<User> orderByComparator) 2169 throws com.liferay.portal.kernel.exception.NoSuchUserException { 2170 return getPersistence() 2171 .findByC_DU_S_PrevAndNext(userId, companyId, defaultUser, 2172 status, orderByComparator); 2173 } 2174 2175 /** 2176 * Removes all the users where companyId = ? and defaultUser = ? and status = ? from the database. 2177 * 2178 * @param companyId the company ID 2179 * @param defaultUser the default user 2180 * @param status the status 2181 */ 2182 public static void removeByC_DU_S(long companyId, boolean defaultUser, 2183 int status) { 2184 getPersistence().removeByC_DU_S(companyId, defaultUser, status); 2185 } 2186 2187 /** 2188 * Returns the number of users where companyId = ? and defaultUser = ? and status = ?. 2189 * 2190 * @param companyId the company ID 2191 * @param defaultUser the default user 2192 * @param status the status 2193 * @return the number of matching users 2194 */ 2195 public static int countByC_DU_S(long companyId, boolean defaultUser, 2196 int status) { 2197 return getPersistence().countByC_DU_S(companyId, defaultUser, status); 2198 } 2199 2200 /** 2201 * Caches the user in the entity cache if it is enabled. 2202 * 2203 * @param user the user 2204 */ 2205 public static void cacheResult(User user) { 2206 getPersistence().cacheResult(user); 2207 } 2208 2209 /** 2210 * Caches the users in the entity cache if it is enabled. 2211 * 2212 * @param users the users 2213 */ 2214 public static void cacheResult(List<User> users) { 2215 getPersistence().cacheResult(users); 2216 } 2217 2218 /** 2219 * Creates a new user with the primary key. Does not add the user to the database. 2220 * 2221 * @param userId the primary key for the new user 2222 * @return the new user 2223 */ 2224 public static User create(long userId) { 2225 return getPersistence().create(userId); 2226 } 2227 2228 /** 2229 * Removes the user with the primary key from the database. Also notifies the appropriate model listeners. 2230 * 2231 * @param userId the primary key of the user 2232 * @return the user that was removed 2233 * @throws NoSuchUserException if a user with the primary key could not be found 2234 */ 2235 public static User remove(long userId) 2236 throws com.liferay.portal.kernel.exception.NoSuchUserException { 2237 return getPersistence().remove(userId); 2238 } 2239 2240 public static User updateImpl(User user) { 2241 return getPersistence().updateImpl(user); 2242 } 2243 2244 /** 2245 * Returns the user with the primary key or throws a {@link NoSuchUserException} if it could not be found. 2246 * 2247 * @param userId the primary key of the user 2248 * @return the user 2249 * @throws NoSuchUserException if a user with the primary key could not be found 2250 */ 2251 public static User findByPrimaryKey(long userId) 2252 throws com.liferay.portal.kernel.exception.NoSuchUserException { 2253 return getPersistence().findByPrimaryKey(userId); 2254 } 2255 2256 /** 2257 * Returns the user with the primary key or returns <code>null</code> if it could not be found. 2258 * 2259 * @param userId the primary key of the user 2260 * @return the user, or <code>null</code> if a user with the primary key could not be found 2261 */ 2262 public static User fetchByPrimaryKey(long userId) { 2263 return getPersistence().fetchByPrimaryKey(userId); 2264 } 2265 2266 public static java.util.Map<java.io.Serializable, User> fetchByPrimaryKeys( 2267 java.util.Set<java.io.Serializable> primaryKeys) { 2268 return getPersistence().fetchByPrimaryKeys(primaryKeys); 2269 } 2270 2271 /** 2272 * Returns all the users. 2273 * 2274 * @return the users 2275 */ 2276 public static List<User> findAll() { 2277 return getPersistence().findAll(); 2278 } 2279 2280 /** 2281 * Returns a range of all the users. 2282 * 2283 * <p> 2284 * 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. 2285 * </p> 2286 * 2287 * @param start the lower bound of the range of users 2288 * @param end the upper bound of the range of users (not inclusive) 2289 * @return the range of users 2290 */ 2291 public static List<User> findAll(int start, int end) { 2292 return getPersistence().findAll(start, end); 2293 } 2294 2295 /** 2296 * Returns an ordered range of all the users. 2297 * 2298 * <p> 2299 * 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. 2300 * </p> 2301 * 2302 * @param start the lower bound of the range of users 2303 * @param end the upper bound of the range of users (not inclusive) 2304 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 2305 * @return the ordered range of users 2306 */ 2307 public static List<User> findAll(int start, int end, 2308 OrderByComparator<User> orderByComparator) { 2309 return getPersistence().findAll(start, end, orderByComparator); 2310 } 2311 2312 /** 2313 * Returns an ordered range of all the users. 2314 * 2315 * <p> 2316 * 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. 2317 * </p> 2318 * 2319 * @param start the lower bound of the range of users 2320 * @param end the upper bound of the range of users (not inclusive) 2321 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 2322 * @param retrieveFromCache whether to retrieve from the finder cache 2323 * @return the ordered range of users 2324 */ 2325 public static List<User> findAll(int start, int end, 2326 OrderByComparator<User> orderByComparator, boolean retrieveFromCache) { 2327 return getPersistence() 2328 .findAll(start, end, orderByComparator, retrieveFromCache); 2329 } 2330 2331 /** 2332 * Removes all the users from the database. 2333 */ 2334 public static void removeAll() { 2335 getPersistence().removeAll(); 2336 } 2337 2338 /** 2339 * Returns the number of users. 2340 * 2341 * @return the number of users 2342 */ 2343 public static int countAll() { 2344 return getPersistence().countAll(); 2345 } 2346 2347 /** 2348 * Returns the primaryKeys of groups associated with the user. 2349 * 2350 * @param pk the primary key of the user 2351 * @return long[] of the primaryKeys of groups associated with the user 2352 */ 2353 public static long[] getGroupPrimaryKeys(long pk) { 2354 return getPersistence().getGroupPrimaryKeys(pk); 2355 } 2356 2357 /** 2358 * Returns all the groups associated with the user. 2359 * 2360 * @param pk the primary key of the user 2361 * @return the groups associated with the user 2362 */ 2363 public static List<com.liferay.portal.kernel.model.Group> getGroups(long pk) { 2364 return getPersistence().getGroups(pk); 2365 } 2366 2367 /** 2368 * Returns a range of all the groups associated with the user. 2369 * 2370 * <p> 2371 * 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. 2372 * </p> 2373 * 2374 * @param pk the primary key of the user 2375 * @param start the lower bound of the range of users 2376 * @param end the upper bound of the range of users (not inclusive) 2377 * @return the range of groups associated with the user 2378 */ 2379 public static List<com.liferay.portal.kernel.model.Group> getGroups( 2380 long pk, int start, int end) { 2381 return getPersistence().getGroups(pk, start, end); 2382 } 2383 2384 /** 2385 * Returns an ordered range of all the groups associated with the user. 2386 * 2387 * <p> 2388 * 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. 2389 * </p> 2390 * 2391 * @param pk the primary key of the user 2392 * @param start the lower bound of the range of users 2393 * @param end the upper bound of the range of users (not inclusive) 2394 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 2395 * @return the ordered range of groups associated with the user 2396 */ 2397 public static List<com.liferay.portal.kernel.model.Group> getGroups( 2398 long pk, int start, int end, 2399 OrderByComparator<com.liferay.portal.kernel.model.Group> orderByComparator) { 2400 return getPersistence().getGroups(pk, start, end, orderByComparator); 2401 } 2402 2403 /** 2404 * Returns the number of groups associated with the user. 2405 * 2406 * @param pk the primary key of the user 2407 * @return the number of groups associated with the user 2408 */ 2409 public static int getGroupsSize(long pk) { 2410 return getPersistence().getGroupsSize(pk); 2411 } 2412 2413 /** 2414 * Returns <code>true</code> if the group is associated with the user. 2415 * 2416 * @param pk the primary key of the user 2417 * @param groupPK the primary key of the group 2418 * @return <code>true</code> if the group is associated with the user; <code>false</code> otherwise 2419 */ 2420 public static boolean containsGroup(long pk, long groupPK) { 2421 return getPersistence().containsGroup(pk, groupPK); 2422 } 2423 2424 /** 2425 * Returns <code>true</code> if the user has any groups associated with it. 2426 * 2427 * @param pk the primary key of the user to check for associations with groups 2428 * @return <code>true</code> if the user has any groups associated with it; <code>false</code> otherwise 2429 */ 2430 public static boolean containsGroups(long pk) { 2431 return getPersistence().containsGroups(pk); 2432 } 2433 2434 /** 2435 * Adds an association between the user and the group. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2436 * 2437 * @param pk the primary key of the user 2438 * @param groupPK the primary key of the group 2439 */ 2440 public static void addGroup(long pk, long groupPK) { 2441 getPersistence().addGroup(pk, groupPK); 2442 } 2443 2444 /** 2445 * Adds an association between the user and the group. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2446 * 2447 * @param pk the primary key of the user 2448 * @param group the group 2449 */ 2450 public static void addGroup(long pk, 2451 com.liferay.portal.kernel.model.Group group) { 2452 getPersistence().addGroup(pk, group); 2453 } 2454 2455 /** 2456 * Adds an association between the user and the groups. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2457 * 2458 * @param pk the primary key of the user 2459 * @param groupPKs the primary keys of the groups 2460 */ 2461 public static void addGroups(long pk, long[] groupPKs) { 2462 getPersistence().addGroups(pk, groupPKs); 2463 } 2464 2465 /** 2466 * Adds an association between the user and the groups. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2467 * 2468 * @param pk the primary key of the user 2469 * @param groups the groups 2470 */ 2471 public static void addGroups(long pk, 2472 List<com.liferay.portal.kernel.model.Group> groups) { 2473 getPersistence().addGroups(pk, groups); 2474 } 2475 2476 /** 2477 * Clears all associations between the user and its groups. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2478 * 2479 * @param pk the primary key of the user to clear the associated groups from 2480 */ 2481 public static void clearGroups(long pk) { 2482 getPersistence().clearGroups(pk); 2483 } 2484 2485 /** 2486 * Removes the association between the user and the group. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2487 * 2488 * @param pk the primary key of the user 2489 * @param groupPK the primary key of the group 2490 */ 2491 public static void removeGroup(long pk, long groupPK) { 2492 getPersistence().removeGroup(pk, groupPK); 2493 } 2494 2495 /** 2496 * Removes the association between the user and the group. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2497 * 2498 * @param pk the primary key of the user 2499 * @param group the group 2500 */ 2501 public static void removeGroup(long pk, 2502 com.liferay.portal.kernel.model.Group group) { 2503 getPersistence().removeGroup(pk, group); 2504 } 2505 2506 /** 2507 * Removes the association between the user and the groups. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2508 * 2509 * @param pk the primary key of the user 2510 * @param groupPKs the primary keys of the groups 2511 */ 2512 public static void removeGroups(long pk, long[] groupPKs) { 2513 getPersistence().removeGroups(pk, groupPKs); 2514 } 2515 2516 /** 2517 * Removes the association between the user and the groups. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2518 * 2519 * @param pk the primary key of the user 2520 * @param groups the groups 2521 */ 2522 public static void removeGroups(long pk, 2523 List<com.liferay.portal.kernel.model.Group> groups) { 2524 getPersistence().removeGroups(pk, groups); 2525 } 2526 2527 /** 2528 * 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. 2529 * 2530 * @param pk the primary key of the user 2531 * @param groupPKs the primary keys of the groups to be associated with the user 2532 */ 2533 public static void setGroups(long pk, long[] groupPKs) { 2534 getPersistence().setGroups(pk, groupPKs); 2535 } 2536 2537 /** 2538 * 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. 2539 * 2540 * @param pk the primary key of the user 2541 * @param groups the groups to be associated with the user 2542 */ 2543 public static void setGroups(long pk, 2544 List<com.liferay.portal.kernel.model.Group> groups) { 2545 getPersistence().setGroups(pk, groups); 2546 } 2547 2548 /** 2549 * Returns the primaryKeys of organizations associated with the user. 2550 * 2551 * @param pk the primary key of the user 2552 * @return long[] of the primaryKeys of organizations associated with the user 2553 */ 2554 public static long[] getOrganizationPrimaryKeys(long pk) { 2555 return getPersistence().getOrganizationPrimaryKeys(pk); 2556 } 2557 2558 /** 2559 * Returns all the organizations associated with the user. 2560 * 2561 * @param pk the primary key of the user 2562 * @return the organizations associated with the user 2563 */ 2564 public static List<com.liferay.portal.kernel.model.Organization> getOrganizations( 2565 long pk) { 2566 return getPersistence().getOrganizations(pk); 2567 } 2568 2569 /** 2570 * Returns a range of all the organizations associated with the user. 2571 * 2572 * <p> 2573 * 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. 2574 * </p> 2575 * 2576 * @param pk the primary key of the user 2577 * @param start the lower bound of the range of users 2578 * @param end the upper bound of the range of users (not inclusive) 2579 * @return the range of organizations associated with the user 2580 */ 2581 public static List<com.liferay.portal.kernel.model.Organization> getOrganizations( 2582 long pk, int start, int end) { 2583 return getPersistence().getOrganizations(pk, start, end); 2584 } 2585 2586 /** 2587 * Returns an ordered range of all the organizations associated with the user. 2588 * 2589 * <p> 2590 * 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. 2591 * </p> 2592 * 2593 * @param pk the primary key of the user 2594 * @param start the lower bound of the range of users 2595 * @param end the upper bound of the range of users (not inclusive) 2596 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 2597 * @return the ordered range of organizations associated with the user 2598 */ 2599 public static List<com.liferay.portal.kernel.model.Organization> getOrganizations( 2600 long pk, int start, int end, 2601 OrderByComparator<com.liferay.portal.kernel.model.Organization> orderByComparator) { 2602 return getPersistence() 2603 .getOrganizations(pk, start, end, orderByComparator); 2604 } 2605 2606 /** 2607 * Returns the number of organizations associated with the user. 2608 * 2609 * @param pk the primary key of the user 2610 * @return the number of organizations associated with the user 2611 */ 2612 public static int getOrganizationsSize(long pk) { 2613 return getPersistence().getOrganizationsSize(pk); 2614 } 2615 2616 /** 2617 * Returns <code>true</code> if the organization is associated with the user. 2618 * 2619 * @param pk the primary key of the user 2620 * @param organizationPK the primary key of the organization 2621 * @return <code>true</code> if the organization is associated with the user; <code>false</code> otherwise 2622 */ 2623 public static boolean containsOrganization(long pk, long organizationPK) { 2624 return getPersistence().containsOrganization(pk, organizationPK); 2625 } 2626 2627 /** 2628 * Returns <code>true</code> if the user has any organizations associated with it. 2629 * 2630 * @param pk the primary key of the user to check for associations with organizations 2631 * @return <code>true</code> if the user has any organizations associated with it; <code>false</code> otherwise 2632 */ 2633 public static boolean containsOrganizations(long pk) { 2634 return getPersistence().containsOrganizations(pk); 2635 } 2636 2637 /** 2638 * Adds an association between the user and the organization. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2639 * 2640 * @param pk the primary key of the user 2641 * @param organizationPK the primary key of the organization 2642 */ 2643 public static void addOrganization(long pk, long organizationPK) { 2644 getPersistence().addOrganization(pk, organizationPK); 2645 } 2646 2647 /** 2648 * Adds an association between the user and the organization. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2649 * 2650 * @param pk the primary key of the user 2651 * @param organization the organization 2652 */ 2653 public static void addOrganization(long pk, 2654 com.liferay.portal.kernel.model.Organization organization) { 2655 getPersistence().addOrganization(pk, organization); 2656 } 2657 2658 /** 2659 * Adds an association between the user and the organizations. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2660 * 2661 * @param pk the primary key of the user 2662 * @param organizationPKs the primary keys of the organizations 2663 */ 2664 public static void addOrganizations(long pk, long[] organizationPKs) { 2665 getPersistence().addOrganizations(pk, organizationPKs); 2666 } 2667 2668 /** 2669 * Adds an association between the user and the organizations. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2670 * 2671 * @param pk the primary key of the user 2672 * @param organizations the organizations 2673 */ 2674 public static void addOrganizations(long pk, 2675 List<com.liferay.portal.kernel.model.Organization> organizations) { 2676 getPersistence().addOrganizations(pk, organizations); 2677 } 2678 2679 /** 2680 * Clears all associations between the user and its organizations. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2681 * 2682 * @param pk the primary key of the user to clear the associated organizations from 2683 */ 2684 public static void clearOrganizations(long pk) { 2685 getPersistence().clearOrganizations(pk); 2686 } 2687 2688 /** 2689 * Removes the association between the user and the organization. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2690 * 2691 * @param pk the primary key of the user 2692 * @param organizationPK the primary key of the organization 2693 */ 2694 public static void removeOrganization(long pk, long organizationPK) { 2695 getPersistence().removeOrganization(pk, organizationPK); 2696 } 2697 2698 /** 2699 * Removes the association between the user and the organization. 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 organization the organization 2703 */ 2704 public static void removeOrganization(long pk, 2705 com.liferay.portal.kernel.model.Organization organization) { 2706 getPersistence().removeOrganization(pk, organization); 2707 } 2708 2709 /** 2710 * Removes the association between the user and the organizations. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2711 * 2712 * @param pk the primary key of the user 2713 * @param organizationPKs the primary keys of the organizations 2714 */ 2715 public static void removeOrganizations(long pk, long[] organizationPKs) { 2716 getPersistence().removeOrganizations(pk, organizationPKs); 2717 } 2718 2719 /** 2720 * Removes the association between the user and the organizations. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2721 * 2722 * @param pk the primary key of the user 2723 * @param organizations the organizations 2724 */ 2725 public static void removeOrganizations(long pk, 2726 List<com.liferay.portal.kernel.model.Organization> organizations) { 2727 getPersistence().removeOrganizations(pk, organizations); 2728 } 2729 2730 /** 2731 * 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. 2732 * 2733 * @param pk the primary key of the user 2734 * @param organizationPKs the primary keys of the organizations to be associated with the user 2735 */ 2736 public static void setOrganizations(long pk, long[] organizationPKs) { 2737 getPersistence().setOrganizations(pk, organizationPKs); 2738 } 2739 2740 /** 2741 * 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. 2742 * 2743 * @param pk the primary key of the user 2744 * @param organizations the organizations to be associated with the user 2745 */ 2746 public static void setOrganizations(long pk, 2747 List<com.liferay.portal.kernel.model.Organization> organizations) { 2748 getPersistence().setOrganizations(pk, organizations); 2749 } 2750 2751 /** 2752 * Returns the primaryKeys of roles associated with the user. 2753 * 2754 * @param pk the primary key of the user 2755 * @return long[] of the primaryKeys of roles associated with the user 2756 */ 2757 public static long[] getRolePrimaryKeys(long pk) { 2758 return getPersistence().getRolePrimaryKeys(pk); 2759 } 2760 2761 /** 2762 * Returns all the roles associated with the user. 2763 * 2764 * @param pk the primary key of the user 2765 * @return the roles associated with the user 2766 */ 2767 public static List<com.liferay.portal.kernel.model.Role> getRoles(long pk) { 2768 return getPersistence().getRoles(pk); 2769 } 2770 2771 /** 2772 * Returns a range of all the roles associated with the user. 2773 * 2774 * <p> 2775 * 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. 2776 * </p> 2777 * 2778 * @param pk the primary key of the user 2779 * @param start the lower bound of the range of users 2780 * @param end the upper bound of the range of users (not inclusive) 2781 * @return the range of roles associated with the user 2782 */ 2783 public static List<com.liferay.portal.kernel.model.Role> getRoles(long pk, 2784 int start, int end) { 2785 return getPersistence().getRoles(pk, start, end); 2786 } 2787 2788 /** 2789 * Returns an ordered range of all the roles associated with the user. 2790 * 2791 * <p> 2792 * 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. 2793 * </p> 2794 * 2795 * @param pk the primary key of the user 2796 * @param start the lower bound of the range of users 2797 * @param end the upper bound of the range of users (not inclusive) 2798 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 2799 * @return the ordered range of roles associated with the user 2800 */ 2801 public static List<com.liferay.portal.kernel.model.Role> getRoles(long pk, 2802 int start, int end, 2803 OrderByComparator<com.liferay.portal.kernel.model.Role> orderByComparator) { 2804 return getPersistence().getRoles(pk, start, end, orderByComparator); 2805 } 2806 2807 /** 2808 * Returns the number of roles associated with the user. 2809 * 2810 * @param pk the primary key of the user 2811 * @return the number of roles associated with the user 2812 */ 2813 public static int getRolesSize(long pk) { 2814 return getPersistence().getRolesSize(pk); 2815 } 2816 2817 /** 2818 * Returns <code>true</code> if the role is associated with the user. 2819 * 2820 * @param pk the primary key of the user 2821 * @param rolePK the primary key of the role 2822 * @return <code>true</code> if the role is associated with the user; <code>false</code> otherwise 2823 */ 2824 public static boolean containsRole(long pk, long rolePK) { 2825 return getPersistence().containsRole(pk, rolePK); 2826 } 2827 2828 /** 2829 * Returns <code>true</code> if the user has any roles associated with it. 2830 * 2831 * @param pk the primary key of the user to check for associations with roles 2832 * @return <code>true</code> if the user has any roles associated with it; <code>false</code> otherwise 2833 */ 2834 public static boolean containsRoles(long pk) { 2835 return getPersistence().containsRoles(pk); 2836 } 2837 2838 /** 2839 * Adds an association between the user and the role. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2840 * 2841 * @param pk the primary key of the user 2842 * @param rolePK the primary key of the role 2843 */ 2844 public static void addRole(long pk, long rolePK) { 2845 getPersistence().addRole(pk, rolePK); 2846 } 2847 2848 /** 2849 * Adds an association between the user and the role. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2850 * 2851 * @param pk the primary key of the user 2852 * @param role the role 2853 */ 2854 public static void addRole(long pk, 2855 com.liferay.portal.kernel.model.Role role) { 2856 getPersistence().addRole(pk, role); 2857 } 2858 2859 /** 2860 * Adds an association between the user and the roles. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2861 * 2862 * @param pk the primary key of the user 2863 * @param rolePKs the primary keys of the roles 2864 */ 2865 public static void addRoles(long pk, long[] rolePKs) { 2866 getPersistence().addRoles(pk, rolePKs); 2867 } 2868 2869 /** 2870 * Adds an association between the user and the roles. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2871 * 2872 * @param pk the primary key of the user 2873 * @param roles the roles 2874 */ 2875 public static void addRoles(long pk, 2876 List<com.liferay.portal.kernel.model.Role> roles) { 2877 getPersistence().addRoles(pk, roles); 2878 } 2879 2880 /** 2881 * Clears all associations between the user and its roles. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2882 * 2883 * @param pk the primary key of the user to clear the associated roles from 2884 */ 2885 public static void clearRoles(long pk) { 2886 getPersistence().clearRoles(pk); 2887 } 2888 2889 /** 2890 * Removes the association between the user and the role. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2891 * 2892 * @param pk the primary key of the user 2893 * @param rolePK the primary key of the role 2894 */ 2895 public static void removeRole(long pk, long rolePK) { 2896 getPersistence().removeRole(pk, rolePK); 2897 } 2898 2899 /** 2900 * Removes the association between the user and the role. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2901 * 2902 * @param pk the primary key of the user 2903 * @param role the role 2904 */ 2905 public static void removeRole(long pk, 2906 com.liferay.portal.kernel.model.Role role) { 2907 getPersistence().removeRole(pk, role); 2908 } 2909 2910 /** 2911 * Removes the association between the user and the roles. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2912 * 2913 * @param pk the primary key of the user 2914 * @param rolePKs the primary keys of the roles 2915 */ 2916 public static void removeRoles(long pk, long[] rolePKs) { 2917 getPersistence().removeRoles(pk, rolePKs); 2918 } 2919 2920 /** 2921 * Removes the association between the user and the roles. Also notifies the appropriate model listeners and clears the mapping table finder cache. 2922 * 2923 * @param pk the primary key of the user 2924 * @param roles the roles 2925 */ 2926 public static void removeRoles(long pk, 2927 List<com.liferay.portal.kernel.model.Role> roles) { 2928 getPersistence().removeRoles(pk, roles); 2929 } 2930 2931 /** 2932 * 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. 2933 * 2934 * @param pk the primary key of the user 2935 * @param rolePKs the primary keys of the roles to be associated with the user 2936 */ 2937 public static void setRoles(long pk, long[] rolePKs) { 2938 getPersistence().setRoles(pk, rolePKs); 2939 } 2940 2941 /** 2942 * 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. 2943 * 2944 * @param pk the primary key of the user 2945 * @param roles the roles to be associated with the user 2946 */ 2947 public static void setRoles(long pk, 2948 List<com.liferay.portal.kernel.model.Role> roles) { 2949 getPersistence().setRoles(pk, roles); 2950 } 2951 2952 /** 2953 * Returns the primaryKeys of teams associated with the user. 2954 * 2955 * @param pk the primary key of the user 2956 * @return long[] of the primaryKeys of teams associated with the user 2957 */ 2958 public static long[] getTeamPrimaryKeys(long pk) { 2959 return getPersistence().getTeamPrimaryKeys(pk); 2960 } 2961 2962 /** 2963 * Returns all the teams associated with the user. 2964 * 2965 * @param pk the primary key of the user 2966 * @return the teams associated with the user 2967 */ 2968 public static List<com.liferay.portal.kernel.model.Team> getTeams(long pk) { 2969 return getPersistence().getTeams(pk); 2970 } 2971 2972 /** 2973 * Returns a range of all the teams associated with the user. 2974 * 2975 * <p> 2976 * 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. 2977 * </p> 2978 * 2979 * @param pk the primary key of the user 2980 * @param start the lower bound of the range of users 2981 * @param end the upper bound of the range of users (not inclusive) 2982 * @return the range of teams associated with the user 2983 */ 2984 public static List<com.liferay.portal.kernel.model.Team> getTeams(long pk, 2985 int start, int end) { 2986 return getPersistence().getTeams(pk, start, end); 2987 } 2988 2989 /** 2990 * Returns an ordered range of all the teams associated with the user. 2991 * 2992 * <p> 2993 * 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. 2994 * </p> 2995 * 2996 * @param pk the primary key of the user 2997 * @param start the lower bound of the range of users 2998 * @param end the upper bound of the range of users (not inclusive) 2999 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 3000 * @return the ordered range of teams associated with the user 3001 */ 3002 public static List<com.liferay.portal.kernel.model.Team> getTeams(long pk, 3003 int start, int end, 3004 OrderByComparator<com.liferay.portal.kernel.model.Team> orderByComparator) { 3005 return getPersistence().getTeams(pk, start, end, orderByComparator); 3006 } 3007 3008 /** 3009 * Returns the number of teams associated with the user. 3010 * 3011 * @param pk the primary key of the user 3012 * @return the number of teams associated with the user 3013 */ 3014 public static int getTeamsSize(long pk) { 3015 return getPersistence().getTeamsSize(pk); 3016 } 3017 3018 /** 3019 * Returns <code>true</code> if the team is associated with the user. 3020 * 3021 * @param pk the primary key of the user 3022 * @param teamPK the primary key of the team 3023 * @return <code>true</code> if the team is associated with the user; <code>false</code> otherwise 3024 */ 3025 public static boolean containsTeam(long pk, long teamPK) { 3026 return getPersistence().containsTeam(pk, teamPK); 3027 } 3028 3029 /** 3030 * Returns <code>true</code> if the user has any teams associated with it. 3031 * 3032 * @param pk the primary key of the user to check for associations with teams 3033 * @return <code>true</code> if the user has any teams associated with it; <code>false</code> otherwise 3034 */ 3035 public static boolean containsTeams(long pk) { 3036 return getPersistence().containsTeams(pk); 3037 } 3038 3039 /** 3040 * Adds an association between the user and the team. Also notifies the appropriate model listeners and clears the mapping table finder cache. 3041 * 3042 * @param pk the primary key of the user 3043 * @param teamPK the primary key of the team 3044 */ 3045 public static void addTeam(long pk, long teamPK) { 3046 getPersistence().addTeam(pk, teamPK); 3047 } 3048 3049 /** 3050 * Adds an association between the user and the team. Also notifies the appropriate model listeners and clears the mapping table finder cache. 3051 * 3052 * @param pk the primary key of the user 3053 * @param team the team 3054 */ 3055 public static void addTeam(long pk, 3056 com.liferay.portal.kernel.model.Team team) { 3057 getPersistence().addTeam(pk, team); 3058 } 3059 3060 /** 3061 * Adds an association between the user and the teams. Also notifies the appropriate model listeners and clears the mapping table finder cache. 3062 * 3063 * @param pk the primary key of the user 3064 * @param teamPKs the primary keys of the teams 3065 */ 3066 public static void addTeams(long pk, long[] teamPKs) { 3067 getPersistence().addTeams(pk, teamPKs); 3068 } 3069 3070 /** 3071 * Adds an association between the user and the teams. Also notifies the appropriate model listeners and clears the mapping table finder cache. 3072 * 3073 * @param pk the primary key of the user 3074 * @param teams the teams 3075 */ 3076 public static void addTeams(long pk, 3077 List<com.liferay.portal.kernel.model.Team> teams) { 3078 getPersistence().addTeams(pk, teams); 3079 } 3080 3081 /** 3082 * Clears all associations between the user and its teams. Also notifies the appropriate model listeners and clears the mapping table finder cache. 3083 * 3084 * @param pk the primary key of the user to clear the associated teams from 3085 */ 3086 public static void clearTeams(long pk) { 3087 getPersistence().clearTeams(pk); 3088 } 3089 3090 /** 3091 * Removes the association between the user and the team. Also notifies the appropriate model listeners and clears the mapping table finder cache. 3092 * 3093 * @param pk the primary key of the user 3094 * @param teamPK the primary key of the team 3095 */ 3096 public static void removeTeam(long pk, long teamPK) { 3097 getPersistence().removeTeam(pk, teamPK); 3098 } 3099 3100 /** 3101 * Removes the association between the user and the team. Also notifies the appropriate model listeners and clears the mapping table finder cache. 3102 * 3103 * @param pk the primary key of the user 3104 * @param team the team 3105 */ 3106 public static void removeTeam(long pk, 3107 com.liferay.portal.kernel.model.Team team) { 3108 getPersistence().removeTeam(pk, team); 3109 } 3110 3111 /** 3112 * Removes the association between the user and the teams. Also notifies the appropriate model listeners and clears the mapping table finder cache. 3113 * 3114 * @param pk the primary key of the user 3115 * @param teamPKs the primary keys of the teams 3116 */ 3117 public static void removeTeams(long pk, long[] teamPKs) { 3118 getPersistence().removeTeams(pk, teamPKs); 3119 } 3120 3121 /** 3122 * Removes the association between the user and the teams. Also notifies the appropriate model listeners and clears the mapping table finder cache. 3123 * 3124 * @param pk the primary key of the user 3125 * @param teams the teams 3126 */ 3127 public static void removeTeams(long pk, 3128 List<com.liferay.portal.kernel.model.Team> teams) { 3129 getPersistence().removeTeams(pk, teams); 3130 } 3131 3132 /** 3133 * 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. 3134 * 3135 * @param pk the primary key of the user 3136 * @param teamPKs the primary keys of the teams to be associated with the user 3137 */ 3138 public static void setTeams(long pk, long[] teamPKs) { 3139 getPersistence().setTeams(pk, teamPKs); 3140 } 3141 3142 /** 3143 * 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. 3144 * 3145 * @param pk the primary key of the user 3146 * @param teams the teams to be associated with the user 3147 */ 3148 public static void setTeams(long pk, 3149 List<com.liferay.portal.kernel.model.Team> teams) { 3150 getPersistence().setTeams(pk, teams); 3151 } 3152 3153 /** 3154 * Returns the primaryKeys of user groups associated with the user. 3155 * 3156 * @param pk the primary key of the user 3157 * @return long[] of the primaryKeys of user groups associated with the user 3158 */ 3159 public static long[] getUserGroupPrimaryKeys(long pk) { 3160 return getPersistence().getUserGroupPrimaryKeys(pk); 3161 } 3162 3163 /** 3164 * Returns all the user groups associated with the user. 3165 * 3166 * @param pk the primary key of the user 3167 * @return the user groups associated with the user 3168 */ 3169 public static List<com.liferay.portal.kernel.model.UserGroup> getUserGroups( 3170 long pk) { 3171 return getPersistence().getUserGroups(pk); 3172 } 3173 3174 /** 3175 * Returns a range of all the user groups associated with the user. 3176 * 3177 * <p> 3178 * 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. 3179 * </p> 3180 * 3181 * @param pk the primary key of the user 3182 * @param start the lower bound of the range of users 3183 * @param end the upper bound of the range of users (not inclusive) 3184 * @return the range of user groups associated with the user 3185 */ 3186 public static List<com.liferay.portal.kernel.model.UserGroup> getUserGroups( 3187 long pk, int start, int end) { 3188 return getPersistence().getUserGroups(pk, start, end); 3189 } 3190 3191 /** 3192 * Returns an ordered range of all the user groups associated with the user. 3193 * 3194 * <p> 3195 * 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. 3196 * </p> 3197 * 3198 * @param pk the primary key of the user 3199 * @param start the lower bound of the range of users 3200 * @param end the upper bound of the range of users (not inclusive) 3201 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 3202 * @return the ordered range of user groups associated with the user 3203 */ 3204 public static List<com.liferay.portal.kernel.model.UserGroup> getUserGroups( 3205 long pk, int start, int end, 3206 OrderByComparator<com.liferay.portal.kernel.model.UserGroup> orderByComparator) { 3207 return getPersistence().getUserGroups(pk, start, end, orderByComparator); 3208 } 3209 3210 /** 3211 * Returns the number of user groups associated with the user. 3212 * 3213 * @param pk the primary key of the user 3214 * @return the number of user groups associated with the user 3215 */ 3216 public static int getUserGroupsSize(long pk) { 3217 return getPersistence().getUserGroupsSize(pk); 3218 } 3219 3220 /** 3221 * Returns <code>true</code> if the user group is associated with the user. 3222 * 3223 * @param pk the primary key of the user 3224 * @param userGroupPK the primary key of the user group 3225 * @return <code>true</code> if the user group is associated with the user; <code>false</code> otherwise 3226 */ 3227 public static boolean containsUserGroup(long pk, long userGroupPK) { 3228 return getPersistence().containsUserGroup(pk, userGroupPK); 3229 } 3230 3231 /** 3232 * Returns <code>true</code> if the user has any user groups associated with it. 3233 * 3234 * @param pk the primary key of the user to check for associations with user groups 3235 * @return <code>true</code> if the user has any user groups associated with it; <code>false</code> otherwise 3236 */ 3237 public static boolean containsUserGroups(long pk) { 3238 return getPersistence().containsUserGroups(pk); 3239 } 3240 3241 /** 3242 * Adds an association between the user and the user group. Also notifies the appropriate model listeners and clears the mapping table finder cache. 3243 * 3244 * @param pk the primary key of the user 3245 * @param userGroupPK the primary key of the user group 3246 */ 3247 public static void addUserGroup(long pk, long userGroupPK) { 3248 getPersistence().addUserGroup(pk, userGroupPK); 3249 } 3250 3251 /** 3252 * Adds an association between the user and the user group. Also notifies the appropriate model listeners and clears the mapping table finder cache. 3253 * 3254 * @param pk the primary key of the user 3255 * @param userGroup the user group 3256 */ 3257 public static void addUserGroup(long pk, 3258 com.liferay.portal.kernel.model.UserGroup userGroup) { 3259 getPersistence().addUserGroup(pk, userGroup); 3260 } 3261 3262 /** 3263 * Adds an association between the user and the user groups. Also notifies the appropriate model listeners and clears the mapping table finder cache. 3264 * 3265 * @param pk the primary key of the user 3266 * @param userGroupPKs the primary keys of the user groups 3267 */ 3268 public static void addUserGroups(long pk, long[] userGroupPKs) { 3269 getPersistence().addUserGroups(pk, userGroupPKs); 3270 } 3271 3272 /** 3273 * Adds an association between the user and the user groups. Also notifies the appropriate model listeners and clears the mapping table finder cache. 3274 * 3275 * @param pk the primary key of the user 3276 * @param userGroups the user groups 3277 */ 3278 public static void addUserGroups(long pk, 3279 List<com.liferay.portal.kernel.model.UserGroup> userGroups) { 3280 getPersistence().addUserGroups(pk, userGroups); 3281 } 3282 3283 /** 3284 * Clears all associations between the user and its user groups. Also notifies the appropriate model listeners and clears the mapping table finder cache. 3285 * 3286 * @param pk the primary key of the user to clear the associated user groups from 3287 */ 3288 public static void clearUserGroups(long pk) { 3289 getPersistence().clearUserGroups(pk); 3290 } 3291 3292 /** 3293 * Removes the association between the user and the user group. Also notifies the appropriate model listeners and clears the mapping table finder cache. 3294 * 3295 * @param pk the primary key of the user 3296 * @param userGroupPK the primary key of the user group 3297 */ 3298 public static void removeUserGroup(long pk, long userGroupPK) { 3299 getPersistence().removeUserGroup(pk, userGroupPK); 3300 } 3301 3302 /** 3303 * Removes the association between the user and the user group. Also notifies the appropriate model listeners and clears the mapping table finder cache. 3304 * 3305 * @param pk the primary key of the user 3306 * @param userGroup the user group 3307 */ 3308 public static void removeUserGroup(long pk, 3309 com.liferay.portal.kernel.model.UserGroup userGroup) { 3310 getPersistence().removeUserGroup(pk, userGroup); 3311 } 3312 3313 /** 3314 * Removes the association between the user and the user groups. Also notifies the appropriate model listeners and clears the mapping table finder cache. 3315 * 3316 * @param pk the primary key of the user 3317 * @param userGroupPKs the primary keys of the user groups 3318 */ 3319 public static void removeUserGroups(long pk, long[] userGroupPKs) { 3320 getPersistence().removeUserGroups(pk, userGroupPKs); 3321 } 3322 3323 /** 3324 * Removes the association between the user and the user groups. Also notifies the appropriate model listeners and clears the mapping table finder cache. 3325 * 3326 * @param pk the primary key of the user 3327 * @param userGroups the user groups 3328 */ 3329 public static void removeUserGroups(long pk, 3330 List<com.liferay.portal.kernel.model.UserGroup> userGroups) { 3331 getPersistence().removeUserGroups(pk, userGroups); 3332 } 3333 3334 /** 3335 * 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. 3336 * 3337 * @param pk the primary key of the user 3338 * @param userGroupPKs the primary keys of the user groups to be associated with the user 3339 */ 3340 public static void setUserGroups(long pk, long[] userGroupPKs) { 3341 getPersistence().setUserGroups(pk, userGroupPKs); 3342 } 3343 3344 /** 3345 * 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. 3346 * 3347 * @param pk the primary key of the user 3348 * @param userGroups the user groups to be associated with the user 3349 */ 3350 public static void setUserGroups(long pk, 3351 List<com.liferay.portal.kernel.model.UserGroup> userGroups) { 3352 getPersistence().setUserGroups(pk, userGroups); 3353 } 3354 3355 public static java.util.Set<java.lang.String> getBadColumnNames() { 3356 return getPersistence().getBadColumnNames(); 3357 } 3358 3359 public static UserPersistence getPersistence() { 3360 if (_persistence == null) { 3361 _persistence = (UserPersistence)PortalBeanLocatorUtil.locate(UserPersistence.class.getName()); 3362 3363 ReferenceRegistry.registerReference(UserUtil.class, "_persistence"); 3364 } 3365 3366 return _persistence; 3367 } 3368 3369 private static UserPersistence _persistence; 3370 }