001 /** 002 * Copyright (c) 2000-present 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.mobiledevicerules.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.util.OrderByComparator; 022 import com.liferay.portal.kernel.util.ReferenceRegistry; 023 import com.liferay.portal.service.ServiceContext; 024 025 import com.liferay.portlet.mobiledevicerules.model.MDRAction; 026 027 import java.util.List; 028 029 /** 030 * The persistence utility for the m d r action service. This utility wraps {@link com.liferay.portlet.mobiledevicerules.service.persistence.impl.MDRActionPersistenceImpl} 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 Edward C. Han 037 * @see MDRActionPersistence 038 * @see com.liferay.portlet.mobiledevicerules.service.persistence.impl.MDRActionPersistenceImpl 039 * @generated 040 */ 041 @ProviderType 042 public class MDRActionUtil { 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(MDRAction mdrAction) { 060 getPersistence().clearCache(mdrAction); 061 } 062 063 /** 064 * @see com.liferay.portal.service.persistence.BasePersistence#countWithDynamicQuery(DynamicQuery) 065 */ 066 public static long countWithDynamicQuery(DynamicQuery dynamicQuery) { 067 return getPersistence().countWithDynamicQuery(dynamicQuery); 068 } 069 070 /** 071 * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery) 072 */ 073 public static List<MDRAction> findWithDynamicQuery( 074 DynamicQuery dynamicQuery) { 075 return getPersistence().findWithDynamicQuery(dynamicQuery); 076 } 077 078 /** 079 * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int) 080 */ 081 public static List<MDRAction> findWithDynamicQuery( 082 DynamicQuery dynamicQuery, int start, int end) { 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<MDRAction> findWithDynamicQuery( 090 DynamicQuery dynamicQuery, int start, int end, 091 OrderByComparator<MDRAction> orderByComparator) { 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) 099 */ 100 public static MDRAction update(MDRAction mdrAction) { 101 return getPersistence().update(mdrAction); 102 } 103 104 /** 105 * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, ServiceContext) 106 */ 107 public static MDRAction update(MDRAction mdrAction, 108 ServiceContext serviceContext) { 109 return getPersistence().update(mdrAction, serviceContext); 110 } 111 112 /** 113 * Returns all the m d r actions where uuid = ?. 114 * 115 * @param uuid the uuid 116 * @return the matching m d r actions 117 */ 118 public static List<MDRAction> findByUuid(java.lang.String uuid) { 119 return getPersistence().findByUuid(uuid); 120 } 121 122 /** 123 * Returns a range of all the m d r actions where uuid = ?. 124 * 125 * <p> 126 * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link MDRActionModelImpl}. 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. 127 * </p> 128 * 129 * @param uuid the uuid 130 * @param start the lower bound of the range of m d r actions 131 * @param end the upper bound of the range of m d r actions (not inclusive) 132 * @return the range of matching m d r actions 133 */ 134 public static List<MDRAction> findByUuid(java.lang.String uuid, int start, 135 int end) { 136 return getPersistence().findByUuid(uuid, start, end); 137 } 138 139 /** 140 * Returns an ordered range of all the m d r actions where uuid = ?. 141 * 142 * <p> 143 * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link MDRActionModelImpl}. 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. 144 * </p> 145 * 146 * @param uuid the uuid 147 * @param start the lower bound of the range of m d r actions 148 * @param end the upper bound of the range of m d r actions (not inclusive) 149 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 150 * @return the ordered range of matching m d r actions 151 */ 152 public static List<MDRAction> findByUuid(java.lang.String uuid, int start, 153 int end, OrderByComparator<MDRAction> orderByComparator) { 154 return getPersistence().findByUuid(uuid, start, end, orderByComparator); 155 } 156 157 /** 158 * Returns the first m d r action in the ordered set where uuid = ?. 159 * 160 * @param uuid the uuid 161 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 162 * @return the first matching m d r action 163 * @throws NoSuchActionException if a matching m d r action could not be found 164 */ 165 public static MDRAction findByUuid_First(java.lang.String uuid, 166 OrderByComparator<MDRAction> orderByComparator) 167 throws com.liferay.portlet.mobiledevicerules.NoSuchActionException { 168 return getPersistence().findByUuid_First(uuid, orderByComparator); 169 } 170 171 /** 172 * Returns the first m d r action in the ordered set where uuid = ?. 173 * 174 * @param uuid the uuid 175 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 176 * @return the first matching m d r action, or <code>null</code> if a matching m d r action could not be found 177 */ 178 public static MDRAction fetchByUuid_First(java.lang.String uuid, 179 OrderByComparator<MDRAction> orderByComparator) { 180 return getPersistence().fetchByUuid_First(uuid, orderByComparator); 181 } 182 183 /** 184 * Returns the last m d r action 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 last matching m d r action 189 * @throws NoSuchActionException if a matching m d r action could not be found 190 */ 191 public static MDRAction findByUuid_Last(java.lang.String uuid, 192 OrderByComparator<MDRAction> orderByComparator) 193 throws com.liferay.portlet.mobiledevicerules.NoSuchActionException { 194 return getPersistence().findByUuid_Last(uuid, orderByComparator); 195 } 196 197 /** 198 * Returns the last m d r action in the ordered set where uuid = ?. 199 * 200 * @param uuid the uuid 201 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 202 * @return the last matching m d r action, or <code>null</code> if a matching m d r action could not be found 203 */ 204 public static MDRAction fetchByUuid_Last(java.lang.String uuid, 205 OrderByComparator<MDRAction> orderByComparator) { 206 return getPersistence().fetchByUuid_Last(uuid, orderByComparator); 207 } 208 209 /** 210 * Returns the m d r actions before and after the current m d r action in the ordered set where uuid = ?. 211 * 212 * @param actionId the primary key of the current m d r action 213 * @param uuid the uuid 214 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 215 * @return the previous, current, and next m d r action 216 * @throws NoSuchActionException if a m d r action with the primary key could not be found 217 */ 218 public static MDRAction[] findByUuid_PrevAndNext(long actionId, 219 java.lang.String uuid, OrderByComparator<MDRAction> orderByComparator) 220 throws com.liferay.portlet.mobiledevicerules.NoSuchActionException { 221 return getPersistence() 222 .findByUuid_PrevAndNext(actionId, uuid, orderByComparator); 223 } 224 225 /** 226 * Removes all the m d r actions where uuid = ? from the database. 227 * 228 * @param uuid the uuid 229 */ 230 public static void removeByUuid(java.lang.String uuid) { 231 getPersistence().removeByUuid(uuid); 232 } 233 234 /** 235 * Returns the number of m d r actions where uuid = ?. 236 * 237 * @param uuid the uuid 238 * @return the number of matching m d r actions 239 */ 240 public static int countByUuid(java.lang.String uuid) { 241 return getPersistence().countByUuid(uuid); 242 } 243 244 /** 245 * Returns the m d r action where uuid = ? and groupId = ? or throws a {@link NoSuchActionException} if it could not be found. 246 * 247 * @param uuid the uuid 248 * @param groupId the group ID 249 * @return the matching m d r action 250 * @throws NoSuchActionException if a matching m d r action could not be found 251 */ 252 public static MDRAction findByUUID_G(java.lang.String uuid, long groupId) 253 throws com.liferay.portlet.mobiledevicerules.NoSuchActionException { 254 return getPersistence().findByUUID_G(uuid, groupId); 255 } 256 257 /** 258 * Returns the m d r action where uuid = ? and groupId = ? or returns <code>null</code> if it could not be found. Uses the finder cache. 259 * 260 * @param uuid the uuid 261 * @param groupId the group ID 262 * @return the matching m d r action, or <code>null</code> if a matching m d r action could not be found 263 */ 264 public static MDRAction fetchByUUID_G(java.lang.String uuid, long groupId) { 265 return getPersistence().fetchByUUID_G(uuid, groupId); 266 } 267 268 /** 269 * Returns the m d r action where uuid = ? and groupId = ? or returns <code>null</code> if it could not be found, optionally using the finder cache. 270 * 271 * @param uuid the uuid 272 * @param groupId the group ID 273 * @param retrieveFromCache whether to use the finder cache 274 * @return the matching m d r action, or <code>null</code> if a matching m d r action could not be found 275 */ 276 public static MDRAction fetchByUUID_G(java.lang.String uuid, long groupId, 277 boolean retrieveFromCache) { 278 return getPersistence().fetchByUUID_G(uuid, groupId, retrieveFromCache); 279 } 280 281 /** 282 * Removes the m d r action where uuid = ? and groupId = ? from the database. 283 * 284 * @param uuid the uuid 285 * @param groupId the group ID 286 * @return the m d r action that was removed 287 */ 288 public static MDRAction removeByUUID_G(java.lang.String uuid, long groupId) 289 throws com.liferay.portlet.mobiledevicerules.NoSuchActionException { 290 return getPersistence().removeByUUID_G(uuid, groupId); 291 } 292 293 /** 294 * Returns the number of m d r actions where uuid = ? and groupId = ?. 295 * 296 * @param uuid the uuid 297 * @param groupId the group ID 298 * @return the number of matching m d r actions 299 */ 300 public static int countByUUID_G(java.lang.String uuid, long groupId) { 301 return getPersistence().countByUUID_G(uuid, groupId); 302 } 303 304 /** 305 * Returns all the m d r actions where uuid = ? and companyId = ?. 306 * 307 * @param uuid the uuid 308 * @param companyId the company ID 309 * @return the matching m d r actions 310 */ 311 public static List<MDRAction> findByUuid_C(java.lang.String uuid, 312 long companyId) { 313 return getPersistence().findByUuid_C(uuid, companyId); 314 } 315 316 /** 317 * Returns a range of all the m d r actions where uuid = ? and companyId = ?. 318 * 319 * <p> 320 * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link MDRActionModelImpl}. 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. 321 * </p> 322 * 323 * @param uuid the uuid 324 * @param companyId the company ID 325 * @param start the lower bound of the range of m d r actions 326 * @param end the upper bound of the range of m d r actions (not inclusive) 327 * @return the range of matching m d r actions 328 */ 329 public static List<MDRAction> findByUuid_C(java.lang.String uuid, 330 long companyId, int start, int end) { 331 return getPersistence().findByUuid_C(uuid, companyId, start, end); 332 } 333 334 /** 335 * Returns an ordered range of all the m d r actions where uuid = ? and companyId = ?. 336 * 337 * <p> 338 * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link MDRActionModelImpl}. 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. 339 * </p> 340 * 341 * @param uuid the uuid 342 * @param companyId the company ID 343 * @param start the lower bound of the range of m d r actions 344 * @param end the upper bound of the range of m d r actions (not inclusive) 345 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 346 * @return the ordered range of matching m d r actions 347 */ 348 public static List<MDRAction> findByUuid_C(java.lang.String uuid, 349 long companyId, int start, int end, 350 OrderByComparator<MDRAction> orderByComparator) { 351 return getPersistence() 352 .findByUuid_C(uuid, companyId, start, end, orderByComparator); 353 } 354 355 /** 356 * Returns the first m d r action in the ordered set where uuid = ? and companyId = ?. 357 * 358 * @param uuid the uuid 359 * @param companyId the company ID 360 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 361 * @return the first matching m d r action 362 * @throws NoSuchActionException if a matching m d r action could not be found 363 */ 364 public static MDRAction findByUuid_C_First(java.lang.String uuid, 365 long companyId, OrderByComparator<MDRAction> orderByComparator) 366 throws com.liferay.portlet.mobiledevicerules.NoSuchActionException { 367 return getPersistence() 368 .findByUuid_C_First(uuid, companyId, orderByComparator); 369 } 370 371 /** 372 * Returns the first m d r action in the ordered set where uuid = ? and companyId = ?. 373 * 374 * @param uuid the uuid 375 * @param companyId the company ID 376 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 377 * @return the first matching m d r action, or <code>null</code> if a matching m d r action could not be found 378 */ 379 public static MDRAction fetchByUuid_C_First(java.lang.String uuid, 380 long companyId, OrderByComparator<MDRAction> orderByComparator) { 381 return getPersistence() 382 .fetchByUuid_C_First(uuid, companyId, orderByComparator); 383 } 384 385 /** 386 * Returns the last m d r action in the ordered set where uuid = ? and companyId = ?. 387 * 388 * @param uuid the uuid 389 * @param companyId the company ID 390 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 391 * @return the last matching m d r action 392 * @throws NoSuchActionException if a matching m d r action could not be found 393 */ 394 public static MDRAction findByUuid_C_Last(java.lang.String uuid, 395 long companyId, OrderByComparator<MDRAction> orderByComparator) 396 throws com.liferay.portlet.mobiledevicerules.NoSuchActionException { 397 return getPersistence() 398 .findByUuid_C_Last(uuid, companyId, orderByComparator); 399 } 400 401 /** 402 * Returns the last m d r action in the ordered set where uuid = ? and companyId = ?. 403 * 404 * @param uuid the uuid 405 * @param companyId the company ID 406 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 407 * @return the last matching m d r action, or <code>null</code> if a matching m d r action could not be found 408 */ 409 public static MDRAction fetchByUuid_C_Last(java.lang.String uuid, 410 long companyId, OrderByComparator<MDRAction> orderByComparator) { 411 return getPersistence() 412 .fetchByUuid_C_Last(uuid, companyId, orderByComparator); 413 } 414 415 /** 416 * Returns the m d r actions before and after the current m d r action in the ordered set where uuid = ? and companyId = ?. 417 * 418 * @param actionId the primary key of the current m d r action 419 * @param uuid the uuid 420 * @param companyId the company ID 421 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 422 * @return the previous, current, and next m d r action 423 * @throws NoSuchActionException if a m d r action with the primary key could not be found 424 */ 425 public static MDRAction[] findByUuid_C_PrevAndNext(long actionId, 426 java.lang.String uuid, long companyId, 427 OrderByComparator<MDRAction> orderByComparator) 428 throws com.liferay.portlet.mobiledevicerules.NoSuchActionException { 429 return getPersistence() 430 .findByUuid_C_PrevAndNext(actionId, uuid, companyId, 431 orderByComparator); 432 } 433 434 /** 435 * Removes all the m d r actions where uuid = ? and companyId = ? from the database. 436 * 437 * @param uuid the uuid 438 * @param companyId the company ID 439 */ 440 public static void removeByUuid_C(java.lang.String uuid, long companyId) { 441 getPersistence().removeByUuid_C(uuid, companyId); 442 } 443 444 /** 445 * Returns the number of m d r actions where uuid = ? and companyId = ?. 446 * 447 * @param uuid the uuid 448 * @param companyId the company ID 449 * @return the number of matching m d r actions 450 */ 451 public static int countByUuid_C(java.lang.String uuid, long companyId) { 452 return getPersistence().countByUuid_C(uuid, companyId); 453 } 454 455 /** 456 * Returns all the m d r actions where ruleGroupInstanceId = ?. 457 * 458 * @param ruleGroupInstanceId the rule group instance ID 459 * @return the matching m d r actions 460 */ 461 public static List<MDRAction> findByRuleGroupInstanceId( 462 long ruleGroupInstanceId) { 463 return getPersistence().findByRuleGroupInstanceId(ruleGroupInstanceId); 464 } 465 466 /** 467 * Returns a range of all the m d r actions where ruleGroupInstanceId = ?. 468 * 469 * <p> 470 * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link MDRActionModelImpl}. 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. 471 * </p> 472 * 473 * @param ruleGroupInstanceId the rule group instance ID 474 * @param start the lower bound of the range of m d r actions 475 * @param end the upper bound of the range of m d r actions (not inclusive) 476 * @return the range of matching m d r actions 477 */ 478 public static List<MDRAction> findByRuleGroupInstanceId( 479 long ruleGroupInstanceId, int start, int end) { 480 return getPersistence() 481 .findByRuleGroupInstanceId(ruleGroupInstanceId, start, end); 482 } 483 484 /** 485 * Returns an ordered range of all the m d r actions where ruleGroupInstanceId = ?. 486 * 487 * <p> 488 * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link MDRActionModelImpl}. 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. 489 * </p> 490 * 491 * @param ruleGroupInstanceId the rule group instance ID 492 * @param start the lower bound of the range of m d r actions 493 * @param end the upper bound of the range of m d r actions (not inclusive) 494 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 495 * @return the ordered range of matching m d r actions 496 */ 497 public static List<MDRAction> findByRuleGroupInstanceId( 498 long ruleGroupInstanceId, int start, int end, 499 OrderByComparator<MDRAction> orderByComparator) { 500 return getPersistence() 501 .findByRuleGroupInstanceId(ruleGroupInstanceId, start, end, 502 orderByComparator); 503 } 504 505 /** 506 * Returns the first m d r action in the ordered set where ruleGroupInstanceId = ?. 507 * 508 * @param ruleGroupInstanceId the rule group instance ID 509 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 510 * @return the first matching m d r action 511 * @throws NoSuchActionException if a matching m d r action could not be found 512 */ 513 public static MDRAction findByRuleGroupInstanceId_First( 514 long ruleGroupInstanceId, OrderByComparator<MDRAction> orderByComparator) 515 throws com.liferay.portlet.mobiledevicerules.NoSuchActionException { 516 return getPersistence() 517 .findByRuleGroupInstanceId_First(ruleGroupInstanceId, 518 orderByComparator); 519 } 520 521 /** 522 * Returns the first m d r action in the ordered set where ruleGroupInstanceId = ?. 523 * 524 * @param ruleGroupInstanceId the rule group instance ID 525 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 526 * @return the first matching m d r action, or <code>null</code> if a matching m d r action could not be found 527 */ 528 public static MDRAction fetchByRuleGroupInstanceId_First( 529 long ruleGroupInstanceId, OrderByComparator<MDRAction> orderByComparator) { 530 return getPersistence() 531 .fetchByRuleGroupInstanceId_First(ruleGroupInstanceId, 532 orderByComparator); 533 } 534 535 /** 536 * Returns the last m d r action in the ordered set where ruleGroupInstanceId = ?. 537 * 538 * @param ruleGroupInstanceId the rule group instance ID 539 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 540 * @return the last matching m d r action 541 * @throws NoSuchActionException if a matching m d r action could not be found 542 */ 543 public static MDRAction findByRuleGroupInstanceId_Last( 544 long ruleGroupInstanceId, OrderByComparator<MDRAction> orderByComparator) 545 throws com.liferay.portlet.mobiledevicerules.NoSuchActionException { 546 return getPersistence() 547 .findByRuleGroupInstanceId_Last(ruleGroupInstanceId, 548 orderByComparator); 549 } 550 551 /** 552 * Returns the last m d r action in the ordered set where ruleGroupInstanceId = ?. 553 * 554 * @param ruleGroupInstanceId the rule group instance ID 555 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 556 * @return the last matching m d r action, or <code>null</code> if a matching m d r action could not be found 557 */ 558 public static MDRAction fetchByRuleGroupInstanceId_Last( 559 long ruleGroupInstanceId, OrderByComparator<MDRAction> orderByComparator) { 560 return getPersistence() 561 .fetchByRuleGroupInstanceId_Last(ruleGroupInstanceId, 562 orderByComparator); 563 } 564 565 /** 566 * Returns the m d r actions before and after the current m d r action in the ordered set where ruleGroupInstanceId = ?. 567 * 568 * @param actionId the primary key of the current m d r action 569 * @param ruleGroupInstanceId the rule group instance ID 570 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 571 * @return the previous, current, and next m d r action 572 * @throws NoSuchActionException if a m d r action with the primary key could not be found 573 */ 574 public static MDRAction[] findByRuleGroupInstanceId_PrevAndNext( 575 long actionId, long ruleGroupInstanceId, 576 OrderByComparator<MDRAction> orderByComparator) 577 throws com.liferay.portlet.mobiledevicerules.NoSuchActionException { 578 return getPersistence() 579 .findByRuleGroupInstanceId_PrevAndNext(actionId, 580 ruleGroupInstanceId, orderByComparator); 581 } 582 583 /** 584 * Removes all the m d r actions where ruleGroupInstanceId = ? from the database. 585 * 586 * @param ruleGroupInstanceId the rule group instance ID 587 */ 588 public static void removeByRuleGroupInstanceId(long ruleGroupInstanceId) { 589 getPersistence().removeByRuleGroupInstanceId(ruleGroupInstanceId); 590 } 591 592 /** 593 * Returns the number of m d r actions where ruleGroupInstanceId = ?. 594 * 595 * @param ruleGroupInstanceId the rule group instance ID 596 * @return the number of matching m d r actions 597 */ 598 public static int countByRuleGroupInstanceId(long ruleGroupInstanceId) { 599 return getPersistence().countByRuleGroupInstanceId(ruleGroupInstanceId); 600 } 601 602 /** 603 * Caches the m d r action in the entity cache if it is enabled. 604 * 605 * @param mdrAction the m d r action 606 */ 607 public static void cacheResult(MDRAction mdrAction) { 608 getPersistence().cacheResult(mdrAction); 609 } 610 611 /** 612 * Caches the m d r actions in the entity cache if it is enabled. 613 * 614 * @param mdrActions the m d r actions 615 */ 616 public static void cacheResult(List<MDRAction> mdrActions) { 617 getPersistence().cacheResult(mdrActions); 618 } 619 620 /** 621 * Creates a new m d r action with the primary key. Does not add the m d r action to the database. 622 * 623 * @param actionId the primary key for the new m d r action 624 * @return the new m d r action 625 */ 626 public static MDRAction create(long actionId) { 627 return getPersistence().create(actionId); 628 } 629 630 /** 631 * Removes the m d r action with the primary key from the database. Also notifies the appropriate model listeners. 632 * 633 * @param actionId the primary key of the m d r action 634 * @return the m d r action that was removed 635 * @throws NoSuchActionException if a m d r action with the primary key could not be found 636 */ 637 public static MDRAction remove(long actionId) 638 throws com.liferay.portlet.mobiledevicerules.NoSuchActionException { 639 return getPersistence().remove(actionId); 640 } 641 642 public static MDRAction updateImpl(MDRAction mdrAction) { 643 return getPersistence().updateImpl(mdrAction); 644 } 645 646 /** 647 * Returns the m d r action with the primary key or throws a {@link NoSuchActionException} if it could not be found. 648 * 649 * @param actionId the primary key of the m d r action 650 * @return the m d r action 651 * @throws NoSuchActionException if a m d r action with the primary key could not be found 652 */ 653 public static MDRAction findByPrimaryKey(long actionId) 654 throws com.liferay.portlet.mobiledevicerules.NoSuchActionException { 655 return getPersistence().findByPrimaryKey(actionId); 656 } 657 658 /** 659 * Returns the m d r action with the primary key or returns <code>null</code> if it could not be found. 660 * 661 * @param actionId the primary key of the m d r action 662 * @return the m d r action, or <code>null</code> if a m d r action with the primary key could not be found 663 */ 664 public static MDRAction fetchByPrimaryKey(long actionId) { 665 return getPersistence().fetchByPrimaryKey(actionId); 666 } 667 668 public static java.util.Map<java.io.Serializable, MDRAction> fetchByPrimaryKeys( 669 java.util.Set<java.io.Serializable> primaryKeys) { 670 return getPersistence().fetchByPrimaryKeys(primaryKeys); 671 } 672 673 /** 674 * Returns all the m d r actions. 675 * 676 * @return the m d r actions 677 */ 678 public static List<MDRAction> findAll() { 679 return getPersistence().findAll(); 680 } 681 682 /** 683 * Returns a range of all the m d r actions. 684 * 685 * <p> 686 * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link MDRActionModelImpl}. 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. 687 * </p> 688 * 689 * @param start the lower bound of the range of m d r actions 690 * @param end the upper bound of the range of m d r actions (not inclusive) 691 * @return the range of m d r actions 692 */ 693 public static List<MDRAction> findAll(int start, int end) { 694 return getPersistence().findAll(start, end); 695 } 696 697 /** 698 * Returns an ordered range of all the m d r actions. 699 * 700 * <p> 701 * 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 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 QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link MDRActionModelImpl}. 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. 702 * </p> 703 * 704 * @param start the lower bound of the range of m d r actions 705 * @param end the upper bound of the range of m d r actions (not inclusive) 706 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 707 * @return the ordered range of m d r actions 708 */ 709 public static List<MDRAction> findAll(int start, int end, 710 OrderByComparator<MDRAction> orderByComparator) { 711 return getPersistence().findAll(start, end, orderByComparator); 712 } 713 714 /** 715 * Removes all the m d r actions from the database. 716 */ 717 public static void removeAll() { 718 getPersistence().removeAll(); 719 } 720 721 /** 722 * Returns the number of m d r actions. 723 * 724 * @return the number of m d r actions 725 */ 726 public static int countAll() { 727 return getPersistence().countAll(); 728 } 729 730 public static MDRActionPersistence getPersistence() { 731 if (_persistence == null) { 732 _persistence = (MDRActionPersistence)PortalBeanLocatorUtil.locate(MDRActionPersistence.class.getName()); 733 734 ReferenceRegistry.registerReference(MDRActionUtil.class, 735 "_persistence"); 736 } 737 738 return _persistence; 739 } 740 741 /** 742 * @deprecated As of 6.2.0 743 */ 744 @Deprecated 745 public void setPersistence(MDRActionPersistence persistence) { 746 } 747 748 private static MDRActionPersistence _persistence; 749 }