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