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.LayoutSet; 018 019 /** 020 * The persistence interface for the layout set 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 LayoutSetPersistenceImpl 028 * @see LayoutSetUtil 029 * @generated 030 */ 031 public interface LayoutSetPersistence extends BasePersistence<LayoutSet> { 032 /* 033 * NOTE FOR DEVELOPERS: 034 * 035 * Never modify or reference this interface directly. Always use {@link LayoutSetUtil} to access the layout set persistence. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this interface. 036 */ 037 038 /** 039 * Caches the layout set in the entity cache if it is enabled. 040 * 041 * @param layoutSet the layout set 042 */ 043 public void cacheResult(com.liferay.portal.model.LayoutSet layoutSet); 044 045 /** 046 * Caches the layout sets in the entity cache if it is enabled. 047 * 048 * @param layoutSets the layout sets 049 */ 050 public void cacheResult( 051 java.util.List<com.liferay.portal.model.LayoutSet> layoutSets); 052 053 /** 054 * Creates a new layout set with the primary key. Does not add the layout set to the database. 055 * 056 * @param layoutSetId the primary key for the new layout set 057 * @return the new layout set 058 */ 059 public com.liferay.portal.model.LayoutSet create(long layoutSetId); 060 061 /** 062 * Removes the layout set with the primary key from the database. Also notifies the appropriate model listeners. 063 * 064 * @param layoutSetId the primary key of the layout set 065 * @return the layout set that was removed 066 * @throws com.liferay.portal.NoSuchLayoutSetException if a layout set with the primary key could not be found 067 * @throws SystemException if a system exception occurred 068 */ 069 public com.liferay.portal.model.LayoutSet remove(long layoutSetId) 070 throws com.liferay.portal.NoSuchLayoutSetException, 071 com.liferay.portal.kernel.exception.SystemException; 072 073 public com.liferay.portal.model.LayoutSet updateImpl( 074 com.liferay.portal.model.LayoutSet layoutSet, boolean merge) 075 throws com.liferay.portal.kernel.exception.SystemException; 076 077 /** 078 * Returns the layout set with the primary key or throws a {@link com.liferay.portal.NoSuchLayoutSetException} if it could not be found. 079 * 080 * @param layoutSetId the primary key of the layout set 081 * @return the layout set 082 * @throws com.liferay.portal.NoSuchLayoutSetException if a layout set with the primary key could not be found 083 * @throws SystemException if a system exception occurred 084 */ 085 public com.liferay.portal.model.LayoutSet findByPrimaryKey(long layoutSetId) 086 throws com.liferay.portal.NoSuchLayoutSetException, 087 com.liferay.portal.kernel.exception.SystemException; 088 089 /** 090 * Returns the layout set with the primary key or returns <code>null</code> if it could not be found. 091 * 092 * @param layoutSetId the primary key of the layout set 093 * @return the layout set, or <code>null</code> if a layout set with the primary key could not be found 094 * @throws SystemException if a system exception occurred 095 */ 096 public com.liferay.portal.model.LayoutSet fetchByPrimaryKey( 097 long layoutSetId) 098 throws com.liferay.portal.kernel.exception.SystemException; 099 100 /** 101 * Returns all the layout sets where groupId = ?. 102 * 103 * @param groupId the group ID 104 * @return the matching layout sets 105 * @throws SystemException if a system exception occurred 106 */ 107 public java.util.List<com.liferay.portal.model.LayoutSet> findByGroupId( 108 long groupId) 109 throws com.liferay.portal.kernel.exception.SystemException; 110 111 /** 112 * Returns a range of all the layout sets where groupId = ?. 113 * 114 * <p> 115 * 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. 116 * </p> 117 * 118 * @param groupId the group ID 119 * @param start the lower bound of the range of layout sets 120 * @param end the upper bound of the range of layout sets (not inclusive) 121 * @return the range of matching layout sets 122 * @throws SystemException if a system exception occurred 123 */ 124 public java.util.List<com.liferay.portal.model.LayoutSet> findByGroupId( 125 long groupId, int start, int end) 126 throws com.liferay.portal.kernel.exception.SystemException; 127 128 /** 129 * Returns an ordered range of all the layout sets where groupId = ?. 130 * 131 * <p> 132 * 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. 133 * </p> 134 * 135 * @param groupId the group ID 136 * @param start the lower bound of the range of layout sets 137 * @param end the upper bound of the range of layout sets (not inclusive) 138 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 139 * @return the ordered range of matching layout sets 140 * @throws SystemException if a system exception occurred 141 */ 142 public java.util.List<com.liferay.portal.model.LayoutSet> findByGroupId( 143 long groupId, int start, int end, 144 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 145 throws com.liferay.portal.kernel.exception.SystemException; 146 147 /** 148 * Returns the first layout set in the ordered set where groupId = ?. 149 * 150 * @param groupId the group ID 151 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 152 * @return the first matching layout set 153 * @throws com.liferay.portal.NoSuchLayoutSetException if a matching layout set could not be found 154 * @throws SystemException if a system exception occurred 155 */ 156 public com.liferay.portal.model.LayoutSet findByGroupId_First( 157 long groupId, 158 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 159 throws com.liferay.portal.NoSuchLayoutSetException, 160 com.liferay.portal.kernel.exception.SystemException; 161 162 /** 163 * Returns the first layout set in the ordered set where groupId = ?. 164 * 165 * @param groupId the group ID 166 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 167 * @return the first matching layout set, or <code>null</code> if a matching layout set could not be found 168 * @throws SystemException if a system exception occurred 169 */ 170 public com.liferay.portal.model.LayoutSet fetchByGroupId_First( 171 long groupId, 172 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 173 throws com.liferay.portal.kernel.exception.SystemException; 174 175 /** 176 * Returns the last layout set in the ordered set where groupId = ?. 177 * 178 * @param groupId the group ID 179 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 180 * @return the last matching layout set 181 * @throws com.liferay.portal.NoSuchLayoutSetException if a matching layout set could not be found 182 * @throws SystemException if a system exception occurred 183 */ 184 public com.liferay.portal.model.LayoutSet findByGroupId_Last(long groupId, 185 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 186 throws com.liferay.portal.NoSuchLayoutSetException, 187 com.liferay.portal.kernel.exception.SystemException; 188 189 /** 190 * Returns the last layout set in the ordered set where groupId = ?. 191 * 192 * @param groupId the group ID 193 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 194 * @return the last matching layout set, or <code>null</code> if a matching layout set could not be found 195 * @throws SystemException if a system exception occurred 196 */ 197 public com.liferay.portal.model.LayoutSet fetchByGroupId_Last( 198 long groupId, 199 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 200 throws com.liferay.portal.kernel.exception.SystemException; 201 202 /** 203 * Returns the layout sets before and after the current layout set in the ordered set where groupId = ?. 204 * 205 * @param layoutSetId the primary key of the current layout set 206 * @param groupId the group ID 207 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 208 * @return the previous, current, and next layout set 209 * @throws com.liferay.portal.NoSuchLayoutSetException if a layout set with the primary key could not be found 210 * @throws SystemException if a system exception occurred 211 */ 212 public com.liferay.portal.model.LayoutSet[] findByGroupId_PrevAndNext( 213 long layoutSetId, long groupId, 214 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 215 throws com.liferay.portal.NoSuchLayoutSetException, 216 com.liferay.portal.kernel.exception.SystemException; 217 218 /** 219 * Returns all the layout sets where layoutSetPrototypeUuid = ?. 220 * 221 * @param layoutSetPrototypeUuid the layout set prototype uuid 222 * @return the matching layout sets 223 * @throws SystemException if a system exception occurred 224 */ 225 public java.util.List<com.liferay.portal.model.LayoutSet> findByLayoutSetPrototypeUuid( 226 java.lang.String layoutSetPrototypeUuid) 227 throws com.liferay.portal.kernel.exception.SystemException; 228 229 /** 230 * Returns a range of all the layout sets where layoutSetPrototypeUuid = ?. 231 * 232 * <p> 233 * 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. 234 * </p> 235 * 236 * @param layoutSetPrototypeUuid the layout set prototype uuid 237 * @param start the lower bound of the range of layout sets 238 * @param end the upper bound of the range of layout sets (not inclusive) 239 * @return the range of matching layout sets 240 * @throws SystemException if a system exception occurred 241 */ 242 public java.util.List<com.liferay.portal.model.LayoutSet> findByLayoutSetPrototypeUuid( 243 java.lang.String layoutSetPrototypeUuid, int start, int end) 244 throws com.liferay.portal.kernel.exception.SystemException; 245 246 /** 247 * Returns an ordered range of all the layout sets where layoutSetPrototypeUuid = ?. 248 * 249 * <p> 250 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. 251 * </p> 252 * 253 * @param layoutSetPrototypeUuid the layout set prototype uuid 254 * @param start the lower bound of the range of layout sets 255 * @param end the upper bound of the range of layout sets (not inclusive) 256 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 257 * @return the ordered range of matching layout sets 258 * @throws SystemException if a system exception occurred 259 */ 260 public java.util.List<com.liferay.portal.model.LayoutSet> findByLayoutSetPrototypeUuid( 261 java.lang.String layoutSetPrototypeUuid, int start, int end, 262 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 263 throws com.liferay.portal.kernel.exception.SystemException; 264 265 /** 266 * Returns the first layout set in the ordered set where layoutSetPrototypeUuid = ?. 267 * 268 * @param layoutSetPrototypeUuid the layout set prototype uuid 269 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 270 * @return the first matching layout set 271 * @throws com.liferay.portal.NoSuchLayoutSetException if a matching layout set could not be found 272 * @throws SystemException if a system exception occurred 273 */ 274 public com.liferay.portal.model.LayoutSet findByLayoutSetPrototypeUuid_First( 275 java.lang.String layoutSetPrototypeUuid, 276 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 277 throws com.liferay.portal.NoSuchLayoutSetException, 278 com.liferay.portal.kernel.exception.SystemException; 279 280 /** 281 * Returns the first layout set in the ordered set where layoutSetPrototypeUuid = ?. 282 * 283 * @param layoutSetPrototypeUuid the layout set prototype uuid 284 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 285 * @return the first matching layout set, or <code>null</code> if a matching layout set could not be found 286 * @throws SystemException if a system exception occurred 287 */ 288 public com.liferay.portal.model.LayoutSet fetchByLayoutSetPrototypeUuid_First( 289 java.lang.String layoutSetPrototypeUuid, 290 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 291 throws com.liferay.portal.kernel.exception.SystemException; 292 293 /** 294 * Returns the last layout set in the ordered set where layoutSetPrototypeUuid = ?. 295 * 296 * @param layoutSetPrototypeUuid the layout set prototype uuid 297 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 298 * @return the last matching layout set 299 * @throws com.liferay.portal.NoSuchLayoutSetException if a matching layout set could not be found 300 * @throws SystemException if a system exception occurred 301 */ 302 public com.liferay.portal.model.LayoutSet findByLayoutSetPrototypeUuid_Last( 303 java.lang.String layoutSetPrototypeUuid, 304 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 305 throws com.liferay.portal.NoSuchLayoutSetException, 306 com.liferay.portal.kernel.exception.SystemException; 307 308 /** 309 * Returns the last layout set in the ordered set where layoutSetPrototypeUuid = ?. 310 * 311 * @param layoutSetPrototypeUuid the layout set prototype uuid 312 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 313 * @return the last matching layout set, or <code>null</code> if a matching layout set could not be found 314 * @throws SystemException if a system exception occurred 315 */ 316 public com.liferay.portal.model.LayoutSet fetchByLayoutSetPrototypeUuid_Last( 317 java.lang.String layoutSetPrototypeUuid, 318 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 319 throws com.liferay.portal.kernel.exception.SystemException; 320 321 /** 322 * Returns the layout sets before and after the current layout set in the ordered set where layoutSetPrototypeUuid = ?. 323 * 324 * @param layoutSetId the primary key of the current layout set 325 * @param layoutSetPrototypeUuid the layout set prototype uuid 326 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 327 * @return the previous, current, and next layout set 328 * @throws com.liferay.portal.NoSuchLayoutSetException if a layout set with the primary key could not be found 329 * @throws SystemException if a system exception occurred 330 */ 331 public com.liferay.portal.model.LayoutSet[] findByLayoutSetPrototypeUuid_PrevAndNext( 332 long layoutSetId, java.lang.String layoutSetPrototypeUuid, 333 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 334 throws com.liferay.portal.NoSuchLayoutSetException, 335 com.liferay.portal.kernel.exception.SystemException; 336 337 /** 338 * Returns the layout set where groupId = ? and privateLayout = ? or throws a {@link com.liferay.portal.NoSuchLayoutSetException} if it could not be found. 339 * 340 * @param groupId the group ID 341 * @param privateLayout the private layout 342 * @return the matching layout set 343 * @throws com.liferay.portal.NoSuchLayoutSetException if a matching layout set could not be found 344 * @throws SystemException if a system exception occurred 345 */ 346 public com.liferay.portal.model.LayoutSet findByG_P(long groupId, 347 boolean privateLayout) 348 throws com.liferay.portal.NoSuchLayoutSetException, 349 com.liferay.portal.kernel.exception.SystemException; 350 351 /** 352 * Returns the layout set where groupId = ? and privateLayout = ? or returns <code>null</code> if it could not be found. Uses the finder cache. 353 * 354 * @param groupId the group ID 355 * @param privateLayout the private layout 356 * @return the matching layout set, or <code>null</code> if a matching layout set could not be found 357 * @throws SystemException if a system exception occurred 358 */ 359 public com.liferay.portal.model.LayoutSet fetchByG_P(long groupId, 360 boolean privateLayout) 361 throws com.liferay.portal.kernel.exception.SystemException; 362 363 /** 364 * Returns the layout set where groupId = ? and privateLayout = ? or returns <code>null</code> if it could not be found, optionally using the finder cache. 365 * 366 * @param groupId the group ID 367 * @param privateLayout the private layout 368 * @param retrieveFromCache whether to use the finder cache 369 * @return the matching layout set, or <code>null</code> if a matching layout set could not be found 370 * @throws SystemException if a system exception occurred 371 */ 372 public com.liferay.portal.model.LayoutSet fetchByG_P(long groupId, 373 boolean privateLayout, boolean retrieveFromCache) 374 throws com.liferay.portal.kernel.exception.SystemException; 375 376 /** 377 * Returns all the layout sets. 378 * 379 * @return the layout sets 380 * @throws SystemException if a system exception occurred 381 */ 382 public java.util.List<com.liferay.portal.model.LayoutSet> findAll() 383 throws com.liferay.portal.kernel.exception.SystemException; 384 385 /** 386 * Returns a range of all the layout sets. 387 * 388 * <p> 389 * 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. 390 * </p> 391 * 392 * @param start the lower bound of the range of layout sets 393 * @param end the upper bound of the range of layout sets (not inclusive) 394 * @return the range of layout sets 395 * @throws SystemException if a system exception occurred 396 */ 397 public java.util.List<com.liferay.portal.model.LayoutSet> findAll( 398 int start, int end) 399 throws com.liferay.portal.kernel.exception.SystemException; 400 401 /** 402 * Returns an ordered range of all the layout sets. 403 * 404 * <p> 405 * 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. 406 * </p> 407 * 408 * @param start the lower bound of the range of layout sets 409 * @param end the upper bound of the range of layout sets (not inclusive) 410 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 411 * @return the ordered range of layout sets 412 * @throws SystemException if a system exception occurred 413 */ 414 public java.util.List<com.liferay.portal.model.LayoutSet> findAll( 415 int start, int end, 416 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 417 throws com.liferay.portal.kernel.exception.SystemException; 418 419 /** 420 * Removes all the layout sets where groupId = ? from the database. 421 * 422 * @param groupId the group ID 423 * @throws SystemException if a system exception occurred 424 */ 425 public void removeByGroupId(long groupId) 426 throws com.liferay.portal.kernel.exception.SystemException; 427 428 /** 429 * Removes all the layout sets where layoutSetPrototypeUuid = ? from the database. 430 * 431 * @param layoutSetPrototypeUuid the layout set prototype uuid 432 * @throws SystemException if a system exception occurred 433 */ 434 public void removeByLayoutSetPrototypeUuid( 435 java.lang.String layoutSetPrototypeUuid) 436 throws com.liferay.portal.kernel.exception.SystemException; 437 438 /** 439 * Removes the layout set where groupId = ? and privateLayout = ? from the database. 440 * 441 * @param groupId the group ID 442 * @param privateLayout the private layout 443 * @return the layout set that was removed 444 * @throws SystemException if a system exception occurred 445 */ 446 public com.liferay.portal.model.LayoutSet removeByG_P(long groupId, 447 boolean privateLayout) 448 throws com.liferay.portal.NoSuchLayoutSetException, 449 com.liferay.portal.kernel.exception.SystemException; 450 451 /** 452 * Removes all the layout sets from the database. 453 * 454 * @throws SystemException if a system exception occurred 455 */ 456 public void removeAll() 457 throws com.liferay.portal.kernel.exception.SystemException; 458 459 /** 460 * Returns the number of layout sets where groupId = ?. 461 * 462 * @param groupId the group ID 463 * @return the number of matching layout sets 464 * @throws SystemException if a system exception occurred 465 */ 466 public int countByGroupId(long groupId) 467 throws com.liferay.portal.kernel.exception.SystemException; 468 469 /** 470 * Returns the number of layout sets where layoutSetPrototypeUuid = ?. 471 * 472 * @param layoutSetPrototypeUuid the layout set prototype uuid 473 * @return the number of matching layout sets 474 * @throws SystemException if a system exception occurred 475 */ 476 public int countByLayoutSetPrototypeUuid( 477 java.lang.String layoutSetPrototypeUuid) 478 throws com.liferay.portal.kernel.exception.SystemException; 479 480 /** 481 * Returns the number of layout sets where groupId = ? and privateLayout = ?. 482 * 483 * @param groupId the group ID 484 * @param privateLayout the private layout 485 * @return the number of matching layout sets 486 * @throws SystemException if a system exception occurred 487 */ 488 public int countByG_P(long groupId, boolean privateLayout) 489 throws com.liferay.portal.kernel.exception.SystemException; 490 491 /** 492 * Returns the number of layout sets. 493 * 494 * @return the number of layout sets 495 * @throws SystemException if a system exception occurred 496 */ 497 public int countAll() 498 throws com.liferay.portal.kernel.exception.SystemException; 499 }