001 /** 002 * Copyright (c) 2000-2012 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 com.liferay.portal.model.UserGroupRole; 018 019 /** 020 * The persistence interface for the user group role service. 021 * 022 * <p> 023 * Caching information and settings can be found in <code>portal.properties</code> 024 * </p> 025 * 026 * @author Brian Wing Shun Chan 027 * @see UserGroupRolePersistenceImpl 028 * @see UserGroupRoleUtil 029 * @generated 030 */ 031 public interface UserGroupRolePersistence extends BasePersistence<UserGroupRole> { 032 /* 033 * NOTE FOR DEVELOPERS: 034 * 035 * Never modify or reference this interface directly. Always use {@link UserGroupRoleUtil} to access the user group role persistence. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this interface. 036 */ 037 038 /** 039 * Caches the user group role in the entity cache if it is enabled. 040 * 041 * @param userGroupRole the user group role 042 */ 043 public void cacheResult( 044 com.liferay.portal.model.UserGroupRole userGroupRole); 045 046 /** 047 * Caches the user group roles in the entity cache if it is enabled. 048 * 049 * @param userGroupRoles the user group roles 050 */ 051 public void cacheResult( 052 java.util.List<com.liferay.portal.model.UserGroupRole> userGroupRoles); 053 054 /** 055 * Creates a new user group role with the primary key. Does not add the user group role to the database. 056 * 057 * @param userGroupRolePK the primary key for the new user group role 058 * @return the new user group role 059 */ 060 public com.liferay.portal.model.UserGroupRole create( 061 com.liferay.portal.service.persistence.UserGroupRolePK userGroupRolePK); 062 063 /** 064 * Removes the user group role with the primary key from the database. Also notifies the appropriate model listeners. 065 * 066 * @param userGroupRolePK the primary key of the user group role 067 * @return the user group role that was removed 068 * @throws com.liferay.portal.NoSuchUserGroupRoleException if a user group role with the primary key could not be found 069 * @throws SystemException if a system exception occurred 070 */ 071 public com.liferay.portal.model.UserGroupRole remove( 072 com.liferay.portal.service.persistence.UserGroupRolePK userGroupRolePK) 073 throws com.liferay.portal.NoSuchUserGroupRoleException, 074 com.liferay.portal.kernel.exception.SystemException; 075 076 public com.liferay.portal.model.UserGroupRole updateImpl( 077 com.liferay.portal.model.UserGroupRole userGroupRole, boolean merge) 078 throws com.liferay.portal.kernel.exception.SystemException; 079 080 /** 081 * Returns the user group role with the primary key or throws a {@link com.liferay.portal.NoSuchUserGroupRoleException} if it could not be found. 082 * 083 * @param userGroupRolePK the primary key of the user group role 084 * @return the user group role 085 * @throws com.liferay.portal.NoSuchUserGroupRoleException if a user group role with the primary key could not be found 086 * @throws SystemException if a system exception occurred 087 */ 088 public com.liferay.portal.model.UserGroupRole findByPrimaryKey( 089 com.liferay.portal.service.persistence.UserGroupRolePK userGroupRolePK) 090 throws com.liferay.portal.NoSuchUserGroupRoleException, 091 com.liferay.portal.kernel.exception.SystemException; 092 093 /** 094 * Returns the user group role with the primary key or returns <code>null</code> if it could not be found. 095 * 096 * @param userGroupRolePK the primary key of the user group role 097 * @return the user group role, or <code>null</code> if a user group role with the primary key could not be found 098 * @throws SystemException if a system exception occurred 099 */ 100 public com.liferay.portal.model.UserGroupRole fetchByPrimaryKey( 101 com.liferay.portal.service.persistence.UserGroupRolePK userGroupRolePK) 102 throws com.liferay.portal.kernel.exception.SystemException; 103 104 /** 105 * Returns all the user group roles where userId = ?. 106 * 107 * @param userId the user ID 108 * @return the matching user group roles 109 * @throws SystemException if a system exception occurred 110 */ 111 public java.util.List<com.liferay.portal.model.UserGroupRole> findByUserId( 112 long userId) throws com.liferay.portal.kernel.exception.SystemException; 113 114 /** 115 * Returns a range of all the user group roles where userId = ?. 116 * 117 * <p> 118 * 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. 119 * </p> 120 * 121 * @param userId the user ID 122 * @param start the lower bound of the range of user group roles 123 * @param end the upper bound of the range of user group roles (not inclusive) 124 * @return the range of matching user group roles 125 * @throws SystemException if a system exception occurred 126 */ 127 public java.util.List<com.liferay.portal.model.UserGroupRole> findByUserId( 128 long userId, int start, int end) 129 throws com.liferay.portal.kernel.exception.SystemException; 130 131 /** 132 * Returns an ordered range of all the user group roles where userId = ?. 133 * 134 * <p> 135 * 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. 136 * </p> 137 * 138 * @param userId the user ID 139 * @param start the lower bound of the range of user group roles 140 * @param end the upper bound of the range of user group roles (not inclusive) 141 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 142 * @return the ordered range of matching user group roles 143 * @throws SystemException if a system exception occurred 144 */ 145 public java.util.List<com.liferay.portal.model.UserGroupRole> findByUserId( 146 long userId, int start, int end, 147 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 148 throws com.liferay.portal.kernel.exception.SystemException; 149 150 /** 151 * Returns the first user group role in the ordered set where userId = ?. 152 * 153 * <p> 154 * 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. 155 * </p> 156 * 157 * @param userId the user ID 158 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 159 * @return the first matching user group role 160 * @throws com.liferay.portal.NoSuchUserGroupRoleException if a matching user group role could not be found 161 * @throws SystemException if a system exception occurred 162 */ 163 public com.liferay.portal.model.UserGroupRole findByUserId_First( 164 long userId, 165 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 166 throws com.liferay.portal.NoSuchUserGroupRoleException, 167 com.liferay.portal.kernel.exception.SystemException; 168 169 /** 170 * Returns the last user group role in the ordered set where userId = ?. 171 * 172 * <p> 173 * 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. 174 * </p> 175 * 176 * @param userId the user ID 177 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 178 * @return the last matching user group role 179 * @throws com.liferay.portal.NoSuchUserGroupRoleException if a matching user group role could not be found 180 * @throws SystemException if a system exception occurred 181 */ 182 public com.liferay.portal.model.UserGroupRole findByUserId_Last( 183 long userId, 184 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 185 throws com.liferay.portal.NoSuchUserGroupRoleException, 186 com.liferay.portal.kernel.exception.SystemException; 187 188 /** 189 * Returns the user group roles before and after the current user group role in the ordered set where userId = ?. 190 * 191 * <p> 192 * 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. 193 * </p> 194 * 195 * @param userGroupRolePK the primary key of the current user group role 196 * @param userId the user ID 197 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 198 * @return the previous, current, and next user group role 199 * @throws com.liferay.portal.NoSuchUserGroupRoleException if a user group role with the primary key could not be found 200 * @throws SystemException if a system exception occurred 201 */ 202 public com.liferay.portal.model.UserGroupRole[] findByUserId_PrevAndNext( 203 com.liferay.portal.service.persistence.UserGroupRolePK userGroupRolePK, 204 long userId, 205 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 206 throws com.liferay.portal.NoSuchUserGroupRoleException, 207 com.liferay.portal.kernel.exception.SystemException; 208 209 /** 210 * Returns all the user group roles where groupId = ?. 211 * 212 * @param groupId the group ID 213 * @return the matching user group roles 214 * @throws SystemException if a system exception occurred 215 */ 216 public java.util.List<com.liferay.portal.model.UserGroupRole> findByGroupId( 217 long groupId) 218 throws com.liferay.portal.kernel.exception.SystemException; 219 220 /** 221 * Returns a range of all the user group roles where groupId = ?. 222 * 223 * <p> 224 * 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. 225 * </p> 226 * 227 * @param groupId the group ID 228 * @param start the lower bound of the range of user group roles 229 * @param end the upper bound of the range of user group roles (not inclusive) 230 * @return the range of matching user group roles 231 * @throws SystemException if a system exception occurred 232 */ 233 public java.util.List<com.liferay.portal.model.UserGroupRole> findByGroupId( 234 long groupId, int start, int end) 235 throws com.liferay.portal.kernel.exception.SystemException; 236 237 /** 238 * Returns an ordered range of all the user group roles where groupId = ?. 239 * 240 * <p> 241 * 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. 242 * </p> 243 * 244 * @param groupId the group ID 245 * @param start the lower bound of the range of user group roles 246 * @param end the upper bound of the range of user group roles (not inclusive) 247 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 248 * @return the ordered range of matching user group roles 249 * @throws SystemException if a system exception occurred 250 */ 251 public java.util.List<com.liferay.portal.model.UserGroupRole> findByGroupId( 252 long groupId, int start, int end, 253 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 254 throws com.liferay.portal.kernel.exception.SystemException; 255 256 /** 257 * Returns the first user group role in the ordered set where groupId = ?. 258 * 259 * <p> 260 * 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. 261 * </p> 262 * 263 * @param groupId the group ID 264 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 265 * @return the first matching user group role 266 * @throws com.liferay.portal.NoSuchUserGroupRoleException if a matching user group role could not be found 267 * @throws SystemException if a system exception occurred 268 */ 269 public com.liferay.portal.model.UserGroupRole findByGroupId_First( 270 long groupId, 271 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 272 throws com.liferay.portal.NoSuchUserGroupRoleException, 273 com.liferay.portal.kernel.exception.SystemException; 274 275 /** 276 * Returns the last user group role in the ordered set where groupId = ?. 277 * 278 * <p> 279 * 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. 280 * </p> 281 * 282 * @param groupId the group ID 283 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 284 * @return the last matching user group role 285 * @throws com.liferay.portal.NoSuchUserGroupRoleException if a matching user group role could not be found 286 * @throws SystemException if a system exception occurred 287 */ 288 public com.liferay.portal.model.UserGroupRole findByGroupId_Last( 289 long groupId, 290 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 291 throws com.liferay.portal.NoSuchUserGroupRoleException, 292 com.liferay.portal.kernel.exception.SystemException; 293 294 /** 295 * Returns the user group roles before and after the current user group role in the ordered set where groupId = ?. 296 * 297 * <p> 298 * 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. 299 * </p> 300 * 301 * @param userGroupRolePK the primary key of the current user group role 302 * @param groupId the group ID 303 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 304 * @return the previous, current, and next user group role 305 * @throws com.liferay.portal.NoSuchUserGroupRoleException if a user group role with the primary key could not be found 306 * @throws SystemException if a system exception occurred 307 */ 308 public com.liferay.portal.model.UserGroupRole[] findByGroupId_PrevAndNext( 309 com.liferay.portal.service.persistence.UserGroupRolePK userGroupRolePK, 310 long groupId, 311 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 312 throws com.liferay.portal.NoSuchUserGroupRoleException, 313 com.liferay.portal.kernel.exception.SystemException; 314 315 /** 316 * Returns all the user group roles where roleId = ?. 317 * 318 * @param roleId the role ID 319 * @return the matching user group roles 320 * @throws SystemException if a system exception occurred 321 */ 322 public java.util.List<com.liferay.portal.model.UserGroupRole> findByRoleId( 323 long roleId) throws com.liferay.portal.kernel.exception.SystemException; 324 325 /** 326 * Returns a range of all the user group roles where roleId = ?. 327 * 328 * <p> 329 * 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. 330 * </p> 331 * 332 * @param roleId the role ID 333 * @param start the lower bound of the range of user group roles 334 * @param end the upper bound of the range of user group roles (not inclusive) 335 * @return the range of matching user group roles 336 * @throws SystemException if a system exception occurred 337 */ 338 public java.util.List<com.liferay.portal.model.UserGroupRole> findByRoleId( 339 long roleId, int start, int end) 340 throws com.liferay.portal.kernel.exception.SystemException; 341 342 /** 343 * Returns an ordered range of all the user group roles where roleId = ?. 344 * 345 * <p> 346 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. 347 * </p> 348 * 349 * @param roleId the role ID 350 * @param start the lower bound of the range of user group roles 351 * @param end the upper bound of the range of user group roles (not inclusive) 352 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 353 * @return the ordered range of matching user group roles 354 * @throws SystemException if a system exception occurred 355 */ 356 public java.util.List<com.liferay.portal.model.UserGroupRole> findByRoleId( 357 long roleId, int start, int end, 358 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 359 throws com.liferay.portal.kernel.exception.SystemException; 360 361 /** 362 * Returns the first user group role in the ordered set where roleId = ?. 363 * 364 * <p> 365 * 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. 366 * </p> 367 * 368 * @param roleId the role ID 369 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 370 * @return the first matching user group role 371 * @throws com.liferay.portal.NoSuchUserGroupRoleException if a matching user group role could not be found 372 * @throws SystemException if a system exception occurred 373 */ 374 public com.liferay.portal.model.UserGroupRole findByRoleId_First( 375 long roleId, 376 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 377 throws com.liferay.portal.NoSuchUserGroupRoleException, 378 com.liferay.portal.kernel.exception.SystemException; 379 380 /** 381 * Returns the last user group role in the ordered set where roleId = ?. 382 * 383 * <p> 384 * 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. 385 * </p> 386 * 387 * @param roleId the role ID 388 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 389 * @return the last matching user group role 390 * @throws com.liferay.portal.NoSuchUserGroupRoleException if a matching user group role could not be found 391 * @throws SystemException if a system exception occurred 392 */ 393 public com.liferay.portal.model.UserGroupRole findByRoleId_Last( 394 long roleId, 395 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 396 throws com.liferay.portal.NoSuchUserGroupRoleException, 397 com.liferay.portal.kernel.exception.SystemException; 398 399 /** 400 * Returns the user group roles before and after the current user group role in the ordered set where roleId = ?. 401 * 402 * <p> 403 * 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. 404 * </p> 405 * 406 * @param userGroupRolePK the primary key of the current user group role 407 * @param roleId the role ID 408 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 409 * @return the previous, current, and next user group role 410 * @throws com.liferay.portal.NoSuchUserGroupRoleException if a user group role with the primary key could not be found 411 * @throws SystemException if a system exception occurred 412 */ 413 public com.liferay.portal.model.UserGroupRole[] findByRoleId_PrevAndNext( 414 com.liferay.portal.service.persistence.UserGroupRolePK userGroupRolePK, 415 long roleId, 416 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 417 throws com.liferay.portal.NoSuchUserGroupRoleException, 418 com.liferay.portal.kernel.exception.SystemException; 419 420 /** 421 * Returns all the user group roles where userId = ? and groupId = ?. 422 * 423 * @param userId the user ID 424 * @param groupId the group ID 425 * @return the matching user group roles 426 * @throws SystemException if a system exception occurred 427 */ 428 public java.util.List<com.liferay.portal.model.UserGroupRole> findByU_G( 429 long userId, long groupId) 430 throws com.liferay.portal.kernel.exception.SystemException; 431 432 /** 433 * Returns a range of all the user group roles where userId = ? and groupId = ?. 434 * 435 * <p> 436 * 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. 437 * </p> 438 * 439 * @param userId the user ID 440 * @param groupId the group ID 441 * @param start the lower bound of the range of user group roles 442 * @param end the upper bound of the range of user group roles (not inclusive) 443 * @return the range of matching user group roles 444 * @throws SystemException if a system exception occurred 445 */ 446 public java.util.List<com.liferay.portal.model.UserGroupRole> findByU_G( 447 long userId, long groupId, int start, int end) 448 throws com.liferay.portal.kernel.exception.SystemException; 449 450 /** 451 * Returns an ordered range of all the user group roles where userId = ? and groupId = ?. 452 * 453 * <p> 454 * 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. 455 * </p> 456 * 457 * @param userId the user ID 458 * @param groupId the group ID 459 * @param start the lower bound of the range of user group roles 460 * @param end the upper bound of the range of user group roles (not inclusive) 461 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 462 * @return the ordered range of matching user group roles 463 * @throws SystemException if a system exception occurred 464 */ 465 public java.util.List<com.liferay.portal.model.UserGroupRole> findByU_G( 466 long userId, long groupId, int start, int end, 467 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 468 throws com.liferay.portal.kernel.exception.SystemException; 469 470 /** 471 * Returns the first user group role in the ordered set where userId = ? and groupId = ?. 472 * 473 * <p> 474 * 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. 475 * </p> 476 * 477 * @param userId the user ID 478 * @param groupId the group ID 479 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 480 * @return the first matching user group role 481 * @throws com.liferay.portal.NoSuchUserGroupRoleException if a matching user group role could not be found 482 * @throws SystemException if a system exception occurred 483 */ 484 public com.liferay.portal.model.UserGroupRole findByU_G_First(long userId, 485 long groupId, 486 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 487 throws com.liferay.portal.NoSuchUserGroupRoleException, 488 com.liferay.portal.kernel.exception.SystemException; 489 490 /** 491 * Returns the last user group role in the ordered set where userId = ? and groupId = ?. 492 * 493 * <p> 494 * 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. 495 * </p> 496 * 497 * @param userId the user ID 498 * @param groupId the group ID 499 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 500 * @return the last matching user group role 501 * @throws com.liferay.portal.NoSuchUserGroupRoleException if a matching user group role could not be found 502 * @throws SystemException if a system exception occurred 503 */ 504 public com.liferay.portal.model.UserGroupRole findByU_G_Last(long userId, 505 long groupId, 506 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 507 throws com.liferay.portal.NoSuchUserGroupRoleException, 508 com.liferay.portal.kernel.exception.SystemException; 509 510 /** 511 * Returns the user group roles before and after the current user group role in the ordered set where userId = ? and groupId = ?. 512 * 513 * <p> 514 * 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. 515 * </p> 516 * 517 * @param userGroupRolePK the primary key of the current user group role 518 * @param userId the user ID 519 * @param groupId the group ID 520 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 521 * @return the previous, current, and next user group role 522 * @throws com.liferay.portal.NoSuchUserGroupRoleException if a user group role with the primary key could not be found 523 * @throws SystemException if a system exception occurred 524 */ 525 public com.liferay.portal.model.UserGroupRole[] findByU_G_PrevAndNext( 526 com.liferay.portal.service.persistence.UserGroupRolePK userGroupRolePK, 527 long userId, long groupId, 528 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 529 throws com.liferay.portal.NoSuchUserGroupRoleException, 530 com.liferay.portal.kernel.exception.SystemException; 531 532 /** 533 * Returns all the user group roles where groupId = ? and roleId = ?. 534 * 535 * @param groupId the group ID 536 * @param roleId the role ID 537 * @return the matching user group roles 538 * @throws SystemException if a system exception occurred 539 */ 540 public java.util.List<com.liferay.portal.model.UserGroupRole> findByG_R( 541 long groupId, long roleId) 542 throws com.liferay.portal.kernel.exception.SystemException; 543 544 /** 545 * Returns a range of all the user group roles where groupId = ? and roleId = ?. 546 * 547 * <p> 548 * 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. 549 * </p> 550 * 551 * @param groupId the group ID 552 * @param roleId the role ID 553 * @param start the lower bound of the range of user group roles 554 * @param end the upper bound of the range of user group roles (not inclusive) 555 * @return the range of matching user group roles 556 * @throws SystemException if a system exception occurred 557 */ 558 public java.util.List<com.liferay.portal.model.UserGroupRole> findByG_R( 559 long groupId, long roleId, int start, int end) 560 throws com.liferay.portal.kernel.exception.SystemException; 561 562 /** 563 * Returns an ordered range of all the user group roles where groupId = ? and roleId = ?. 564 * 565 * <p> 566 * 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. 567 * </p> 568 * 569 * @param groupId the group ID 570 * @param roleId the role ID 571 * @param start the lower bound of the range of user group roles 572 * @param end the upper bound of the range of user group roles (not inclusive) 573 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 574 * @return the ordered range of matching user group roles 575 * @throws SystemException if a system exception occurred 576 */ 577 public java.util.List<com.liferay.portal.model.UserGroupRole> findByG_R( 578 long groupId, long roleId, int start, int end, 579 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 580 throws com.liferay.portal.kernel.exception.SystemException; 581 582 /** 583 * Returns the first user group role in the ordered set where groupId = ? and roleId = ?. 584 * 585 * <p> 586 * 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. 587 * </p> 588 * 589 * @param groupId the group ID 590 * @param roleId the role ID 591 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 592 * @return the first matching user group role 593 * @throws com.liferay.portal.NoSuchUserGroupRoleException if a matching user group role could not be found 594 * @throws SystemException if a system exception occurred 595 */ 596 public com.liferay.portal.model.UserGroupRole findByG_R_First( 597 long groupId, long roleId, 598 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 599 throws com.liferay.portal.NoSuchUserGroupRoleException, 600 com.liferay.portal.kernel.exception.SystemException; 601 602 /** 603 * Returns the last user group role in the ordered set where groupId = ? and roleId = ?. 604 * 605 * <p> 606 * 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. 607 * </p> 608 * 609 * @param groupId the group ID 610 * @param roleId the role ID 611 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 612 * @return the last matching user group role 613 * @throws com.liferay.portal.NoSuchUserGroupRoleException if a matching user group role could not be found 614 * @throws SystemException if a system exception occurred 615 */ 616 public com.liferay.portal.model.UserGroupRole findByG_R_Last(long groupId, 617 long roleId, 618 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 619 throws com.liferay.portal.NoSuchUserGroupRoleException, 620 com.liferay.portal.kernel.exception.SystemException; 621 622 /** 623 * Returns the user group roles before and after the current user group role in the ordered set where groupId = ? and roleId = ?. 624 * 625 * <p> 626 * 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. 627 * </p> 628 * 629 * @param userGroupRolePK the primary key of the current user group role 630 * @param groupId the group ID 631 * @param roleId the role ID 632 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 633 * @return the previous, current, and next user group role 634 * @throws com.liferay.portal.NoSuchUserGroupRoleException if a user group role with the primary key could not be found 635 * @throws SystemException if a system exception occurred 636 */ 637 public com.liferay.portal.model.UserGroupRole[] findByG_R_PrevAndNext( 638 com.liferay.portal.service.persistence.UserGroupRolePK userGroupRolePK, 639 long groupId, long roleId, 640 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 641 throws com.liferay.portal.NoSuchUserGroupRoleException, 642 com.liferay.portal.kernel.exception.SystemException; 643 644 /** 645 * Returns all the user group roles. 646 * 647 * @return the user group roles 648 * @throws SystemException if a system exception occurred 649 */ 650 public java.util.List<com.liferay.portal.model.UserGroupRole> findAll() 651 throws com.liferay.portal.kernel.exception.SystemException; 652 653 /** 654 * Returns a range of all the user group roles. 655 * 656 * <p> 657 * 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. 658 * </p> 659 * 660 * @param start the lower bound of the range of user group roles 661 * @param end the upper bound of the range of user group roles (not inclusive) 662 * @return the range of user group roles 663 * @throws SystemException if a system exception occurred 664 */ 665 public java.util.List<com.liferay.portal.model.UserGroupRole> findAll( 666 int start, int end) 667 throws com.liferay.portal.kernel.exception.SystemException; 668 669 /** 670 * Returns an ordered range of all the user group roles. 671 * 672 * <p> 673 * 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. 674 * </p> 675 * 676 * @param start the lower bound of the range of user group roles 677 * @param end the upper bound of the range of user group roles (not inclusive) 678 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 679 * @return the ordered range of user group roles 680 * @throws SystemException if a system exception occurred 681 */ 682 public java.util.List<com.liferay.portal.model.UserGroupRole> findAll( 683 int start, int end, 684 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 685 throws com.liferay.portal.kernel.exception.SystemException; 686 687 /** 688 * Removes all the user group roles where userId = ? from the database. 689 * 690 * @param userId the user ID 691 * @throws SystemException if a system exception occurred 692 */ 693 public void removeByUserId(long userId) 694 throws com.liferay.portal.kernel.exception.SystemException; 695 696 /** 697 * Removes all the user group roles where groupId = ? from the database. 698 * 699 * @param groupId the group ID 700 * @throws SystemException if a system exception occurred 701 */ 702 public void removeByGroupId(long groupId) 703 throws com.liferay.portal.kernel.exception.SystemException; 704 705 /** 706 * Removes all the user group roles where roleId = ? from the database. 707 * 708 * @param roleId the role ID 709 * @throws SystemException if a system exception occurred 710 */ 711 public void removeByRoleId(long roleId) 712 throws com.liferay.portal.kernel.exception.SystemException; 713 714 /** 715 * Removes all the user group roles where userId = ? and groupId = ? from the database. 716 * 717 * @param userId the user ID 718 * @param groupId the group ID 719 * @throws SystemException if a system exception occurred 720 */ 721 public void removeByU_G(long userId, long groupId) 722 throws com.liferay.portal.kernel.exception.SystemException; 723 724 /** 725 * Removes all the user group roles where groupId = ? and roleId = ? from the database. 726 * 727 * @param groupId the group ID 728 * @param roleId the role ID 729 * @throws SystemException if a system exception occurred 730 */ 731 public void removeByG_R(long groupId, long roleId) 732 throws com.liferay.portal.kernel.exception.SystemException; 733 734 /** 735 * Removes all the user group roles from the database. 736 * 737 * @throws SystemException if a system exception occurred 738 */ 739 public void removeAll() 740 throws com.liferay.portal.kernel.exception.SystemException; 741 742 /** 743 * Returns the number of user group roles where userId = ?. 744 * 745 * @param userId the user ID 746 * @return the number of matching user group roles 747 * @throws SystemException if a system exception occurred 748 */ 749 public int countByUserId(long userId) 750 throws com.liferay.portal.kernel.exception.SystemException; 751 752 /** 753 * Returns the number of user group roles where groupId = ?. 754 * 755 * @param groupId the group ID 756 * @return the number of matching user group roles 757 * @throws SystemException if a system exception occurred 758 */ 759 public int countByGroupId(long groupId) 760 throws com.liferay.portal.kernel.exception.SystemException; 761 762 /** 763 * Returns the number of user group roles where roleId = ?. 764 * 765 * @param roleId the role ID 766 * @return the number of matching user group roles 767 * @throws SystemException if a system exception occurred 768 */ 769 public int countByRoleId(long roleId) 770 throws com.liferay.portal.kernel.exception.SystemException; 771 772 /** 773 * Returns the number of user group roles where userId = ? and groupId = ?. 774 * 775 * @param userId the user ID 776 * @param groupId the group ID 777 * @return the number of matching user group roles 778 * @throws SystemException if a system exception occurred 779 */ 780 public int countByU_G(long userId, long groupId) 781 throws com.liferay.portal.kernel.exception.SystemException; 782 783 /** 784 * Returns the number of user group roles where groupId = ? and roleId = ?. 785 * 786 * @param groupId the group ID 787 * @param roleId the role ID 788 * @return the number of matching user group roles 789 * @throws SystemException if a system exception occurred 790 */ 791 public int countByG_R(long groupId, long roleId) 792 throws com.liferay.portal.kernel.exception.SystemException; 793 794 /** 795 * Returns the number of user group roles. 796 * 797 * @return the number of user group roles 798 * @throws SystemException if a system exception occurred 799 */ 800 public int countAll() 801 throws com.liferay.portal.kernel.exception.SystemException; 802 }