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