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