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