001 /** 002 * Copyright (c) 2000-present Liferay, Inc. All rights reserved. 003 * 004 * This library is free software; you can redistribute it and/or modify it under 005 * the terms of the GNU Lesser General Public License as published by the Free 006 * Software Foundation; either version 2.1 of the License, or (at your option) 007 * any later version. 008 * 009 * This library is distributed in the hope that it will be useful, but WITHOUT 010 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS 011 * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more 012 * details. 013 */ 014 015 package com.liferay.portal.service.persistence; 016 017 import aQute.bnd.annotation.ProviderType; 018 019 import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil; 020 import com.liferay.portal.kernel.dao.orm.DynamicQuery; 021 import com.liferay.portal.kernel.util.OrderByComparator; 022 import com.liferay.portal.kernel.util.ReferenceRegistry; 023 import com.liferay.portal.model.UserGroupGroupRole; 024 import com.liferay.portal.service.ServiceContext; 025 026 import java.util.List; 027 028 /** 029 * The persistence utility for the user group group role service. This utility wraps {@link com.liferay.portal.service.persistence.impl.UserGroupGroupRolePersistenceImpl} and provides direct access to the database for CRUD operations. This utility should only be used by the service layer, as it must operate within a transaction. Never access this utility in a JSP, controller, model, or other front-end class. 030 * 031 * <p> 032 * Caching information and settings can be found in <code>portal.properties</code> 033 * </p> 034 * 035 * @author Brian Wing Shun Chan 036 * @see UserGroupGroupRolePersistence 037 * @see com.liferay.portal.service.persistence.impl.UserGroupGroupRolePersistenceImpl 038 * @generated 039 */ 040 @ProviderType 041 public class UserGroupGroupRoleUtil { 042 /* 043 * NOTE FOR DEVELOPERS: 044 * 045 * Never modify this class directly. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this class. 046 */ 047 048 /** 049 * @see com.liferay.portal.service.persistence.BasePersistence#clearCache() 050 */ 051 public static void clearCache() { 052 getPersistence().clearCache(); 053 } 054 055 /** 056 * @see com.liferay.portal.service.persistence.BasePersistence#clearCache(com.liferay.portal.model.BaseModel) 057 */ 058 public static void clearCache(UserGroupGroupRole userGroupGroupRole) { 059 getPersistence().clearCache(userGroupGroupRole); 060 } 061 062 /** 063 * @see com.liferay.portal.service.persistence.BasePersistence#countWithDynamicQuery(DynamicQuery) 064 */ 065 public static long countWithDynamicQuery(DynamicQuery dynamicQuery) { 066 return getPersistence().countWithDynamicQuery(dynamicQuery); 067 } 068 069 /** 070 * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery) 071 */ 072 public static List<UserGroupGroupRole> findWithDynamicQuery( 073 DynamicQuery dynamicQuery) { 074 return getPersistence().findWithDynamicQuery(dynamicQuery); 075 } 076 077 /** 078 * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int) 079 */ 080 public static List<UserGroupGroupRole> findWithDynamicQuery( 081 DynamicQuery dynamicQuery, int start, int end) { 082 return getPersistence().findWithDynamicQuery(dynamicQuery, start, end); 083 } 084 085 /** 086 * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int, OrderByComparator) 087 */ 088 public static List<UserGroupGroupRole> findWithDynamicQuery( 089 DynamicQuery dynamicQuery, int start, int end, 090 OrderByComparator<UserGroupGroupRole> orderByComparator) { 091 return getPersistence() 092 .findWithDynamicQuery(dynamicQuery, start, end, 093 orderByComparator); 094 } 095 096 /** 097 * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel) 098 */ 099 public static UserGroupGroupRole update( 100 UserGroupGroupRole userGroupGroupRole) { 101 return getPersistence().update(userGroupGroupRole); 102 } 103 104 /** 105 * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, ServiceContext) 106 */ 107 public static UserGroupGroupRole update( 108 UserGroupGroupRole userGroupGroupRole, ServiceContext serviceContext) { 109 return getPersistence().update(userGroupGroupRole, serviceContext); 110 } 111 112 /** 113 * Returns all the user group group roles where userGroupId = ?. 114 * 115 * @param userGroupId the user group ID 116 * @return the matching user group group roles 117 */ 118 public static List<UserGroupGroupRole> findByUserGroupId(long userGroupId) { 119 return getPersistence().findByUserGroupId(userGroupId); 120 } 121 122 /** 123 * Returns a range of all the user group group roles where userGroupId = ?. 124 * 125 * <p> 126 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link UserGroupGroupRoleModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order. 127 * </p> 128 * 129 * @param userGroupId the user group ID 130 * @param start the lower bound of the range of user group group roles 131 * @param end the upper bound of the range of user group group roles (not inclusive) 132 * @return the range of matching user group group roles 133 */ 134 public static List<UserGroupGroupRole> findByUserGroupId(long userGroupId, 135 int start, int end) { 136 return getPersistence().findByUserGroupId(userGroupId, start, end); 137 } 138 139 /** 140 * Returns an ordered range of all the user group group roles where userGroupId = ?. 141 * 142 * <p> 143 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link UserGroupGroupRoleModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order. 144 * </p> 145 * 146 * @param userGroupId the user group ID 147 * @param start the lower bound of the range of user group group roles 148 * @param end the upper bound of the range of user group group roles (not inclusive) 149 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 150 * @return the ordered range of matching user group group roles 151 */ 152 public static List<UserGroupGroupRole> findByUserGroupId(long userGroupId, 153 int start, int end, 154 OrderByComparator<UserGroupGroupRole> orderByComparator) { 155 return getPersistence() 156 .findByUserGroupId(userGroupId, start, end, orderByComparator); 157 } 158 159 /** 160 * Returns the first user group group role in the ordered set where userGroupId = ?. 161 * 162 * @param userGroupId the user group ID 163 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 164 * @return the first matching user group group role 165 * @throws NoSuchUserGroupGroupRoleException if a matching user group group role could not be found 166 */ 167 public static UserGroupGroupRole findByUserGroupId_First(long userGroupId, 168 OrderByComparator<UserGroupGroupRole> orderByComparator) 169 throws com.liferay.portal.NoSuchUserGroupGroupRoleException { 170 return getPersistence() 171 .findByUserGroupId_First(userGroupId, orderByComparator); 172 } 173 174 /** 175 * Returns the first user group group role in the ordered set where userGroupId = ?. 176 * 177 * @param userGroupId the user group ID 178 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 179 * @return the first matching user group group role, or <code>null</code> if a matching user group group role could not be found 180 */ 181 public static UserGroupGroupRole fetchByUserGroupId_First( 182 long userGroupId, 183 OrderByComparator<UserGroupGroupRole> orderByComparator) { 184 return getPersistence() 185 .fetchByUserGroupId_First(userGroupId, orderByComparator); 186 } 187 188 /** 189 * Returns the last user group group role in the ordered set where userGroupId = ?. 190 * 191 * @param userGroupId the user group ID 192 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 193 * @return the last matching user group group role 194 * @throws NoSuchUserGroupGroupRoleException if a matching user group group role could not be found 195 */ 196 public static UserGroupGroupRole findByUserGroupId_Last(long userGroupId, 197 OrderByComparator<UserGroupGroupRole> orderByComparator) 198 throws com.liferay.portal.NoSuchUserGroupGroupRoleException { 199 return getPersistence() 200 .findByUserGroupId_Last(userGroupId, orderByComparator); 201 } 202 203 /** 204 * Returns the last user group group role in the ordered set where userGroupId = ?. 205 * 206 * @param userGroupId the user group ID 207 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 208 * @return the last matching user group group role, or <code>null</code> if a matching user group group role could not be found 209 */ 210 public static UserGroupGroupRole fetchByUserGroupId_Last(long userGroupId, 211 OrderByComparator<UserGroupGroupRole> orderByComparator) { 212 return getPersistence() 213 .fetchByUserGroupId_Last(userGroupId, orderByComparator); 214 } 215 216 /** 217 * Returns the user group group roles before and after the current user group group role in the ordered set where userGroupId = ?. 218 * 219 * @param userGroupGroupRolePK the primary key of the current user group group role 220 * @param userGroupId the user group ID 221 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 222 * @return the previous, current, and next user group group role 223 * @throws NoSuchUserGroupGroupRoleException if a user group group role with the primary key could not be found 224 */ 225 public static UserGroupGroupRole[] findByUserGroupId_PrevAndNext( 226 com.liferay.portal.service.persistence.UserGroupGroupRolePK userGroupGroupRolePK, 227 long userGroupId, 228 OrderByComparator<UserGroupGroupRole> orderByComparator) 229 throws com.liferay.portal.NoSuchUserGroupGroupRoleException { 230 return getPersistence() 231 .findByUserGroupId_PrevAndNext(userGroupGroupRolePK, 232 userGroupId, orderByComparator); 233 } 234 235 /** 236 * Removes all the user group group roles where userGroupId = ? from the database. 237 * 238 * @param userGroupId the user group ID 239 */ 240 public static void removeByUserGroupId(long userGroupId) { 241 getPersistence().removeByUserGroupId(userGroupId); 242 } 243 244 /** 245 * Returns the number of user group group roles where userGroupId = ?. 246 * 247 * @param userGroupId the user group ID 248 * @return the number of matching user group group roles 249 */ 250 public static int countByUserGroupId(long userGroupId) { 251 return getPersistence().countByUserGroupId(userGroupId); 252 } 253 254 /** 255 * Returns all the user group group roles where groupId = ?. 256 * 257 * @param groupId the group ID 258 * @return the matching user group group roles 259 */ 260 public static List<UserGroupGroupRole> findByGroupId(long groupId) { 261 return getPersistence().findByGroupId(groupId); 262 } 263 264 /** 265 * Returns a range of all the user group group roles where groupId = ?. 266 * 267 * <p> 268 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link UserGroupGroupRoleModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order. 269 * </p> 270 * 271 * @param groupId the group ID 272 * @param start the lower bound of the range of user group group roles 273 * @param end the upper bound of the range of user group group roles (not inclusive) 274 * @return the range of matching user group group roles 275 */ 276 public static List<UserGroupGroupRole> findByGroupId(long groupId, 277 int start, int end) { 278 return getPersistence().findByGroupId(groupId, start, end); 279 } 280 281 /** 282 * Returns an ordered range of all the user group group roles where groupId = ?. 283 * 284 * <p> 285 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link UserGroupGroupRoleModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order. 286 * </p> 287 * 288 * @param groupId the group ID 289 * @param start the lower bound of the range of user group group roles 290 * @param end the upper bound of the range of user group group roles (not inclusive) 291 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 292 * @return the ordered range of matching user group group roles 293 */ 294 public static List<UserGroupGroupRole> findByGroupId(long groupId, 295 int start, int end, 296 OrderByComparator<UserGroupGroupRole> orderByComparator) { 297 return getPersistence() 298 .findByGroupId(groupId, start, end, orderByComparator); 299 } 300 301 /** 302 * Returns the first user group group role in the ordered set where groupId = ?. 303 * 304 * @param groupId the group ID 305 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 306 * @return the first matching user group group role 307 * @throws NoSuchUserGroupGroupRoleException if a matching user group group role could not be found 308 */ 309 public static UserGroupGroupRole findByGroupId_First(long groupId, 310 OrderByComparator<UserGroupGroupRole> orderByComparator) 311 throws com.liferay.portal.NoSuchUserGroupGroupRoleException { 312 return getPersistence().findByGroupId_First(groupId, orderByComparator); 313 } 314 315 /** 316 * Returns the first user group group role in the ordered set where groupId = ?. 317 * 318 * @param groupId the group ID 319 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 320 * @return the first matching user group group role, or <code>null</code> if a matching user group group role could not be found 321 */ 322 public static UserGroupGroupRole fetchByGroupId_First(long groupId, 323 OrderByComparator<UserGroupGroupRole> orderByComparator) { 324 return getPersistence().fetchByGroupId_First(groupId, orderByComparator); 325 } 326 327 /** 328 * Returns the last user group group role in the ordered set where groupId = ?. 329 * 330 * @param groupId the group ID 331 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 332 * @return the last matching user group group role 333 * @throws NoSuchUserGroupGroupRoleException if a matching user group group role could not be found 334 */ 335 public static UserGroupGroupRole findByGroupId_Last(long groupId, 336 OrderByComparator<UserGroupGroupRole> orderByComparator) 337 throws com.liferay.portal.NoSuchUserGroupGroupRoleException { 338 return getPersistence().findByGroupId_Last(groupId, orderByComparator); 339 } 340 341 /** 342 * Returns the last user group group role in the ordered set where groupId = ?. 343 * 344 * @param groupId the group ID 345 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 346 * @return the last matching user group group role, or <code>null</code> if a matching user group group role could not be found 347 */ 348 public static UserGroupGroupRole fetchByGroupId_Last(long groupId, 349 OrderByComparator<UserGroupGroupRole> orderByComparator) { 350 return getPersistence().fetchByGroupId_Last(groupId, orderByComparator); 351 } 352 353 /** 354 * Returns the user group group roles before and after the current user group group role in the ordered set where groupId = ?. 355 * 356 * @param userGroupGroupRolePK the primary key of the current user group group role 357 * @param groupId the group ID 358 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 359 * @return the previous, current, and next user group group role 360 * @throws NoSuchUserGroupGroupRoleException if a user group group role with the primary key could not be found 361 */ 362 public static UserGroupGroupRole[] findByGroupId_PrevAndNext( 363 com.liferay.portal.service.persistence.UserGroupGroupRolePK userGroupGroupRolePK, 364 long groupId, OrderByComparator<UserGroupGroupRole> orderByComparator) 365 throws com.liferay.portal.NoSuchUserGroupGroupRoleException { 366 return getPersistence() 367 .findByGroupId_PrevAndNext(userGroupGroupRolePK, groupId, 368 orderByComparator); 369 } 370 371 /** 372 * Removes all the user group group roles where groupId = ? from the database. 373 * 374 * @param groupId the group ID 375 */ 376 public static void removeByGroupId(long groupId) { 377 getPersistence().removeByGroupId(groupId); 378 } 379 380 /** 381 * Returns the number of user group group roles where groupId = ?. 382 * 383 * @param groupId the group ID 384 * @return the number of matching user group group roles 385 */ 386 public static int countByGroupId(long groupId) { 387 return getPersistence().countByGroupId(groupId); 388 } 389 390 /** 391 * Returns all the user group group roles where roleId = ?. 392 * 393 * @param roleId the role ID 394 * @return the matching user group group roles 395 */ 396 public static List<UserGroupGroupRole> findByRoleId(long roleId) { 397 return getPersistence().findByRoleId(roleId); 398 } 399 400 /** 401 * Returns a range of all the user group group roles where roleId = ?. 402 * 403 * <p> 404 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link UserGroupGroupRoleModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order. 405 * </p> 406 * 407 * @param roleId the role ID 408 * @param start the lower bound of the range of user group group roles 409 * @param end the upper bound of the range of user group group roles (not inclusive) 410 * @return the range of matching user group group roles 411 */ 412 public static List<UserGroupGroupRole> findByRoleId(long roleId, int start, 413 int end) { 414 return getPersistence().findByRoleId(roleId, start, end); 415 } 416 417 /** 418 * Returns an ordered range of all the user group group roles where roleId = ?. 419 * 420 * <p> 421 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link UserGroupGroupRoleModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order. 422 * </p> 423 * 424 * @param roleId the role ID 425 * @param start the lower bound of the range of user group group roles 426 * @param end the upper bound of the range of user group group roles (not inclusive) 427 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 428 * @return the ordered range of matching user group group roles 429 */ 430 public static List<UserGroupGroupRole> findByRoleId(long roleId, int start, 431 int end, OrderByComparator<UserGroupGroupRole> orderByComparator) { 432 return getPersistence() 433 .findByRoleId(roleId, start, end, orderByComparator); 434 } 435 436 /** 437 * Returns the first user group group role in the ordered set where roleId = ?. 438 * 439 * @param roleId the role ID 440 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 441 * @return the first matching user group group role 442 * @throws NoSuchUserGroupGroupRoleException if a matching user group group role could not be found 443 */ 444 public static UserGroupGroupRole findByRoleId_First(long roleId, 445 OrderByComparator<UserGroupGroupRole> orderByComparator) 446 throws com.liferay.portal.NoSuchUserGroupGroupRoleException { 447 return getPersistence().findByRoleId_First(roleId, orderByComparator); 448 } 449 450 /** 451 * Returns the first user group group role in the ordered set where roleId = ?. 452 * 453 * @param roleId the role ID 454 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 455 * @return the first matching user group group role, or <code>null</code> if a matching user group group role could not be found 456 */ 457 public static UserGroupGroupRole fetchByRoleId_First(long roleId, 458 OrderByComparator<UserGroupGroupRole> orderByComparator) { 459 return getPersistence().fetchByRoleId_First(roleId, orderByComparator); 460 } 461 462 /** 463 * Returns the last user group group role in the ordered set where roleId = ?. 464 * 465 * @param roleId the role ID 466 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 467 * @return the last matching user group group role 468 * @throws NoSuchUserGroupGroupRoleException if a matching user group group role could not be found 469 */ 470 public static UserGroupGroupRole findByRoleId_Last(long roleId, 471 OrderByComparator<UserGroupGroupRole> orderByComparator) 472 throws com.liferay.portal.NoSuchUserGroupGroupRoleException { 473 return getPersistence().findByRoleId_Last(roleId, orderByComparator); 474 } 475 476 /** 477 * Returns the last user group group role in the ordered set where roleId = ?. 478 * 479 * @param roleId the role ID 480 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 481 * @return the last matching user group group role, or <code>null</code> if a matching user group group role could not be found 482 */ 483 public static UserGroupGroupRole fetchByRoleId_Last(long roleId, 484 OrderByComparator<UserGroupGroupRole> orderByComparator) { 485 return getPersistence().fetchByRoleId_Last(roleId, orderByComparator); 486 } 487 488 /** 489 * Returns the user group group roles before and after the current user group group role in the ordered set where roleId = ?. 490 * 491 * @param userGroupGroupRolePK the primary key of the current user group group role 492 * @param roleId the role ID 493 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 494 * @return the previous, current, and next user group group role 495 * @throws NoSuchUserGroupGroupRoleException if a user group group role with the primary key could not be found 496 */ 497 public static UserGroupGroupRole[] findByRoleId_PrevAndNext( 498 com.liferay.portal.service.persistence.UserGroupGroupRolePK userGroupGroupRolePK, 499 long roleId, OrderByComparator<UserGroupGroupRole> orderByComparator) 500 throws com.liferay.portal.NoSuchUserGroupGroupRoleException { 501 return getPersistence() 502 .findByRoleId_PrevAndNext(userGroupGroupRolePK, roleId, 503 orderByComparator); 504 } 505 506 /** 507 * Removes all the user group group roles where roleId = ? from the database. 508 * 509 * @param roleId the role ID 510 */ 511 public static void removeByRoleId(long roleId) { 512 getPersistence().removeByRoleId(roleId); 513 } 514 515 /** 516 * Returns the number of user group group roles where roleId = ?. 517 * 518 * @param roleId the role ID 519 * @return the number of matching user group group roles 520 */ 521 public static int countByRoleId(long roleId) { 522 return getPersistence().countByRoleId(roleId); 523 } 524 525 /** 526 * Returns all the user group group roles where userGroupId = ? and groupId = ?. 527 * 528 * @param userGroupId the user group ID 529 * @param groupId the group ID 530 * @return the matching user group group roles 531 */ 532 public static List<UserGroupGroupRole> findByU_G(long userGroupId, 533 long groupId) { 534 return getPersistence().findByU_G(userGroupId, groupId); 535 } 536 537 /** 538 * Returns a range of all the user group group roles where userGroupId = ? and groupId = ?. 539 * 540 * <p> 541 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link UserGroupGroupRoleModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order. 542 * </p> 543 * 544 * @param userGroupId the user group ID 545 * @param groupId the group ID 546 * @param start the lower bound of the range of user group group roles 547 * @param end the upper bound of the range of user group group roles (not inclusive) 548 * @return the range of matching user group group roles 549 */ 550 public static List<UserGroupGroupRole> findByU_G(long userGroupId, 551 long groupId, int start, int end) { 552 return getPersistence().findByU_G(userGroupId, groupId, start, end); 553 } 554 555 /** 556 * Returns an ordered range of all the user group group roles where userGroupId = ? and groupId = ?. 557 * 558 * <p> 559 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link UserGroupGroupRoleModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order. 560 * </p> 561 * 562 * @param userGroupId the user group ID 563 * @param groupId the group ID 564 * @param start the lower bound of the range of user group group roles 565 * @param end the upper bound of the range of user group group roles (not inclusive) 566 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 567 * @return the ordered range of matching user group group roles 568 */ 569 public static List<UserGroupGroupRole> findByU_G(long userGroupId, 570 long groupId, int start, int end, 571 OrderByComparator<UserGroupGroupRole> orderByComparator) { 572 return getPersistence() 573 .findByU_G(userGroupId, groupId, start, end, 574 orderByComparator); 575 } 576 577 /** 578 * Returns the first user group group role in the ordered set where userGroupId = ? and groupId = ?. 579 * 580 * @param userGroupId the user group ID 581 * @param groupId the group ID 582 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 583 * @return the first matching user group group role 584 * @throws NoSuchUserGroupGroupRoleException if a matching user group group role could not be found 585 */ 586 public static UserGroupGroupRole findByU_G_First(long userGroupId, 587 long groupId, OrderByComparator<UserGroupGroupRole> orderByComparator) 588 throws com.liferay.portal.NoSuchUserGroupGroupRoleException { 589 return getPersistence() 590 .findByU_G_First(userGroupId, groupId, orderByComparator); 591 } 592 593 /** 594 * Returns the first user group group role in the ordered set where userGroupId = ? and groupId = ?. 595 * 596 * @param userGroupId the user group ID 597 * @param groupId the group ID 598 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 599 * @return the first matching user group group role, or <code>null</code> if a matching user group group role could not be found 600 */ 601 public static UserGroupGroupRole fetchByU_G_First(long userGroupId, 602 long groupId, OrderByComparator<UserGroupGroupRole> orderByComparator) { 603 return getPersistence() 604 .fetchByU_G_First(userGroupId, groupId, orderByComparator); 605 } 606 607 /** 608 * Returns the last user group group role in the ordered set where userGroupId = ? and groupId = ?. 609 * 610 * @param userGroupId the user group ID 611 * @param groupId the group ID 612 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 613 * @return the last matching user group group role 614 * @throws NoSuchUserGroupGroupRoleException if a matching user group group role could not be found 615 */ 616 public static UserGroupGroupRole findByU_G_Last(long userGroupId, 617 long groupId, OrderByComparator<UserGroupGroupRole> orderByComparator) 618 throws com.liferay.portal.NoSuchUserGroupGroupRoleException { 619 return getPersistence() 620 .findByU_G_Last(userGroupId, groupId, orderByComparator); 621 } 622 623 /** 624 * Returns the last user group group role in the ordered set where userGroupId = ? and groupId = ?. 625 * 626 * @param userGroupId the user group ID 627 * @param groupId the group ID 628 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 629 * @return the last matching user group group role, or <code>null</code> if a matching user group group role could not be found 630 */ 631 public static UserGroupGroupRole fetchByU_G_Last(long userGroupId, 632 long groupId, OrderByComparator<UserGroupGroupRole> orderByComparator) { 633 return getPersistence() 634 .fetchByU_G_Last(userGroupId, groupId, orderByComparator); 635 } 636 637 /** 638 * Returns the user group group roles before and after the current user group group role in the ordered set where userGroupId = ? and groupId = ?. 639 * 640 * @param userGroupGroupRolePK the primary key of the current user group group role 641 * @param userGroupId the user group ID 642 * @param groupId the group ID 643 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 644 * @return the previous, current, and next user group group role 645 * @throws NoSuchUserGroupGroupRoleException if a user group group role with the primary key could not be found 646 */ 647 public static UserGroupGroupRole[] findByU_G_PrevAndNext( 648 com.liferay.portal.service.persistence.UserGroupGroupRolePK userGroupGroupRolePK, 649 long userGroupId, long groupId, 650 OrderByComparator<UserGroupGroupRole> orderByComparator) 651 throws com.liferay.portal.NoSuchUserGroupGroupRoleException { 652 return getPersistence() 653 .findByU_G_PrevAndNext(userGroupGroupRolePK, userGroupId, 654 groupId, orderByComparator); 655 } 656 657 /** 658 * Removes all the user group group roles where userGroupId = ? and groupId = ? from the database. 659 * 660 * @param userGroupId the user group ID 661 * @param groupId the group ID 662 */ 663 public static void removeByU_G(long userGroupId, long groupId) { 664 getPersistence().removeByU_G(userGroupId, groupId); 665 } 666 667 /** 668 * Returns the number of user group group roles where userGroupId = ? and groupId = ?. 669 * 670 * @param userGroupId the user group ID 671 * @param groupId the group ID 672 * @return the number of matching user group group roles 673 */ 674 public static int countByU_G(long userGroupId, long groupId) { 675 return getPersistence().countByU_G(userGroupId, groupId); 676 } 677 678 /** 679 * Returns all the user group group roles where groupId = ? and roleId = ?. 680 * 681 * @param groupId the group ID 682 * @param roleId the role ID 683 * @return the matching user group group roles 684 */ 685 public static List<UserGroupGroupRole> findByG_R(long groupId, long roleId) { 686 return getPersistence().findByG_R(groupId, roleId); 687 } 688 689 /** 690 * Returns a range of all the user group group roles where groupId = ? and roleId = ?. 691 * 692 * <p> 693 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link UserGroupGroupRoleModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order. 694 * </p> 695 * 696 * @param groupId the group ID 697 * @param roleId the role ID 698 * @param start the lower bound of the range of user group group roles 699 * @param end the upper bound of the range of user group group roles (not inclusive) 700 * @return the range of matching user group group roles 701 */ 702 public static List<UserGroupGroupRole> findByG_R(long groupId, long roleId, 703 int start, int end) { 704 return getPersistence().findByG_R(groupId, roleId, start, end); 705 } 706 707 /** 708 * Returns an ordered range of all the user group group roles where groupId = ? and roleId = ?. 709 * 710 * <p> 711 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link UserGroupGroupRoleModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order. 712 * </p> 713 * 714 * @param groupId the group ID 715 * @param roleId the role ID 716 * @param start the lower bound of the range of user group group roles 717 * @param end the upper bound of the range of user group group roles (not inclusive) 718 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 719 * @return the ordered range of matching user group group roles 720 */ 721 public static List<UserGroupGroupRole> findByG_R(long groupId, long roleId, 722 int start, int end, 723 OrderByComparator<UserGroupGroupRole> orderByComparator) { 724 return getPersistence() 725 .findByG_R(groupId, roleId, start, end, orderByComparator); 726 } 727 728 /** 729 * Returns the first user group group role in the ordered set where groupId = ? and roleId = ?. 730 * 731 * @param groupId the group ID 732 * @param roleId the role ID 733 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 734 * @return the first matching user group group role 735 * @throws NoSuchUserGroupGroupRoleException if a matching user group group role could not be found 736 */ 737 public static UserGroupGroupRole findByG_R_First(long groupId, long roleId, 738 OrderByComparator<UserGroupGroupRole> orderByComparator) 739 throws com.liferay.portal.NoSuchUserGroupGroupRoleException { 740 return getPersistence() 741 .findByG_R_First(groupId, roleId, orderByComparator); 742 } 743 744 /** 745 * Returns the first user group group role in the ordered set where groupId = ? and roleId = ?. 746 * 747 * @param groupId the group ID 748 * @param roleId the role ID 749 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 750 * @return the first matching user group group role, or <code>null</code> if a matching user group group role could not be found 751 */ 752 public static UserGroupGroupRole fetchByG_R_First(long groupId, 753 long roleId, OrderByComparator<UserGroupGroupRole> orderByComparator) { 754 return getPersistence() 755 .fetchByG_R_First(groupId, roleId, orderByComparator); 756 } 757 758 /** 759 * Returns the last user group group role in the ordered set where groupId = ? and roleId = ?. 760 * 761 * @param groupId the group ID 762 * @param roleId the role ID 763 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 764 * @return the last matching user group group role 765 * @throws NoSuchUserGroupGroupRoleException if a matching user group group role could not be found 766 */ 767 public static UserGroupGroupRole findByG_R_Last(long groupId, long roleId, 768 OrderByComparator<UserGroupGroupRole> orderByComparator) 769 throws com.liferay.portal.NoSuchUserGroupGroupRoleException { 770 return getPersistence() 771 .findByG_R_Last(groupId, roleId, orderByComparator); 772 } 773 774 /** 775 * Returns the last user group group role in the ordered set where groupId = ? and roleId = ?. 776 * 777 * @param groupId the group ID 778 * @param roleId the role ID 779 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 780 * @return the last matching user group group role, or <code>null</code> if a matching user group group role could not be found 781 */ 782 public static UserGroupGroupRole fetchByG_R_Last(long groupId, long roleId, 783 OrderByComparator<UserGroupGroupRole> orderByComparator) { 784 return getPersistence() 785 .fetchByG_R_Last(groupId, roleId, orderByComparator); 786 } 787 788 /** 789 * Returns the user group group roles before and after the current user group group role in the ordered set where groupId = ? and roleId = ?. 790 * 791 * @param userGroupGroupRolePK the primary key of the current user group group role 792 * @param groupId the group ID 793 * @param roleId the role ID 794 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 795 * @return the previous, current, and next user group group role 796 * @throws NoSuchUserGroupGroupRoleException if a user group group role with the primary key could not be found 797 */ 798 public static UserGroupGroupRole[] findByG_R_PrevAndNext( 799 com.liferay.portal.service.persistence.UserGroupGroupRolePK userGroupGroupRolePK, 800 long groupId, long roleId, 801 OrderByComparator<UserGroupGroupRole> orderByComparator) 802 throws com.liferay.portal.NoSuchUserGroupGroupRoleException { 803 return getPersistence() 804 .findByG_R_PrevAndNext(userGroupGroupRolePK, groupId, 805 roleId, orderByComparator); 806 } 807 808 /** 809 * Removes all the user group group roles where groupId = ? and roleId = ? from the database. 810 * 811 * @param groupId the group ID 812 * @param roleId the role ID 813 */ 814 public static void removeByG_R(long groupId, long roleId) { 815 getPersistence().removeByG_R(groupId, roleId); 816 } 817 818 /** 819 * Returns the number of user group group roles where groupId = ? and roleId = ?. 820 * 821 * @param groupId the group ID 822 * @param roleId the role ID 823 * @return the number of matching user group group roles 824 */ 825 public static int countByG_R(long groupId, long roleId) { 826 return getPersistence().countByG_R(groupId, roleId); 827 } 828 829 /** 830 * Caches the user group group role in the entity cache if it is enabled. 831 * 832 * @param userGroupGroupRole the user group group role 833 */ 834 public static void cacheResult(UserGroupGroupRole userGroupGroupRole) { 835 getPersistence().cacheResult(userGroupGroupRole); 836 } 837 838 /** 839 * Caches the user group group roles in the entity cache if it is enabled. 840 * 841 * @param userGroupGroupRoles the user group group roles 842 */ 843 public static void cacheResult(List<UserGroupGroupRole> userGroupGroupRoles) { 844 getPersistence().cacheResult(userGroupGroupRoles); 845 } 846 847 /** 848 * Creates a new user group group role with the primary key. Does not add the user group group role to the database. 849 * 850 * @param userGroupGroupRolePK the primary key for the new user group group role 851 * @return the new user group group role 852 */ 853 public static UserGroupGroupRole create( 854 com.liferay.portal.service.persistence.UserGroupGroupRolePK userGroupGroupRolePK) { 855 return getPersistence().create(userGroupGroupRolePK); 856 } 857 858 /** 859 * Removes the user group group role with the primary key from the database. Also notifies the appropriate model listeners. 860 * 861 * @param userGroupGroupRolePK the primary key of the user group group role 862 * @return the user group group role that was removed 863 * @throws NoSuchUserGroupGroupRoleException if a user group group role with the primary key could not be found 864 */ 865 public static UserGroupGroupRole remove( 866 com.liferay.portal.service.persistence.UserGroupGroupRolePK userGroupGroupRolePK) 867 throws com.liferay.portal.NoSuchUserGroupGroupRoleException { 868 return getPersistence().remove(userGroupGroupRolePK); 869 } 870 871 public static UserGroupGroupRole updateImpl( 872 UserGroupGroupRole userGroupGroupRole) { 873 return getPersistence().updateImpl(userGroupGroupRole); 874 } 875 876 /** 877 * Returns the user group group role with the primary key or throws a {@link NoSuchUserGroupGroupRoleException} if it could not be found. 878 * 879 * @param userGroupGroupRolePK the primary key of the user group group role 880 * @return the user group group role 881 * @throws NoSuchUserGroupGroupRoleException if a user group group role with the primary key could not be found 882 */ 883 public static UserGroupGroupRole findByPrimaryKey( 884 com.liferay.portal.service.persistence.UserGroupGroupRolePK userGroupGroupRolePK) 885 throws com.liferay.portal.NoSuchUserGroupGroupRoleException { 886 return getPersistence().findByPrimaryKey(userGroupGroupRolePK); 887 } 888 889 /** 890 * Returns the user group group role with the primary key or returns <code>null</code> if it could not be found. 891 * 892 * @param userGroupGroupRolePK the primary key of the user group group role 893 * @return the user group group role, or <code>null</code> if a user group group role with the primary key could not be found 894 */ 895 public static UserGroupGroupRole fetchByPrimaryKey( 896 com.liferay.portal.service.persistence.UserGroupGroupRolePK userGroupGroupRolePK) { 897 return getPersistence().fetchByPrimaryKey(userGroupGroupRolePK); 898 } 899 900 public static java.util.Map<java.io.Serializable, UserGroupGroupRole> fetchByPrimaryKeys( 901 java.util.Set<java.io.Serializable> primaryKeys) { 902 return getPersistence().fetchByPrimaryKeys(primaryKeys); 903 } 904 905 /** 906 * Returns all the user group group roles. 907 * 908 * @return the user group group roles 909 */ 910 public static List<UserGroupGroupRole> findAll() { 911 return getPersistence().findAll(); 912 } 913 914 /** 915 * Returns a range of all the user group group roles. 916 * 917 * <p> 918 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link UserGroupGroupRoleModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order. 919 * </p> 920 * 921 * @param start the lower bound of the range of user group group roles 922 * @param end the upper bound of the range of user group group roles (not inclusive) 923 * @return the range of user group group roles 924 */ 925 public static List<UserGroupGroupRole> findAll(int start, int end) { 926 return getPersistence().findAll(start, end); 927 } 928 929 /** 930 * Returns an ordered range of all the user group group roles. 931 * 932 * <p> 933 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link QueryUtil#ALL_POS} will return the full result set. If <code>orderByComparator</code> is specified, then the query will include the given ORDER BY logic. If <code>orderByComparator</code> is absent and pagination is required (<code>start</code> and <code>end</code> are not {@link QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link UserGroupGroupRoleModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order. 934 * </p> 935 * 936 * @param start the lower bound of the range of user group group roles 937 * @param end the upper bound of the range of user group group roles (not inclusive) 938 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 939 * @return the ordered range of user group group roles 940 */ 941 public static List<UserGroupGroupRole> findAll(int start, int end, 942 OrderByComparator<UserGroupGroupRole> orderByComparator) { 943 return getPersistence().findAll(start, end, orderByComparator); 944 } 945 946 /** 947 * Removes all the user group group roles from the database. 948 */ 949 public static void removeAll() { 950 getPersistence().removeAll(); 951 } 952 953 /** 954 * Returns the number of user group group roles. 955 * 956 * @return the number of user group group roles 957 */ 958 public static int countAll() { 959 return getPersistence().countAll(); 960 } 961 962 public static UserGroupGroupRolePersistence getPersistence() { 963 if (_persistence == null) { 964 _persistence = (UserGroupGroupRolePersistence)PortalBeanLocatorUtil.locate(UserGroupGroupRolePersistence.class.getName()); 965 966 ReferenceRegistry.registerReference(UserGroupGroupRoleUtil.class, 967 "_persistence"); 968 } 969 970 return _persistence; 971 } 972 973 /** 974 * @deprecated As of 6.2.0 975 */ 976 @Deprecated 977 public void setPersistence(UserGroupGroupRolePersistence persistence) { 978 } 979 980 private static UserGroupGroupRolePersistence _persistence; 981 }