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.messageboards.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.messageboards.model.MBBan; 026 027 import java.util.List; 028 029 /** 030 * The persistence utility for the message boards ban service. This utility wraps {@link com.liferay.portlet.messageboards.service.persistence.impl.MBBanPersistenceImpl} and provides direct access to the database for CRUD operations. This utility should only be used by the service layer, as it must operate within a transaction. Never access this utility in a JSP, controller, model, or other front-end class. 031 * 032 * <p> 033 * Caching information and settings can be found in <code>portal.properties</code> 034 * </p> 035 * 036 * @author Brian Wing Shun Chan 037 * @see MBBanPersistence 038 * @see com.liferay.portlet.messageboards.service.persistence.impl.MBBanPersistenceImpl 039 * @generated 040 */ 041 @ProviderType 042 public class MBBanUtil { 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(MBBan mbBan) { 060 getPersistence().clearCache(mbBan); 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<MBBan> findWithDynamicQuery(DynamicQuery dynamicQuery) { 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<MBBan> findWithDynamicQuery(DynamicQuery dynamicQuery, 081 int start, int end) { 082 return getPersistence().findWithDynamicQuery(dynamicQuery, start, end); 083 } 084 085 /** 086 * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int, OrderByComparator) 087 */ 088 public static List<MBBan> findWithDynamicQuery(DynamicQuery dynamicQuery, 089 int start, int end, OrderByComparator<MBBan> orderByComparator) { 090 return getPersistence() 091 .findWithDynamicQuery(dynamicQuery, start, end, 092 orderByComparator); 093 } 094 095 /** 096 * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel) 097 */ 098 public static MBBan update(MBBan mbBan) { 099 return getPersistence().update(mbBan); 100 } 101 102 /** 103 * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, ServiceContext) 104 */ 105 public static MBBan update(MBBan mbBan, ServiceContext serviceContext) { 106 return getPersistence().update(mbBan, serviceContext); 107 } 108 109 /** 110 * Returns all the message boards bans where uuid = ?. 111 * 112 * @param uuid the uuid 113 * @return the matching message boards bans 114 */ 115 public static List<MBBan> findByUuid(java.lang.String uuid) { 116 return getPersistence().findByUuid(uuid); 117 } 118 119 /** 120 * Returns a range of all the message boards bans where uuid = ?. 121 * 122 * <p> 123 * 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 MBBanModelImpl}. 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. 124 * </p> 125 * 126 * @param uuid the uuid 127 * @param start the lower bound of the range of message boards bans 128 * @param end the upper bound of the range of message boards bans (not inclusive) 129 * @return the range of matching message boards bans 130 */ 131 public static List<MBBan> findByUuid(java.lang.String uuid, int start, 132 int end) { 133 return getPersistence().findByUuid(uuid, start, end); 134 } 135 136 /** 137 * Returns an ordered range of all the message boards bans where uuid = ?. 138 * 139 * <p> 140 * 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 MBBanModelImpl}. 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. 141 * </p> 142 * 143 * @param uuid the uuid 144 * @param start the lower bound of the range of message boards bans 145 * @param end the upper bound of the range of message boards bans (not inclusive) 146 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 147 * @return the ordered range of matching message boards bans 148 */ 149 public static List<MBBan> findByUuid(java.lang.String uuid, int start, 150 int end, OrderByComparator<MBBan> orderByComparator) { 151 return getPersistence().findByUuid(uuid, start, end, orderByComparator); 152 } 153 154 /** 155 * Returns an ordered range of all the message boards bans where uuid = ?. 156 * 157 * <p> 158 * 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 MBBanModelImpl}. 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. 159 * </p> 160 * 161 * @param uuid the uuid 162 * @param start the lower bound of the range of message boards bans 163 * @param end the upper bound of the range of message boards bans (not inclusive) 164 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 165 * @param retrieveFromCache whether to retrieve from the finder cache 166 * @return the ordered range of matching message boards bans 167 */ 168 public static List<MBBan> findByUuid(java.lang.String uuid, int start, 169 int end, OrderByComparator<MBBan> orderByComparator, 170 boolean retrieveFromCache) { 171 return getPersistence() 172 .findByUuid(uuid, start, end, orderByComparator, 173 retrieveFromCache); 174 } 175 176 /** 177 * Returns the first message boards ban in the ordered set where uuid = ?. 178 * 179 * @param uuid the uuid 180 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 181 * @return the first matching message boards ban 182 * @throws NoSuchBanException if a matching message boards ban could not be found 183 */ 184 public static MBBan findByUuid_First(java.lang.String uuid, 185 OrderByComparator<MBBan> orderByComparator) 186 throws com.liferay.portlet.messageboards.exception.NoSuchBanException { 187 return getPersistence().findByUuid_First(uuid, orderByComparator); 188 } 189 190 /** 191 * Returns the first message boards ban in the ordered set where uuid = ?. 192 * 193 * @param uuid the uuid 194 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 195 * @return the first matching message boards ban, or <code>null</code> if a matching message boards ban could not be found 196 */ 197 public static MBBan fetchByUuid_First(java.lang.String uuid, 198 OrderByComparator<MBBan> orderByComparator) { 199 return getPersistence().fetchByUuid_First(uuid, orderByComparator); 200 } 201 202 /** 203 * Returns the last message boards ban in the ordered set where uuid = ?. 204 * 205 * @param uuid the uuid 206 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 207 * @return the last matching message boards ban 208 * @throws NoSuchBanException if a matching message boards ban could not be found 209 */ 210 public static MBBan findByUuid_Last(java.lang.String uuid, 211 OrderByComparator<MBBan> orderByComparator) 212 throws com.liferay.portlet.messageboards.exception.NoSuchBanException { 213 return getPersistence().findByUuid_Last(uuid, orderByComparator); 214 } 215 216 /** 217 * Returns the last message boards ban in the ordered set where uuid = ?. 218 * 219 * @param uuid the uuid 220 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 221 * @return the last matching message boards ban, or <code>null</code> if a matching message boards ban could not be found 222 */ 223 public static MBBan fetchByUuid_Last(java.lang.String uuid, 224 OrderByComparator<MBBan> orderByComparator) { 225 return getPersistence().fetchByUuid_Last(uuid, orderByComparator); 226 } 227 228 /** 229 * Returns the message boards bans before and after the current message boards ban in the ordered set where uuid = ?. 230 * 231 * @param banId the primary key of the current message boards ban 232 * @param uuid the uuid 233 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 234 * @return the previous, current, and next message boards ban 235 * @throws NoSuchBanException if a message boards ban with the primary key could not be found 236 */ 237 public static MBBan[] findByUuid_PrevAndNext(long banId, 238 java.lang.String uuid, OrderByComparator<MBBan> orderByComparator) 239 throws com.liferay.portlet.messageboards.exception.NoSuchBanException { 240 return getPersistence() 241 .findByUuid_PrevAndNext(banId, uuid, orderByComparator); 242 } 243 244 /** 245 * Removes all the message boards bans where uuid = ? from the database. 246 * 247 * @param uuid the uuid 248 */ 249 public static void removeByUuid(java.lang.String uuid) { 250 getPersistence().removeByUuid(uuid); 251 } 252 253 /** 254 * Returns the number of message boards bans where uuid = ?. 255 * 256 * @param uuid the uuid 257 * @return the number of matching message boards bans 258 */ 259 public static int countByUuid(java.lang.String uuid) { 260 return getPersistence().countByUuid(uuid); 261 } 262 263 /** 264 * Returns the message boards ban where uuid = ? and groupId = ? or throws a {@link NoSuchBanException} if it could not be found. 265 * 266 * @param uuid the uuid 267 * @param groupId the group ID 268 * @return the matching message boards ban 269 * @throws NoSuchBanException if a matching message boards ban could not be found 270 */ 271 public static MBBan findByUUID_G(java.lang.String uuid, long groupId) 272 throws com.liferay.portlet.messageboards.exception.NoSuchBanException { 273 return getPersistence().findByUUID_G(uuid, groupId); 274 } 275 276 /** 277 * Returns the message boards ban where uuid = ? and groupId = ? or returns <code>null</code> if it could not be found. Uses the finder cache. 278 * 279 * @param uuid the uuid 280 * @param groupId the group ID 281 * @return the matching message boards ban, or <code>null</code> if a matching message boards ban could not be found 282 */ 283 public static MBBan fetchByUUID_G(java.lang.String uuid, long groupId) { 284 return getPersistence().fetchByUUID_G(uuid, groupId); 285 } 286 287 /** 288 * Returns the message boards ban where uuid = ? and groupId = ? or returns <code>null</code> if it could not be found, optionally using the finder cache. 289 * 290 * @param uuid the uuid 291 * @param groupId the group ID 292 * @param retrieveFromCache whether to retrieve from the finder cache 293 * @return the matching message boards ban, or <code>null</code> if a matching message boards ban could not be found 294 */ 295 public static MBBan fetchByUUID_G(java.lang.String uuid, long groupId, 296 boolean retrieveFromCache) { 297 return getPersistence().fetchByUUID_G(uuid, groupId, retrieveFromCache); 298 } 299 300 /** 301 * Removes the message boards ban where uuid = ? and groupId = ? from the database. 302 * 303 * @param uuid the uuid 304 * @param groupId the group ID 305 * @return the message boards ban that was removed 306 */ 307 public static MBBan removeByUUID_G(java.lang.String uuid, long groupId) 308 throws com.liferay.portlet.messageboards.exception.NoSuchBanException { 309 return getPersistence().removeByUUID_G(uuid, groupId); 310 } 311 312 /** 313 * Returns the number of message boards bans where uuid = ? and groupId = ?. 314 * 315 * @param uuid the uuid 316 * @param groupId the group ID 317 * @return the number of matching message boards bans 318 */ 319 public static int countByUUID_G(java.lang.String uuid, long groupId) { 320 return getPersistence().countByUUID_G(uuid, groupId); 321 } 322 323 /** 324 * Returns all the message boards bans where uuid = ? and companyId = ?. 325 * 326 * @param uuid the uuid 327 * @param companyId the company ID 328 * @return the matching message boards bans 329 */ 330 public static List<MBBan> findByUuid_C(java.lang.String uuid, long companyId) { 331 return getPersistence().findByUuid_C(uuid, companyId); 332 } 333 334 /** 335 * Returns a range of all the message boards bans 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 MBBanModelImpl}. 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 message boards bans 344 * @param end the upper bound of the range of message boards bans (not inclusive) 345 * @return the range of matching message boards bans 346 */ 347 public static List<MBBan> findByUuid_C(java.lang.String uuid, 348 long companyId, int start, int end) { 349 return getPersistence().findByUuid_C(uuid, companyId, start, end); 350 } 351 352 /** 353 * Returns an ordered range of all the message boards bans where uuid = ? and companyId = ?. 354 * 355 * <p> 356 * 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 MBBanModelImpl}. 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. 357 * </p> 358 * 359 * @param uuid the uuid 360 * @param companyId the company ID 361 * @param start the lower bound of the range of message boards bans 362 * @param end the upper bound of the range of message boards bans (not inclusive) 363 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 364 * @return the ordered range of matching message boards bans 365 */ 366 public static List<MBBan> findByUuid_C(java.lang.String uuid, 367 long companyId, int start, int end, 368 OrderByComparator<MBBan> orderByComparator) { 369 return getPersistence() 370 .findByUuid_C(uuid, companyId, start, end, orderByComparator); 371 } 372 373 /** 374 * Returns an ordered range of all the message boards bans where uuid = ? and companyId = ?. 375 * 376 * <p> 377 * 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 MBBanModelImpl}. 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. 378 * </p> 379 * 380 * @param uuid the uuid 381 * @param companyId the company ID 382 * @param start the lower bound of the range of message boards bans 383 * @param end the upper bound of the range of message boards bans (not inclusive) 384 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 385 * @param retrieveFromCache whether to retrieve from the finder cache 386 * @return the ordered range of matching message boards bans 387 */ 388 public static List<MBBan> findByUuid_C(java.lang.String uuid, 389 long companyId, int start, int end, 390 OrderByComparator<MBBan> orderByComparator, boolean retrieveFromCache) { 391 return getPersistence() 392 .findByUuid_C(uuid, companyId, start, end, 393 orderByComparator, retrieveFromCache); 394 } 395 396 /** 397 * Returns the first message boards ban in the ordered set where uuid = ? and companyId = ?. 398 * 399 * @param uuid the uuid 400 * @param companyId the company ID 401 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 402 * @return the first matching message boards ban 403 * @throws NoSuchBanException if a matching message boards ban could not be found 404 */ 405 public static MBBan findByUuid_C_First(java.lang.String uuid, 406 long companyId, OrderByComparator<MBBan> orderByComparator) 407 throws com.liferay.portlet.messageboards.exception.NoSuchBanException { 408 return getPersistence() 409 .findByUuid_C_First(uuid, companyId, orderByComparator); 410 } 411 412 /** 413 * Returns the first message boards ban in the ordered set where uuid = ? and companyId = ?. 414 * 415 * @param uuid the uuid 416 * @param companyId the company ID 417 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 418 * @return the first matching message boards ban, or <code>null</code> if a matching message boards ban could not be found 419 */ 420 public static MBBan fetchByUuid_C_First(java.lang.String uuid, 421 long companyId, OrderByComparator<MBBan> orderByComparator) { 422 return getPersistence() 423 .fetchByUuid_C_First(uuid, companyId, orderByComparator); 424 } 425 426 /** 427 * Returns the last message boards ban in the ordered set where uuid = ? and companyId = ?. 428 * 429 * @param uuid the uuid 430 * @param companyId the company ID 431 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 432 * @return the last matching message boards ban 433 * @throws NoSuchBanException if a matching message boards ban could not be found 434 */ 435 public static MBBan findByUuid_C_Last(java.lang.String uuid, 436 long companyId, OrderByComparator<MBBan> orderByComparator) 437 throws com.liferay.portlet.messageboards.exception.NoSuchBanException { 438 return getPersistence() 439 .findByUuid_C_Last(uuid, companyId, orderByComparator); 440 } 441 442 /** 443 * Returns the last message boards ban in the ordered set where uuid = ? and companyId = ?. 444 * 445 * @param uuid the uuid 446 * @param companyId the company ID 447 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 448 * @return the last matching message boards ban, or <code>null</code> if a matching message boards ban could not be found 449 */ 450 public static MBBan fetchByUuid_C_Last(java.lang.String uuid, 451 long companyId, OrderByComparator<MBBan> orderByComparator) { 452 return getPersistence() 453 .fetchByUuid_C_Last(uuid, companyId, orderByComparator); 454 } 455 456 /** 457 * Returns the message boards bans before and after the current message boards ban in the ordered set where uuid = ? and companyId = ?. 458 * 459 * @param banId the primary key of the current message boards ban 460 * @param uuid the uuid 461 * @param companyId the company ID 462 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 463 * @return the previous, current, and next message boards ban 464 * @throws NoSuchBanException if a message boards ban with the primary key could not be found 465 */ 466 public static MBBan[] findByUuid_C_PrevAndNext(long banId, 467 java.lang.String uuid, long companyId, 468 OrderByComparator<MBBan> orderByComparator) 469 throws com.liferay.portlet.messageboards.exception.NoSuchBanException { 470 return getPersistence() 471 .findByUuid_C_PrevAndNext(banId, uuid, companyId, 472 orderByComparator); 473 } 474 475 /** 476 * Removes all the message boards bans where uuid = ? and companyId = ? from the database. 477 * 478 * @param uuid the uuid 479 * @param companyId the company ID 480 */ 481 public static void removeByUuid_C(java.lang.String uuid, long companyId) { 482 getPersistence().removeByUuid_C(uuid, companyId); 483 } 484 485 /** 486 * Returns the number of message boards bans where uuid = ? and companyId = ?. 487 * 488 * @param uuid the uuid 489 * @param companyId the company ID 490 * @return the number of matching message boards bans 491 */ 492 public static int countByUuid_C(java.lang.String uuid, long companyId) { 493 return getPersistence().countByUuid_C(uuid, companyId); 494 } 495 496 /** 497 * Returns all the message boards bans where groupId = ?. 498 * 499 * @param groupId the group ID 500 * @return the matching message boards bans 501 */ 502 public static List<MBBan> findByGroupId(long groupId) { 503 return getPersistence().findByGroupId(groupId); 504 } 505 506 /** 507 * Returns a range of all the message boards bans where groupId = ?. 508 * 509 * <p> 510 * 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 MBBanModelImpl}. 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. 511 * </p> 512 * 513 * @param groupId the group ID 514 * @param start the lower bound of the range of message boards bans 515 * @param end the upper bound of the range of message boards bans (not inclusive) 516 * @return the range of matching message boards bans 517 */ 518 public static List<MBBan> findByGroupId(long groupId, int start, int end) { 519 return getPersistence().findByGroupId(groupId, start, end); 520 } 521 522 /** 523 * Returns an ordered range of all the message boards bans where groupId = ?. 524 * 525 * <p> 526 * 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 MBBanModelImpl}. 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. 527 * </p> 528 * 529 * @param groupId the group ID 530 * @param start the lower bound of the range of message boards bans 531 * @param end the upper bound of the range of message boards bans (not inclusive) 532 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 533 * @return the ordered range of matching message boards bans 534 */ 535 public static List<MBBan> findByGroupId(long groupId, int start, int end, 536 OrderByComparator<MBBan> orderByComparator) { 537 return getPersistence() 538 .findByGroupId(groupId, start, end, orderByComparator); 539 } 540 541 /** 542 * Returns an ordered range of all the message boards bans where groupId = ?. 543 * 544 * <p> 545 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link 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 MBBanModelImpl}. If both <code>orderByComparator</code> and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order. 546 * </p> 547 * 548 * @param groupId the group ID 549 * @param start the lower bound of the range of message boards bans 550 * @param end the upper bound of the range of message boards bans (not inclusive) 551 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 552 * @param retrieveFromCache whether to retrieve from the finder cache 553 * @return the ordered range of matching message boards bans 554 */ 555 public static List<MBBan> findByGroupId(long groupId, int start, int end, 556 OrderByComparator<MBBan> orderByComparator, boolean retrieveFromCache) { 557 return getPersistence() 558 .findByGroupId(groupId, start, end, orderByComparator, 559 retrieveFromCache); 560 } 561 562 /** 563 * Returns the first message boards ban in the ordered set where groupId = ?. 564 * 565 * @param groupId the group ID 566 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 567 * @return the first matching message boards ban 568 * @throws NoSuchBanException if a matching message boards ban could not be found 569 */ 570 public static MBBan findByGroupId_First(long groupId, 571 OrderByComparator<MBBan> orderByComparator) 572 throws com.liferay.portlet.messageboards.exception.NoSuchBanException { 573 return getPersistence().findByGroupId_First(groupId, orderByComparator); 574 } 575 576 /** 577 * Returns the first message boards ban in the ordered set where groupId = ?. 578 * 579 * @param groupId the group ID 580 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 581 * @return the first matching message boards ban, or <code>null</code> if a matching message boards ban could not be found 582 */ 583 public static MBBan fetchByGroupId_First(long groupId, 584 OrderByComparator<MBBan> orderByComparator) { 585 return getPersistence().fetchByGroupId_First(groupId, orderByComparator); 586 } 587 588 /** 589 * Returns the last message boards ban in the ordered set where groupId = ?. 590 * 591 * @param groupId the group ID 592 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 593 * @return the last matching message boards ban 594 * @throws NoSuchBanException if a matching message boards ban could not be found 595 */ 596 public static MBBan findByGroupId_Last(long groupId, 597 OrderByComparator<MBBan> orderByComparator) 598 throws com.liferay.portlet.messageboards.exception.NoSuchBanException { 599 return getPersistence().findByGroupId_Last(groupId, orderByComparator); 600 } 601 602 /** 603 * Returns the last message boards ban in the ordered set where groupId = ?. 604 * 605 * @param groupId the group ID 606 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 607 * @return the last matching message boards ban, or <code>null</code> if a matching message boards ban could not be found 608 */ 609 public static MBBan fetchByGroupId_Last(long groupId, 610 OrderByComparator<MBBan> orderByComparator) { 611 return getPersistence().fetchByGroupId_Last(groupId, orderByComparator); 612 } 613 614 /** 615 * Returns the message boards bans before and after the current message boards ban in the ordered set where groupId = ?. 616 * 617 * @param banId the primary key of the current message boards ban 618 * @param groupId the group ID 619 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 620 * @return the previous, current, and next message boards ban 621 * @throws NoSuchBanException if a message boards ban with the primary key could not be found 622 */ 623 public static MBBan[] findByGroupId_PrevAndNext(long banId, long groupId, 624 OrderByComparator<MBBan> orderByComparator) 625 throws com.liferay.portlet.messageboards.exception.NoSuchBanException { 626 return getPersistence() 627 .findByGroupId_PrevAndNext(banId, groupId, orderByComparator); 628 } 629 630 /** 631 * Removes all the message boards bans where groupId = ? from the database. 632 * 633 * @param groupId the group ID 634 */ 635 public static void removeByGroupId(long groupId) { 636 getPersistence().removeByGroupId(groupId); 637 } 638 639 /** 640 * Returns the number of message boards bans where groupId = ?. 641 * 642 * @param groupId the group ID 643 * @return the number of matching message boards bans 644 */ 645 public static int countByGroupId(long groupId) { 646 return getPersistence().countByGroupId(groupId); 647 } 648 649 /** 650 * Returns all the message boards bans where userId = ?. 651 * 652 * @param userId the user ID 653 * @return the matching message boards bans 654 */ 655 public static List<MBBan> findByUserId(long userId) { 656 return getPersistence().findByUserId(userId); 657 } 658 659 /** 660 * Returns a range of all the message boards bans where userId = ?. 661 * 662 * <p> 663 * 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 MBBanModelImpl}. 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. 664 * </p> 665 * 666 * @param userId the user ID 667 * @param start the lower bound of the range of message boards bans 668 * @param end the upper bound of the range of message boards bans (not inclusive) 669 * @return the range of matching message boards bans 670 */ 671 public static List<MBBan> findByUserId(long userId, int start, int end) { 672 return getPersistence().findByUserId(userId, start, end); 673 } 674 675 /** 676 * Returns an ordered range of all the message boards bans where userId = ?. 677 * 678 * <p> 679 * 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 MBBanModelImpl}. 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. 680 * </p> 681 * 682 * @param userId the user ID 683 * @param start the lower bound of the range of message boards bans 684 * @param end the upper bound of the range of message boards bans (not inclusive) 685 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 686 * @return the ordered range of matching message boards bans 687 */ 688 public static List<MBBan> findByUserId(long userId, int start, int end, 689 OrderByComparator<MBBan> orderByComparator) { 690 return getPersistence() 691 .findByUserId(userId, start, end, orderByComparator); 692 } 693 694 /** 695 * Returns an ordered range of all the message boards bans where userId = ?. 696 * 697 * <p> 698 * 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 MBBanModelImpl}. 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. 699 * </p> 700 * 701 * @param userId the user ID 702 * @param start the lower bound of the range of message boards bans 703 * @param end the upper bound of the range of message boards bans (not inclusive) 704 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 705 * @param retrieveFromCache whether to retrieve from the finder cache 706 * @return the ordered range of matching message boards bans 707 */ 708 public static List<MBBan> findByUserId(long userId, int start, int end, 709 OrderByComparator<MBBan> orderByComparator, boolean retrieveFromCache) { 710 return getPersistence() 711 .findByUserId(userId, start, end, orderByComparator, 712 retrieveFromCache); 713 } 714 715 /** 716 * Returns the first message boards ban in the ordered set where userId = ?. 717 * 718 * @param userId the user ID 719 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 720 * @return the first matching message boards ban 721 * @throws NoSuchBanException if a matching message boards ban could not be found 722 */ 723 public static MBBan findByUserId_First(long userId, 724 OrderByComparator<MBBan> orderByComparator) 725 throws com.liferay.portlet.messageboards.exception.NoSuchBanException { 726 return getPersistence().findByUserId_First(userId, orderByComparator); 727 } 728 729 /** 730 * Returns the first message boards ban in the ordered set where userId = ?. 731 * 732 * @param userId the user ID 733 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 734 * @return the first matching message boards ban, or <code>null</code> if a matching message boards ban could not be found 735 */ 736 public static MBBan fetchByUserId_First(long userId, 737 OrderByComparator<MBBan> orderByComparator) { 738 return getPersistence().fetchByUserId_First(userId, orderByComparator); 739 } 740 741 /** 742 * Returns the last message boards ban in the ordered set where userId = ?. 743 * 744 * @param userId the user ID 745 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 746 * @return the last matching message boards ban 747 * @throws NoSuchBanException if a matching message boards ban could not be found 748 */ 749 public static MBBan findByUserId_Last(long userId, 750 OrderByComparator<MBBan> orderByComparator) 751 throws com.liferay.portlet.messageboards.exception.NoSuchBanException { 752 return getPersistence().findByUserId_Last(userId, orderByComparator); 753 } 754 755 /** 756 * Returns the last message boards ban in the ordered set where userId = ?. 757 * 758 * @param userId the user ID 759 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 760 * @return the last matching message boards ban, or <code>null</code> if a matching message boards ban could not be found 761 */ 762 public static MBBan fetchByUserId_Last(long userId, 763 OrderByComparator<MBBan> orderByComparator) { 764 return getPersistence().fetchByUserId_Last(userId, orderByComparator); 765 } 766 767 /** 768 * Returns the message boards bans before and after the current message boards ban in the ordered set where userId = ?. 769 * 770 * @param banId the primary key of the current message boards ban 771 * @param userId the user ID 772 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 773 * @return the previous, current, and next message boards ban 774 * @throws NoSuchBanException if a message boards ban with the primary key could not be found 775 */ 776 public static MBBan[] findByUserId_PrevAndNext(long banId, long userId, 777 OrderByComparator<MBBan> orderByComparator) 778 throws com.liferay.portlet.messageboards.exception.NoSuchBanException { 779 return getPersistence() 780 .findByUserId_PrevAndNext(banId, userId, orderByComparator); 781 } 782 783 /** 784 * Removes all the message boards bans where userId = ? from the database. 785 * 786 * @param userId the user ID 787 */ 788 public static void removeByUserId(long userId) { 789 getPersistence().removeByUserId(userId); 790 } 791 792 /** 793 * Returns the number of message boards bans where userId = ?. 794 * 795 * @param userId the user ID 796 * @return the number of matching message boards bans 797 */ 798 public static int countByUserId(long userId) { 799 return getPersistence().countByUserId(userId); 800 } 801 802 /** 803 * Returns all the message boards bans where banUserId = ?. 804 * 805 * @param banUserId the ban user ID 806 * @return the matching message boards bans 807 */ 808 public static List<MBBan> findByBanUserId(long banUserId) { 809 return getPersistence().findByBanUserId(banUserId); 810 } 811 812 /** 813 * Returns a range of all the message boards bans where banUserId = ?. 814 * 815 * <p> 816 * 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 MBBanModelImpl}. 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. 817 * </p> 818 * 819 * @param banUserId the ban user ID 820 * @param start the lower bound of the range of message boards bans 821 * @param end the upper bound of the range of message boards bans (not inclusive) 822 * @return the range of matching message boards bans 823 */ 824 public static List<MBBan> findByBanUserId(long banUserId, int start, int end) { 825 return getPersistence().findByBanUserId(banUserId, start, end); 826 } 827 828 /** 829 * Returns an ordered range of all the message boards bans where banUserId = ?. 830 * 831 * <p> 832 * 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 MBBanModelImpl}. 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. 833 * </p> 834 * 835 * @param banUserId the ban user ID 836 * @param start the lower bound of the range of message boards bans 837 * @param end the upper bound of the range of message boards bans (not inclusive) 838 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 839 * @return the ordered range of matching message boards bans 840 */ 841 public static List<MBBan> findByBanUserId(long banUserId, int start, 842 int end, OrderByComparator<MBBan> orderByComparator) { 843 return getPersistence() 844 .findByBanUserId(banUserId, start, end, orderByComparator); 845 } 846 847 /** 848 * Returns an ordered range of all the message boards bans where banUserId = ?. 849 * 850 * <p> 851 * 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 MBBanModelImpl}. 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. 852 * </p> 853 * 854 * @param banUserId the ban user ID 855 * @param start the lower bound of the range of message boards bans 856 * @param end the upper bound of the range of message boards bans (not inclusive) 857 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 858 * @param retrieveFromCache whether to retrieve from the finder cache 859 * @return the ordered range of matching message boards bans 860 */ 861 public static List<MBBan> findByBanUserId(long banUserId, int start, 862 int end, OrderByComparator<MBBan> orderByComparator, 863 boolean retrieveFromCache) { 864 return getPersistence() 865 .findByBanUserId(banUserId, start, end, orderByComparator, 866 retrieveFromCache); 867 } 868 869 /** 870 * Returns the first message boards ban in the ordered set where banUserId = ?. 871 * 872 * @param banUserId the ban user ID 873 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 874 * @return the first matching message boards ban 875 * @throws NoSuchBanException if a matching message boards ban could not be found 876 */ 877 public static MBBan findByBanUserId_First(long banUserId, 878 OrderByComparator<MBBan> orderByComparator) 879 throws com.liferay.portlet.messageboards.exception.NoSuchBanException { 880 return getPersistence() 881 .findByBanUserId_First(banUserId, orderByComparator); 882 } 883 884 /** 885 * Returns the first message boards ban in the ordered set where banUserId = ?. 886 * 887 * @param banUserId the ban user ID 888 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 889 * @return the first matching message boards ban, or <code>null</code> if a matching message boards ban could not be found 890 */ 891 public static MBBan fetchByBanUserId_First(long banUserId, 892 OrderByComparator<MBBan> orderByComparator) { 893 return getPersistence() 894 .fetchByBanUserId_First(banUserId, orderByComparator); 895 } 896 897 /** 898 * Returns the last message boards ban in the ordered set where banUserId = ?. 899 * 900 * @param banUserId the ban user ID 901 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 902 * @return the last matching message boards ban 903 * @throws NoSuchBanException if a matching message boards ban could not be found 904 */ 905 public static MBBan findByBanUserId_Last(long banUserId, 906 OrderByComparator<MBBan> orderByComparator) 907 throws com.liferay.portlet.messageboards.exception.NoSuchBanException { 908 return getPersistence() 909 .findByBanUserId_Last(banUserId, orderByComparator); 910 } 911 912 /** 913 * Returns the last message boards ban in the ordered set where banUserId = ?. 914 * 915 * @param banUserId the ban user ID 916 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 917 * @return the last matching message boards ban, or <code>null</code> if a matching message boards ban could not be found 918 */ 919 public static MBBan fetchByBanUserId_Last(long banUserId, 920 OrderByComparator<MBBan> orderByComparator) { 921 return getPersistence() 922 .fetchByBanUserId_Last(banUserId, orderByComparator); 923 } 924 925 /** 926 * Returns the message boards bans before and after the current message boards ban in the ordered set where banUserId = ?. 927 * 928 * @param banId the primary key of the current message boards ban 929 * @param banUserId the ban user ID 930 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 931 * @return the previous, current, and next message boards ban 932 * @throws NoSuchBanException if a message boards ban with the primary key could not be found 933 */ 934 public static MBBan[] findByBanUserId_PrevAndNext(long banId, 935 long banUserId, OrderByComparator<MBBan> orderByComparator) 936 throws com.liferay.portlet.messageboards.exception.NoSuchBanException { 937 return getPersistence() 938 .findByBanUserId_PrevAndNext(banId, banUserId, 939 orderByComparator); 940 } 941 942 /** 943 * Removes all the message boards bans where banUserId = ? from the database. 944 * 945 * @param banUserId the ban user ID 946 */ 947 public static void removeByBanUserId(long banUserId) { 948 getPersistence().removeByBanUserId(banUserId); 949 } 950 951 /** 952 * Returns the number of message boards bans where banUserId = ?. 953 * 954 * @param banUserId the ban user ID 955 * @return the number of matching message boards bans 956 */ 957 public static int countByBanUserId(long banUserId) { 958 return getPersistence().countByBanUserId(banUserId); 959 } 960 961 /** 962 * Returns the message boards ban where groupId = ? and banUserId = ? or throws a {@link NoSuchBanException} if it could not be found. 963 * 964 * @param groupId the group ID 965 * @param banUserId the ban user ID 966 * @return the matching message boards ban 967 * @throws NoSuchBanException if a matching message boards ban could not be found 968 */ 969 public static MBBan findByG_B(long groupId, long banUserId) 970 throws com.liferay.portlet.messageboards.exception.NoSuchBanException { 971 return getPersistence().findByG_B(groupId, banUserId); 972 } 973 974 /** 975 * Returns the message boards ban where groupId = ? and banUserId = ? or returns <code>null</code> if it could not be found. Uses the finder cache. 976 * 977 * @param groupId the group ID 978 * @param banUserId the ban user ID 979 * @return the matching message boards ban, or <code>null</code> if a matching message boards ban could not be found 980 */ 981 public static MBBan fetchByG_B(long groupId, long banUserId) { 982 return getPersistence().fetchByG_B(groupId, banUserId); 983 } 984 985 /** 986 * Returns the message boards ban where groupId = ? and banUserId = ? or returns <code>null</code> if it could not be found, optionally using the finder cache. 987 * 988 * @param groupId the group ID 989 * @param banUserId the ban user ID 990 * @param retrieveFromCache whether to retrieve from the finder cache 991 * @return the matching message boards ban, or <code>null</code> if a matching message boards ban could not be found 992 */ 993 public static MBBan fetchByG_B(long groupId, long banUserId, 994 boolean retrieveFromCache) { 995 return getPersistence().fetchByG_B(groupId, banUserId, retrieveFromCache); 996 } 997 998 /** 999 * Removes the message boards ban where groupId = ? and banUserId = ? from the database. 1000 * 1001 * @param groupId the group ID 1002 * @param banUserId the ban user ID 1003 * @return the message boards ban that was removed 1004 */ 1005 public static MBBan removeByG_B(long groupId, long banUserId) 1006 throws com.liferay.portlet.messageboards.exception.NoSuchBanException { 1007 return getPersistence().removeByG_B(groupId, banUserId); 1008 } 1009 1010 /** 1011 * Returns the number of message boards bans where groupId = ? and banUserId = ?. 1012 * 1013 * @param groupId the group ID 1014 * @param banUserId the ban user ID 1015 * @return the number of matching message boards bans 1016 */ 1017 public static int countByG_B(long groupId, long banUserId) { 1018 return getPersistence().countByG_B(groupId, banUserId); 1019 } 1020 1021 /** 1022 * Caches the message boards ban in the entity cache if it is enabled. 1023 * 1024 * @param mbBan the message boards ban 1025 */ 1026 public static void cacheResult(MBBan mbBan) { 1027 getPersistence().cacheResult(mbBan); 1028 } 1029 1030 /** 1031 * Caches the message boards bans in the entity cache if it is enabled. 1032 * 1033 * @param mbBans the message boards bans 1034 */ 1035 public static void cacheResult(List<MBBan> mbBans) { 1036 getPersistence().cacheResult(mbBans); 1037 } 1038 1039 /** 1040 * Creates a new message boards ban with the primary key. Does not add the message boards ban to the database. 1041 * 1042 * @param banId the primary key for the new message boards ban 1043 * @return the new message boards ban 1044 */ 1045 public static MBBan create(long banId) { 1046 return getPersistence().create(banId); 1047 } 1048 1049 /** 1050 * Removes the message boards ban with the primary key from the database. Also notifies the appropriate model listeners. 1051 * 1052 * @param banId the primary key of the message boards ban 1053 * @return the message boards ban that was removed 1054 * @throws NoSuchBanException if a message boards ban with the primary key could not be found 1055 */ 1056 public static MBBan remove(long banId) 1057 throws com.liferay.portlet.messageboards.exception.NoSuchBanException { 1058 return getPersistence().remove(banId); 1059 } 1060 1061 public static MBBan updateImpl(MBBan mbBan) { 1062 return getPersistence().updateImpl(mbBan); 1063 } 1064 1065 /** 1066 * Returns the message boards ban with the primary key or throws a {@link NoSuchBanException} if it could not be found. 1067 * 1068 * @param banId the primary key of the message boards ban 1069 * @return the message boards ban 1070 * @throws NoSuchBanException if a message boards ban with the primary key could not be found 1071 */ 1072 public static MBBan findByPrimaryKey(long banId) 1073 throws com.liferay.portlet.messageboards.exception.NoSuchBanException { 1074 return getPersistence().findByPrimaryKey(banId); 1075 } 1076 1077 /** 1078 * Returns the message boards ban with the primary key or returns <code>null</code> if it could not be found. 1079 * 1080 * @param banId the primary key of the message boards ban 1081 * @return the message boards ban, or <code>null</code> if a message boards ban with the primary key could not be found 1082 */ 1083 public static MBBan fetchByPrimaryKey(long banId) { 1084 return getPersistence().fetchByPrimaryKey(banId); 1085 } 1086 1087 public static java.util.Map<java.io.Serializable, MBBan> fetchByPrimaryKeys( 1088 java.util.Set<java.io.Serializable> primaryKeys) { 1089 return getPersistence().fetchByPrimaryKeys(primaryKeys); 1090 } 1091 1092 /** 1093 * Returns all the message boards bans. 1094 * 1095 * @return the message boards bans 1096 */ 1097 public static List<MBBan> findAll() { 1098 return getPersistence().findAll(); 1099 } 1100 1101 /** 1102 * Returns a range of all the message boards bans. 1103 * 1104 * <p> 1105 * 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 MBBanModelImpl}. 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. 1106 * </p> 1107 * 1108 * @param start the lower bound of the range of message boards bans 1109 * @param end the upper bound of the range of message boards bans (not inclusive) 1110 * @return the range of message boards bans 1111 */ 1112 public static List<MBBan> findAll(int start, int end) { 1113 return getPersistence().findAll(start, end); 1114 } 1115 1116 /** 1117 * Returns an ordered range of all the message boards bans. 1118 * 1119 * <p> 1120 * 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 MBBanModelImpl}. 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. 1121 * </p> 1122 * 1123 * @param start the lower bound of the range of message boards bans 1124 * @param end the upper bound of the range of message boards bans (not inclusive) 1125 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 1126 * @return the ordered range of message boards bans 1127 */ 1128 public static List<MBBan> findAll(int start, int end, 1129 OrderByComparator<MBBan> orderByComparator) { 1130 return getPersistence().findAll(start, end, orderByComparator); 1131 } 1132 1133 /** 1134 * Returns an ordered range of all the message boards bans. 1135 * 1136 * <p> 1137 * 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 MBBanModelImpl}. 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. 1138 * </p> 1139 * 1140 * @param start the lower bound of the range of message boards bans 1141 * @param end the upper bound of the range of message boards bans (not inclusive) 1142 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 1143 * @param retrieveFromCache whether to retrieve from the finder cache 1144 * @return the ordered range of message boards bans 1145 */ 1146 public static List<MBBan> findAll(int start, int end, 1147 OrderByComparator<MBBan> orderByComparator, boolean retrieveFromCache) { 1148 return getPersistence() 1149 .findAll(start, end, orderByComparator, retrieveFromCache); 1150 } 1151 1152 /** 1153 * Removes all the message boards bans from the database. 1154 */ 1155 public static void removeAll() { 1156 getPersistence().removeAll(); 1157 } 1158 1159 /** 1160 * Returns the number of message boards bans. 1161 * 1162 * @return the number of message boards bans 1163 */ 1164 public static int countAll() { 1165 return getPersistence().countAll(); 1166 } 1167 1168 public static java.util.Set<java.lang.String> getBadColumnNames() { 1169 return getPersistence().getBadColumnNames(); 1170 } 1171 1172 public static MBBanPersistence getPersistence() { 1173 if (_persistence == null) { 1174 _persistence = (MBBanPersistence)PortalBeanLocatorUtil.locate(MBBanPersistence.class.getName()); 1175 1176 ReferenceRegistry.registerReference(MBBanUtil.class, "_persistence"); 1177 } 1178 1179 return _persistence; 1180 } 1181 1182 private static MBBanPersistence _persistence; 1183 }