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 com.liferay.portal.model.OrgGroupPermission; 018 019 /** 020 * The persistence interface for the org group permission service. 021 * 022 * <p> 023 * Caching information and settings can be found in <code>portal.properties</code> 024 * </p> 025 * 026 * @author Brian Wing Shun Chan 027 * @see OrgGroupPermissionPersistenceImpl 028 * @see OrgGroupPermissionUtil 029 * @generated 030 */ 031 public interface OrgGroupPermissionPersistence extends BasePersistence<OrgGroupPermission> { 032 /* 033 * NOTE FOR DEVELOPERS: 034 * 035 * Never modify or reference this interface directly. Always use {@link OrgGroupPermissionUtil} to access the org group permission persistence. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this interface. 036 */ 037 038 /** 039 * Caches the org group permission in the entity cache if it is enabled. 040 * 041 * @param orgGroupPermission the org group permission 042 */ 043 public void cacheResult( 044 com.liferay.portal.model.OrgGroupPermission orgGroupPermission); 045 046 /** 047 * Caches the org group permissions in the entity cache if it is enabled. 048 * 049 * @param orgGroupPermissions the org group permissions 050 */ 051 public void cacheResult( 052 java.util.List<com.liferay.portal.model.OrgGroupPermission> orgGroupPermissions); 053 054 /** 055 * Creates a new org group permission with the primary key. Does not add the org group permission to the database. 056 * 057 * @param orgGroupPermissionPK the primary key for the new org group permission 058 * @return the new org group permission 059 */ 060 public com.liferay.portal.model.OrgGroupPermission create( 061 com.liferay.portal.service.persistence.OrgGroupPermissionPK orgGroupPermissionPK); 062 063 /** 064 * Removes the org group permission with the primary key from the database. Also notifies the appropriate model listeners. 065 * 066 * @param orgGroupPermissionPK the primary key of the org group permission 067 * @return the org group permission that was removed 068 * @throws com.liferay.portal.NoSuchOrgGroupPermissionException if a org group permission with the primary key could not be found 069 * @throws SystemException if a system exception occurred 070 */ 071 public com.liferay.portal.model.OrgGroupPermission remove( 072 com.liferay.portal.service.persistence.OrgGroupPermissionPK orgGroupPermissionPK) 073 throws com.liferay.portal.NoSuchOrgGroupPermissionException, 074 com.liferay.portal.kernel.exception.SystemException; 075 076 public com.liferay.portal.model.OrgGroupPermission updateImpl( 077 com.liferay.portal.model.OrgGroupPermission orgGroupPermission, 078 boolean merge) 079 throws com.liferay.portal.kernel.exception.SystemException; 080 081 /** 082 * Returns the org group permission with the primary key or throws a {@link com.liferay.portal.NoSuchOrgGroupPermissionException} if it could not be found. 083 * 084 * @param orgGroupPermissionPK the primary key of the org group permission 085 * @return the org group permission 086 * @throws com.liferay.portal.NoSuchOrgGroupPermissionException if a org group permission with the primary key could not be found 087 * @throws SystemException if a system exception occurred 088 */ 089 public com.liferay.portal.model.OrgGroupPermission findByPrimaryKey( 090 com.liferay.portal.service.persistence.OrgGroupPermissionPK orgGroupPermissionPK) 091 throws com.liferay.portal.NoSuchOrgGroupPermissionException, 092 com.liferay.portal.kernel.exception.SystemException; 093 094 /** 095 * Returns the org group permission with the primary key or returns <code>null</code> if it could not be found. 096 * 097 * @param orgGroupPermissionPK the primary key of the org group permission 098 * @return the org group permission, or <code>null</code> if a org group permission with the primary key could not be found 099 * @throws SystemException if a system exception occurred 100 */ 101 public com.liferay.portal.model.OrgGroupPermission fetchByPrimaryKey( 102 com.liferay.portal.service.persistence.OrgGroupPermissionPK orgGroupPermissionPK) 103 throws com.liferay.portal.kernel.exception.SystemException; 104 105 /** 106 * Returns all the org group permissions where groupId = ?. 107 * 108 * @param groupId the group ID 109 * @return the matching org group permissions 110 * @throws SystemException if a system exception occurred 111 */ 112 public java.util.List<com.liferay.portal.model.OrgGroupPermission> findByGroupId( 113 long groupId) 114 throws com.liferay.portal.kernel.exception.SystemException; 115 116 /** 117 * Returns a range of all the org group permissions where groupId = ?. 118 * 119 * <p> 120 * 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. 121 * </p> 122 * 123 * @param groupId the group ID 124 * @param start the lower bound of the range of org group permissions 125 * @param end the upper bound of the range of org group permissions (not inclusive) 126 * @return the range of matching org group permissions 127 * @throws SystemException if a system exception occurred 128 */ 129 public java.util.List<com.liferay.portal.model.OrgGroupPermission> findByGroupId( 130 long groupId, int start, int end) 131 throws com.liferay.portal.kernel.exception.SystemException; 132 133 /** 134 * Returns an ordered range of all the org group permissions where groupId = ?. 135 * 136 * <p> 137 * 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. 138 * </p> 139 * 140 * @param groupId the group ID 141 * @param start the lower bound of the range of org group permissions 142 * @param end the upper bound of the range of org group permissions (not inclusive) 143 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 144 * @return the ordered range of matching org group permissions 145 * @throws SystemException if a system exception occurred 146 */ 147 public java.util.List<com.liferay.portal.model.OrgGroupPermission> findByGroupId( 148 long groupId, int start, int end, 149 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 150 throws com.liferay.portal.kernel.exception.SystemException; 151 152 /** 153 * Returns the first org group permission in the ordered set where groupId = ?. 154 * 155 * @param groupId the group ID 156 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 157 * @return the first matching org group permission 158 * @throws com.liferay.portal.NoSuchOrgGroupPermissionException if a matching org group permission could not be found 159 * @throws SystemException if a system exception occurred 160 */ 161 public com.liferay.portal.model.OrgGroupPermission findByGroupId_First( 162 long groupId, 163 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 164 throws com.liferay.portal.NoSuchOrgGroupPermissionException, 165 com.liferay.portal.kernel.exception.SystemException; 166 167 /** 168 * Returns the first org group permission in the ordered set where groupId = ?. 169 * 170 * @param groupId the group ID 171 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 172 * @return the first matching org group permission, or <code>null</code> if a matching org group permission could not be found 173 * @throws SystemException if a system exception occurred 174 */ 175 public com.liferay.portal.model.OrgGroupPermission fetchByGroupId_First( 176 long groupId, 177 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 178 throws com.liferay.portal.kernel.exception.SystemException; 179 180 /** 181 * Returns the last org group permission in the ordered set where groupId = ?. 182 * 183 * @param groupId the group ID 184 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 185 * @return the last matching org group permission 186 * @throws com.liferay.portal.NoSuchOrgGroupPermissionException if a matching org group permission could not be found 187 * @throws SystemException if a system exception occurred 188 */ 189 public com.liferay.portal.model.OrgGroupPermission findByGroupId_Last( 190 long groupId, 191 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 192 throws com.liferay.portal.NoSuchOrgGroupPermissionException, 193 com.liferay.portal.kernel.exception.SystemException; 194 195 /** 196 * Returns the last org group permission in the ordered set where groupId = ?. 197 * 198 * @param groupId the group ID 199 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 200 * @return the last matching org group permission, or <code>null</code> if a matching org group permission could not be found 201 * @throws SystemException if a system exception occurred 202 */ 203 public com.liferay.portal.model.OrgGroupPermission fetchByGroupId_Last( 204 long groupId, 205 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 206 throws com.liferay.portal.kernel.exception.SystemException; 207 208 /** 209 * Returns the org group permissions before and after the current org group permission in the ordered set where groupId = ?. 210 * 211 * @param orgGroupPermissionPK the primary key of the current org group permission 212 * @param groupId the group ID 213 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 214 * @return the previous, current, and next org group permission 215 * @throws com.liferay.portal.NoSuchOrgGroupPermissionException if a org group permission with the primary key could not be found 216 * @throws SystemException if a system exception occurred 217 */ 218 public com.liferay.portal.model.OrgGroupPermission[] findByGroupId_PrevAndNext( 219 com.liferay.portal.service.persistence.OrgGroupPermissionPK orgGroupPermissionPK, 220 long groupId, 221 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 222 throws com.liferay.portal.NoSuchOrgGroupPermissionException, 223 com.liferay.portal.kernel.exception.SystemException; 224 225 /** 226 * Returns all the org group permissions where permissionId = ?. 227 * 228 * @param permissionId the permission ID 229 * @return the matching org group permissions 230 * @throws SystemException if a system exception occurred 231 */ 232 public java.util.List<com.liferay.portal.model.OrgGroupPermission> findByPermissionId( 233 long permissionId) 234 throws com.liferay.portal.kernel.exception.SystemException; 235 236 /** 237 * Returns a range of all the org group permissions where permissionId = ?. 238 * 239 * <p> 240 * 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. 241 * </p> 242 * 243 * @param permissionId the permission ID 244 * @param start the lower bound of the range of org group permissions 245 * @param end the upper bound of the range of org group permissions (not inclusive) 246 * @return the range of matching org group permissions 247 * @throws SystemException if a system exception occurred 248 */ 249 public java.util.List<com.liferay.portal.model.OrgGroupPermission> findByPermissionId( 250 long permissionId, int start, int end) 251 throws com.liferay.portal.kernel.exception.SystemException; 252 253 /** 254 * Returns an ordered range of all the org group permissions where permissionId = ?. 255 * 256 * <p> 257 * 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. 258 * </p> 259 * 260 * @param permissionId the permission ID 261 * @param start the lower bound of the range of org group permissions 262 * @param end the upper bound of the range of org group permissions (not inclusive) 263 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 264 * @return the ordered range of matching org group permissions 265 * @throws SystemException if a system exception occurred 266 */ 267 public java.util.List<com.liferay.portal.model.OrgGroupPermission> findByPermissionId( 268 long permissionId, int start, int end, 269 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 270 throws com.liferay.portal.kernel.exception.SystemException; 271 272 /** 273 * Returns the first org group permission in the ordered set where permissionId = ?. 274 * 275 * @param permissionId the permission ID 276 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 277 * @return the first matching org group permission 278 * @throws com.liferay.portal.NoSuchOrgGroupPermissionException if a matching org group permission could not be found 279 * @throws SystemException if a system exception occurred 280 */ 281 public com.liferay.portal.model.OrgGroupPermission findByPermissionId_First( 282 long permissionId, 283 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 284 throws com.liferay.portal.NoSuchOrgGroupPermissionException, 285 com.liferay.portal.kernel.exception.SystemException; 286 287 /** 288 * Returns the first org group permission in the ordered set where permissionId = ?. 289 * 290 * @param permissionId the permission ID 291 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 292 * @return the first matching org group permission, or <code>null</code> if a matching org group permission could not be found 293 * @throws SystemException if a system exception occurred 294 */ 295 public com.liferay.portal.model.OrgGroupPermission fetchByPermissionId_First( 296 long permissionId, 297 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 298 throws com.liferay.portal.kernel.exception.SystemException; 299 300 /** 301 * Returns the last org group permission in the ordered set where permissionId = ?. 302 * 303 * @param permissionId the permission ID 304 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 305 * @return the last matching org group permission 306 * @throws com.liferay.portal.NoSuchOrgGroupPermissionException if a matching org group permission could not be found 307 * @throws SystemException if a system exception occurred 308 */ 309 public com.liferay.portal.model.OrgGroupPermission findByPermissionId_Last( 310 long permissionId, 311 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 312 throws com.liferay.portal.NoSuchOrgGroupPermissionException, 313 com.liferay.portal.kernel.exception.SystemException; 314 315 /** 316 * Returns the last org group permission in the ordered set where permissionId = ?. 317 * 318 * @param permissionId the permission ID 319 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 320 * @return the last matching org group permission, or <code>null</code> if a matching org group permission could not be found 321 * @throws SystemException if a system exception occurred 322 */ 323 public com.liferay.portal.model.OrgGroupPermission fetchByPermissionId_Last( 324 long permissionId, 325 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 326 throws com.liferay.portal.kernel.exception.SystemException; 327 328 /** 329 * Returns the org group permissions before and after the current org group permission in the ordered set where permissionId = ?. 330 * 331 * @param orgGroupPermissionPK the primary key of the current org group permission 332 * @param permissionId the permission ID 333 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 334 * @return the previous, current, and next org group permission 335 * @throws com.liferay.portal.NoSuchOrgGroupPermissionException if a org group permission with the primary key could not be found 336 * @throws SystemException if a system exception occurred 337 */ 338 public com.liferay.portal.model.OrgGroupPermission[] findByPermissionId_PrevAndNext( 339 com.liferay.portal.service.persistence.OrgGroupPermissionPK orgGroupPermissionPK, 340 long permissionId, 341 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 342 throws com.liferay.portal.NoSuchOrgGroupPermissionException, 343 com.liferay.portal.kernel.exception.SystemException; 344 345 /** 346 * Returns all the org group permissions. 347 * 348 * @return the org group permissions 349 * @throws SystemException if a system exception occurred 350 */ 351 public java.util.List<com.liferay.portal.model.OrgGroupPermission> findAll() 352 throws com.liferay.portal.kernel.exception.SystemException; 353 354 /** 355 * Returns a range of all the org group permissions. 356 * 357 * <p> 358 * 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. 359 * </p> 360 * 361 * @param start the lower bound of the range of org group permissions 362 * @param end the upper bound of the range of org group permissions (not inclusive) 363 * @return the range of org group permissions 364 * @throws SystemException if a system exception occurred 365 */ 366 public java.util.List<com.liferay.portal.model.OrgGroupPermission> findAll( 367 int start, int end) 368 throws com.liferay.portal.kernel.exception.SystemException; 369 370 /** 371 * Returns an ordered range of all the org group permissions. 372 * 373 * <p> 374 * 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. 375 * </p> 376 * 377 * @param start the lower bound of the range of org group permissions 378 * @param end the upper bound of the range of org group permissions (not inclusive) 379 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 380 * @return the ordered range of org group permissions 381 * @throws SystemException if a system exception occurred 382 */ 383 public java.util.List<com.liferay.portal.model.OrgGroupPermission> findAll( 384 int start, int end, 385 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 386 throws com.liferay.portal.kernel.exception.SystemException; 387 388 /** 389 * Removes all the org group permissions where groupId = ? from the database. 390 * 391 * @param groupId the group ID 392 * @throws SystemException if a system exception occurred 393 */ 394 public void removeByGroupId(long groupId) 395 throws com.liferay.portal.kernel.exception.SystemException; 396 397 /** 398 * Removes all the org group permissions where permissionId = ? from the database. 399 * 400 * @param permissionId the permission ID 401 * @throws SystemException if a system exception occurred 402 */ 403 public void removeByPermissionId(long permissionId) 404 throws com.liferay.portal.kernel.exception.SystemException; 405 406 /** 407 * Removes all the org group permissions from the database. 408 * 409 * @throws SystemException if a system exception occurred 410 */ 411 public void removeAll() 412 throws com.liferay.portal.kernel.exception.SystemException; 413 414 /** 415 * Returns the number of org group permissions where groupId = ?. 416 * 417 * @param groupId the group ID 418 * @return the number of matching org group permissions 419 * @throws SystemException if a system exception occurred 420 */ 421 public int countByGroupId(long groupId) 422 throws com.liferay.portal.kernel.exception.SystemException; 423 424 /** 425 * Returns the number of org group permissions where permissionId = ?. 426 * 427 * @param permissionId the permission ID 428 * @return the number of matching org group permissions 429 * @throws SystemException if a system exception occurred 430 */ 431 public int countByPermissionId(long permissionId) 432 throws com.liferay.portal.kernel.exception.SystemException; 433 434 /** 435 * Returns the number of org group permissions. 436 * 437 * @return the number of org group permissions 438 * @throws SystemException if a system exception occurred 439 */ 440 public int countAll() 441 throws com.liferay.portal.kernel.exception.SystemException; 442 }