001 /** 002 * Copyright (c) 2000-2012 Liferay, Inc. All rights reserved. 003 * 004 * This library is free software; you can redistribute it and/or modify it under 005 * the terms of the GNU Lesser General Public License as published by the Free 006 * Software Foundation; either version 2.1 of the License, or (at your option) 007 * any later version. 008 * 009 * This library is distributed in the hope that it will be useful, but WITHOUT 010 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS 011 * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more 012 * details. 013 */ 014 015 package com.liferay.portlet.messageboards.service.persistence; 016 017 import com.liferay.portal.service.persistence.BasePersistence; 018 019 import com.liferay.portlet.messageboards.model.MBBan; 020 021 /** 022 * The persistence interface for the message boards ban service. 023 * 024 * <p> 025 * Caching information and settings can be found in <code>portal.properties</code> 026 * </p> 027 * 028 * @author Brian Wing Shun Chan 029 * @see MBBanPersistenceImpl 030 * @see MBBanUtil 031 * @generated 032 */ 033 public interface MBBanPersistence extends BasePersistence<MBBan> { 034 /* 035 * NOTE FOR DEVELOPERS: 036 * 037 * Never modify or reference this interface directly. Always use {@link MBBanUtil} to access the message boards ban persistence. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this interface. 038 */ 039 040 /** 041 * Returns all the message boards bans where groupId = ?. 042 * 043 * @param groupId the group ID 044 * @return the matching message boards bans 045 * @throws SystemException if a system exception occurred 046 */ 047 public java.util.List<com.liferay.portlet.messageboards.model.MBBan> findByGroupId( 048 long groupId) 049 throws com.liferay.portal.kernel.exception.SystemException; 050 051 /** 052 * Returns a range of all the message boards bans where groupId = ?. 053 * 054 * <p> 055 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. 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 com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.messageboards.model.impl.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. 056 * </p> 057 * 058 * @param groupId the group ID 059 * @param start the lower bound of the range of message boards bans 060 * @param end the upper bound of the range of message boards bans (not inclusive) 061 * @return the range of matching message boards bans 062 * @throws SystemException if a system exception occurred 063 */ 064 public java.util.List<com.liferay.portlet.messageboards.model.MBBan> findByGroupId( 065 long groupId, int start, int end) 066 throws com.liferay.portal.kernel.exception.SystemException; 067 068 /** 069 * Returns an ordered range of all the message boards bans where groupId = ?. 070 * 071 * <p> 072 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. 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 com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.messageboards.model.impl.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. 073 * </p> 074 * 075 * @param groupId the group ID 076 * @param start the lower bound of the range of message boards bans 077 * @param end the upper bound of the range of message boards bans (not inclusive) 078 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 079 * @return the ordered range of matching message boards bans 080 * @throws SystemException if a system exception occurred 081 */ 082 public java.util.List<com.liferay.portlet.messageboards.model.MBBan> findByGroupId( 083 long groupId, int start, int end, 084 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 085 throws com.liferay.portal.kernel.exception.SystemException; 086 087 /** 088 * Returns the first message boards ban in the ordered set where groupId = ?. 089 * 090 * @param groupId the group ID 091 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 092 * @return the first matching message boards ban 093 * @throws com.liferay.portlet.messageboards.NoSuchBanException if a matching message boards ban could not be found 094 * @throws SystemException if a system exception occurred 095 */ 096 public com.liferay.portlet.messageboards.model.MBBan findByGroupId_First( 097 long groupId, 098 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 099 throws com.liferay.portal.kernel.exception.SystemException, 100 com.liferay.portlet.messageboards.NoSuchBanException; 101 102 /** 103 * Returns the first message boards ban in the ordered set where groupId = ?. 104 * 105 * @param groupId the group ID 106 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 107 * @return the first matching message boards ban, or <code>null</code> if a matching message boards ban could not be found 108 * @throws SystemException if a system exception occurred 109 */ 110 public com.liferay.portlet.messageboards.model.MBBan fetchByGroupId_First( 111 long groupId, 112 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 113 throws com.liferay.portal.kernel.exception.SystemException; 114 115 /** 116 * Returns the last message boards ban in the ordered set where groupId = ?. 117 * 118 * @param groupId the group ID 119 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 120 * @return the last matching message boards ban 121 * @throws com.liferay.portlet.messageboards.NoSuchBanException if a matching message boards ban could not be found 122 * @throws SystemException if a system exception occurred 123 */ 124 public com.liferay.portlet.messageboards.model.MBBan findByGroupId_Last( 125 long groupId, 126 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 127 throws com.liferay.portal.kernel.exception.SystemException, 128 com.liferay.portlet.messageboards.NoSuchBanException; 129 130 /** 131 * Returns the last message boards ban in the ordered set where groupId = ?. 132 * 133 * @param groupId the group ID 134 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 135 * @return the last matching message boards ban, or <code>null</code> if a matching message boards ban could not be found 136 * @throws SystemException if a system exception occurred 137 */ 138 public com.liferay.portlet.messageboards.model.MBBan fetchByGroupId_Last( 139 long groupId, 140 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 141 throws com.liferay.portal.kernel.exception.SystemException; 142 143 /** 144 * Returns the message boards bans before and after the current message boards ban in the ordered set where groupId = ?. 145 * 146 * @param banId the primary key of the current message boards ban 147 * @param groupId the group ID 148 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 149 * @return the previous, current, and next message boards ban 150 * @throws com.liferay.portlet.messageboards.NoSuchBanException if a message boards ban with the primary key could not be found 151 * @throws SystemException if a system exception occurred 152 */ 153 public com.liferay.portlet.messageboards.model.MBBan[] findByGroupId_PrevAndNext( 154 long banId, long groupId, 155 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 156 throws com.liferay.portal.kernel.exception.SystemException, 157 com.liferay.portlet.messageboards.NoSuchBanException; 158 159 /** 160 * Removes all the message boards bans where groupId = ? from the database. 161 * 162 * @param groupId the group ID 163 * @throws SystemException if a system exception occurred 164 */ 165 public void removeByGroupId(long groupId) 166 throws com.liferay.portal.kernel.exception.SystemException; 167 168 /** 169 * Returns the number of message boards bans where groupId = ?. 170 * 171 * @param groupId the group ID 172 * @return the number of matching message boards bans 173 * @throws SystemException if a system exception occurred 174 */ 175 public int countByGroupId(long groupId) 176 throws com.liferay.portal.kernel.exception.SystemException; 177 178 /** 179 * Returns all the message boards bans where userId = ?. 180 * 181 * @param userId the user ID 182 * @return the matching message boards bans 183 * @throws SystemException if a system exception occurred 184 */ 185 public java.util.List<com.liferay.portlet.messageboards.model.MBBan> findByUserId( 186 long userId) throws com.liferay.portal.kernel.exception.SystemException; 187 188 /** 189 * Returns a range of all the message boards bans where userId = ?. 190 * 191 * <p> 192 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. 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 com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.messageboards.model.impl.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. 193 * </p> 194 * 195 * @param userId the user ID 196 * @param start the lower bound of the range of message boards bans 197 * @param end the upper bound of the range of message boards bans (not inclusive) 198 * @return the range of matching message boards bans 199 * @throws SystemException if a system exception occurred 200 */ 201 public java.util.List<com.liferay.portlet.messageboards.model.MBBan> findByUserId( 202 long userId, int start, int end) 203 throws com.liferay.portal.kernel.exception.SystemException; 204 205 /** 206 * Returns an ordered range of all the message boards bans where userId = ?. 207 * 208 * <p> 209 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. 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 com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.messageboards.model.impl.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. 210 * </p> 211 * 212 * @param userId the user ID 213 * @param start the lower bound of the range of message boards bans 214 * @param end the upper bound of the range of message boards bans (not inclusive) 215 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 216 * @return the ordered range of matching message boards bans 217 * @throws SystemException if a system exception occurred 218 */ 219 public java.util.List<com.liferay.portlet.messageboards.model.MBBan> findByUserId( 220 long userId, int start, int end, 221 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 222 throws com.liferay.portal.kernel.exception.SystemException; 223 224 /** 225 * Returns the first message boards ban in the ordered set where userId = ?. 226 * 227 * @param userId the user ID 228 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 229 * @return the first matching message boards ban 230 * @throws com.liferay.portlet.messageboards.NoSuchBanException if a matching message boards ban could not be found 231 * @throws SystemException if a system exception occurred 232 */ 233 public com.liferay.portlet.messageboards.model.MBBan findByUserId_First( 234 long userId, 235 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 236 throws com.liferay.portal.kernel.exception.SystemException, 237 com.liferay.portlet.messageboards.NoSuchBanException; 238 239 /** 240 * Returns the first message boards ban in the ordered set where userId = ?. 241 * 242 * @param userId the user ID 243 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 244 * @return the first matching message boards ban, or <code>null</code> if a matching message boards ban could not be found 245 * @throws SystemException if a system exception occurred 246 */ 247 public com.liferay.portlet.messageboards.model.MBBan fetchByUserId_First( 248 long userId, 249 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 250 throws com.liferay.portal.kernel.exception.SystemException; 251 252 /** 253 * Returns the last message boards ban in the ordered set where userId = ?. 254 * 255 * @param userId the user ID 256 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 257 * @return the last matching message boards ban 258 * @throws com.liferay.portlet.messageboards.NoSuchBanException if a matching message boards ban could not be found 259 * @throws SystemException if a system exception occurred 260 */ 261 public com.liferay.portlet.messageboards.model.MBBan findByUserId_Last( 262 long userId, 263 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 264 throws com.liferay.portal.kernel.exception.SystemException, 265 com.liferay.portlet.messageboards.NoSuchBanException; 266 267 /** 268 * Returns the last message boards ban in the ordered set where userId = ?. 269 * 270 * @param userId the user ID 271 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 272 * @return the last matching message boards ban, or <code>null</code> if a matching message boards ban could not be found 273 * @throws SystemException if a system exception occurred 274 */ 275 public com.liferay.portlet.messageboards.model.MBBan fetchByUserId_Last( 276 long userId, 277 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 278 throws com.liferay.portal.kernel.exception.SystemException; 279 280 /** 281 * Returns the message boards bans before and after the current message boards ban in the ordered set where userId = ?. 282 * 283 * @param banId the primary key of the current message boards ban 284 * @param userId the user ID 285 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 286 * @return the previous, current, and next message boards ban 287 * @throws com.liferay.portlet.messageboards.NoSuchBanException if a message boards ban with the primary key could not be found 288 * @throws SystemException if a system exception occurred 289 */ 290 public com.liferay.portlet.messageboards.model.MBBan[] findByUserId_PrevAndNext( 291 long banId, long userId, 292 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 293 throws com.liferay.portal.kernel.exception.SystemException, 294 com.liferay.portlet.messageboards.NoSuchBanException; 295 296 /** 297 * Removes all the message boards bans where userId = ? from the database. 298 * 299 * @param userId the user ID 300 * @throws SystemException if a system exception occurred 301 */ 302 public void removeByUserId(long userId) 303 throws com.liferay.portal.kernel.exception.SystemException; 304 305 /** 306 * Returns the number of message boards bans where userId = ?. 307 * 308 * @param userId the user ID 309 * @return the number of matching message boards bans 310 * @throws SystemException if a system exception occurred 311 */ 312 public int countByUserId(long userId) 313 throws com.liferay.portal.kernel.exception.SystemException; 314 315 /** 316 * Returns all the message boards bans where banUserId = ?. 317 * 318 * @param banUserId the ban user ID 319 * @return the matching message boards bans 320 * @throws SystemException if a system exception occurred 321 */ 322 public java.util.List<com.liferay.portlet.messageboards.model.MBBan> findByBanUserId( 323 long banUserId) 324 throws com.liferay.portal.kernel.exception.SystemException; 325 326 /** 327 * Returns a range of all the message boards bans where banUserId = ?. 328 * 329 * <p> 330 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. 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 com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.messageboards.model.impl.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. 331 * </p> 332 * 333 * @param banUserId the ban user ID 334 * @param start the lower bound of the range of message boards bans 335 * @param end the upper bound of the range of message boards bans (not inclusive) 336 * @return the range of matching message boards bans 337 * @throws SystemException if a system exception occurred 338 */ 339 public java.util.List<com.liferay.portlet.messageboards.model.MBBan> findByBanUserId( 340 long banUserId, int start, int end) 341 throws com.liferay.portal.kernel.exception.SystemException; 342 343 /** 344 * Returns an ordered range of all the message boards bans where banUserId = ?. 345 * 346 * <p> 347 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. 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 com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.messageboards.model.impl.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. 348 * </p> 349 * 350 * @param banUserId the ban user ID 351 * @param start the lower bound of the range of message boards bans 352 * @param end the upper bound of the range of message boards bans (not inclusive) 353 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 354 * @return the ordered range of matching message boards bans 355 * @throws SystemException if a system exception occurred 356 */ 357 public java.util.List<com.liferay.portlet.messageboards.model.MBBan> findByBanUserId( 358 long banUserId, int start, int end, 359 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 360 throws com.liferay.portal.kernel.exception.SystemException; 361 362 /** 363 * Returns the first message boards ban in the ordered set where banUserId = ?. 364 * 365 * @param banUserId the ban user ID 366 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 367 * @return the first matching message boards ban 368 * @throws com.liferay.portlet.messageboards.NoSuchBanException if a matching message boards ban could not be found 369 * @throws SystemException if a system exception occurred 370 */ 371 public com.liferay.portlet.messageboards.model.MBBan findByBanUserId_First( 372 long banUserId, 373 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 374 throws com.liferay.portal.kernel.exception.SystemException, 375 com.liferay.portlet.messageboards.NoSuchBanException; 376 377 /** 378 * Returns the first message boards ban in the ordered set where banUserId = ?. 379 * 380 * @param banUserId the ban user ID 381 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 382 * @return the first matching message boards ban, or <code>null</code> if a matching message boards ban could not be found 383 * @throws SystemException if a system exception occurred 384 */ 385 public com.liferay.portlet.messageboards.model.MBBan fetchByBanUserId_First( 386 long banUserId, 387 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 388 throws com.liferay.portal.kernel.exception.SystemException; 389 390 /** 391 * Returns the last message boards ban in the ordered set where banUserId = ?. 392 * 393 * @param banUserId the ban user ID 394 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 395 * @return the last matching message boards ban 396 * @throws com.liferay.portlet.messageboards.NoSuchBanException if a matching message boards ban could not be found 397 * @throws SystemException if a system exception occurred 398 */ 399 public com.liferay.portlet.messageboards.model.MBBan findByBanUserId_Last( 400 long banUserId, 401 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 402 throws com.liferay.portal.kernel.exception.SystemException, 403 com.liferay.portlet.messageboards.NoSuchBanException; 404 405 /** 406 * Returns the last message boards ban in the ordered set where banUserId = ?. 407 * 408 * @param banUserId the ban user ID 409 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 410 * @return the last matching message boards ban, or <code>null</code> if a matching message boards ban could not be found 411 * @throws SystemException if a system exception occurred 412 */ 413 public com.liferay.portlet.messageboards.model.MBBan fetchByBanUserId_Last( 414 long banUserId, 415 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 416 throws com.liferay.portal.kernel.exception.SystemException; 417 418 /** 419 * Returns the message boards bans before and after the current message boards ban in the ordered set where banUserId = ?. 420 * 421 * @param banId the primary key of the current message boards ban 422 * @param banUserId the ban user ID 423 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 424 * @return the previous, current, and next message boards ban 425 * @throws com.liferay.portlet.messageboards.NoSuchBanException if a message boards ban with the primary key could not be found 426 * @throws SystemException if a system exception occurred 427 */ 428 public com.liferay.portlet.messageboards.model.MBBan[] findByBanUserId_PrevAndNext( 429 long banId, long banUserId, 430 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 431 throws com.liferay.portal.kernel.exception.SystemException, 432 com.liferay.portlet.messageboards.NoSuchBanException; 433 434 /** 435 * Removes all the message boards bans where banUserId = ? from the database. 436 * 437 * @param banUserId the ban user ID 438 * @throws SystemException if a system exception occurred 439 */ 440 public void removeByBanUserId(long banUserId) 441 throws com.liferay.portal.kernel.exception.SystemException; 442 443 /** 444 * Returns the number of message boards bans where banUserId = ?. 445 * 446 * @param banUserId the ban user ID 447 * @return the number of matching message boards bans 448 * @throws SystemException if a system exception occurred 449 */ 450 public int countByBanUserId(long banUserId) 451 throws com.liferay.portal.kernel.exception.SystemException; 452 453 /** 454 * Returns the message boards ban where groupId = ? and banUserId = ? or throws a {@link com.liferay.portlet.messageboards.NoSuchBanException} if it could not be found. 455 * 456 * @param groupId the group ID 457 * @param banUserId the ban user ID 458 * @return the matching message boards ban 459 * @throws com.liferay.portlet.messageboards.NoSuchBanException if a matching message boards ban could not be found 460 * @throws SystemException if a system exception occurred 461 */ 462 public com.liferay.portlet.messageboards.model.MBBan findByG_B( 463 long groupId, long banUserId) 464 throws com.liferay.portal.kernel.exception.SystemException, 465 com.liferay.portlet.messageboards.NoSuchBanException; 466 467 /** 468 * Returns the message boards ban where groupId = ? and banUserId = ? or returns <code>null</code> if it could not be found. Uses the finder cache. 469 * 470 * @param groupId the group ID 471 * @param banUserId the ban user ID 472 * @return the matching message boards ban, or <code>null</code> if a matching message boards ban could not be found 473 * @throws SystemException if a system exception occurred 474 */ 475 public com.liferay.portlet.messageboards.model.MBBan fetchByG_B( 476 long groupId, long banUserId) 477 throws com.liferay.portal.kernel.exception.SystemException; 478 479 /** 480 * 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. 481 * 482 * @param groupId the group ID 483 * @param banUserId the ban user ID 484 * @param retrieveFromCache whether to use the finder cache 485 * @return the matching message boards ban, or <code>null</code> if a matching message boards ban could not be found 486 * @throws SystemException if a system exception occurred 487 */ 488 public com.liferay.portlet.messageboards.model.MBBan fetchByG_B( 489 long groupId, long banUserId, boolean retrieveFromCache) 490 throws com.liferay.portal.kernel.exception.SystemException; 491 492 /** 493 * Removes the message boards ban where groupId = ? and banUserId = ? from the database. 494 * 495 * @param groupId the group ID 496 * @param banUserId the ban user ID 497 * @return the message boards ban that was removed 498 * @throws SystemException if a system exception occurred 499 */ 500 public com.liferay.portlet.messageboards.model.MBBan removeByG_B( 501 long groupId, long banUserId) 502 throws com.liferay.portal.kernel.exception.SystemException, 503 com.liferay.portlet.messageboards.NoSuchBanException; 504 505 /** 506 * Returns the number of message boards bans where groupId = ? and banUserId = ?. 507 * 508 * @param groupId the group ID 509 * @param banUserId the ban user ID 510 * @return the number of matching message boards bans 511 * @throws SystemException if a system exception occurred 512 */ 513 public int countByG_B(long groupId, long banUserId) 514 throws com.liferay.portal.kernel.exception.SystemException; 515 516 /** 517 * Caches the message boards ban in the entity cache if it is enabled. 518 * 519 * @param mbBan the message boards ban 520 */ 521 public void cacheResult(com.liferay.portlet.messageboards.model.MBBan mbBan); 522 523 /** 524 * Caches the message boards bans in the entity cache if it is enabled. 525 * 526 * @param mbBans the message boards bans 527 */ 528 public void cacheResult( 529 java.util.List<com.liferay.portlet.messageboards.model.MBBan> mbBans); 530 531 /** 532 * Creates a new message boards ban with the primary key. Does not add the message boards ban to the database. 533 * 534 * @param banId the primary key for the new message boards ban 535 * @return the new message boards ban 536 */ 537 public com.liferay.portlet.messageboards.model.MBBan create(long banId); 538 539 /** 540 * Removes the message boards ban with the primary key from the database. Also notifies the appropriate model listeners. 541 * 542 * @param banId the primary key of the message boards ban 543 * @return the message boards ban that was removed 544 * @throws com.liferay.portlet.messageboards.NoSuchBanException if a message boards ban with the primary key could not be found 545 * @throws SystemException if a system exception occurred 546 */ 547 public com.liferay.portlet.messageboards.model.MBBan remove(long banId) 548 throws com.liferay.portal.kernel.exception.SystemException, 549 com.liferay.portlet.messageboards.NoSuchBanException; 550 551 public com.liferay.portlet.messageboards.model.MBBan updateImpl( 552 com.liferay.portlet.messageboards.model.MBBan mbBan) 553 throws com.liferay.portal.kernel.exception.SystemException; 554 555 /** 556 * Returns the message boards ban with the primary key or throws a {@link com.liferay.portlet.messageboards.NoSuchBanException} if it could not be found. 557 * 558 * @param banId the primary key of the message boards ban 559 * @return the message boards ban 560 * @throws com.liferay.portlet.messageboards.NoSuchBanException if a message boards ban with the primary key could not be found 561 * @throws SystemException if a system exception occurred 562 */ 563 public com.liferay.portlet.messageboards.model.MBBan findByPrimaryKey( 564 long banId) 565 throws com.liferay.portal.kernel.exception.SystemException, 566 com.liferay.portlet.messageboards.NoSuchBanException; 567 568 /** 569 * Returns the message boards ban with the primary key or returns <code>null</code> if it could not be found. 570 * 571 * @param banId the primary key of the message boards ban 572 * @return the message boards ban, or <code>null</code> if a message boards ban with the primary key could not be found 573 * @throws SystemException if a system exception occurred 574 */ 575 public com.liferay.portlet.messageboards.model.MBBan fetchByPrimaryKey( 576 long banId) throws com.liferay.portal.kernel.exception.SystemException; 577 578 /** 579 * Returns all the message boards bans. 580 * 581 * @return the message boards bans 582 * @throws SystemException if a system exception occurred 583 */ 584 public java.util.List<com.liferay.portlet.messageboards.model.MBBan> findAll() 585 throws com.liferay.portal.kernel.exception.SystemException; 586 587 /** 588 * Returns a range of all the message boards bans. 589 * 590 * <p> 591 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. 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 com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.messageboards.model.impl.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. 592 * </p> 593 * 594 * @param start the lower bound of the range of message boards bans 595 * @param end the upper bound of the range of message boards bans (not inclusive) 596 * @return the range of message boards bans 597 * @throws SystemException if a system exception occurred 598 */ 599 public java.util.List<com.liferay.portlet.messageboards.model.MBBan> findAll( 600 int start, int end) 601 throws com.liferay.portal.kernel.exception.SystemException; 602 603 /** 604 * Returns an ordered range of all the message boards bans. 605 * 606 * <p> 607 * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set. 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 com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS}), then the query will include the default ORDER BY logic from {@link com.liferay.portlet.messageboards.model.impl.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. 608 * </p> 609 * 610 * @param start the lower bound of the range of message boards bans 611 * @param end the upper bound of the range of message boards bans (not inclusive) 612 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 613 * @return the ordered range of message boards bans 614 * @throws SystemException if a system exception occurred 615 */ 616 public java.util.List<com.liferay.portlet.messageboards.model.MBBan> findAll( 617 int start, int end, 618 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 619 throws com.liferay.portal.kernel.exception.SystemException; 620 621 /** 622 * Removes all the message boards bans from the database. 623 * 624 * @throws SystemException if a system exception occurred 625 */ 626 public void removeAll() 627 throws com.liferay.portal.kernel.exception.SystemException; 628 629 /** 630 * Returns the number of message boards bans. 631 * 632 * @return the number of message boards bans 633 * @throws SystemException if a system exception occurred 634 */ 635 public int countAll() 636 throws com.liferay.portal.kernel.exception.SystemException; 637 }