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.service.persistence.BasePersistence; 020 021 import com.liferay.portlet.messageboards.model.MBThreadFlag; 022 023 /** 024 * The persistence interface for the message boards thread flag service. 025 * 026 * <p> 027 * Caching information and settings can be found in <code>portal.properties</code> 028 * </p> 029 * 030 * @author Brian Wing Shun Chan 031 * @see com.liferay.portlet.messageboards.service.persistence.impl.MBThreadFlagPersistenceImpl 032 * @see MBThreadFlagUtil 033 * @generated 034 */ 035 @ProviderType 036 public interface MBThreadFlagPersistence extends BasePersistence<MBThreadFlag> { 037 /* 038 * NOTE FOR DEVELOPERS: 039 * 040 * Never modify or reference this interface directly. Always use {@link MBThreadFlagUtil} to access the message boards thread flag persistence. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this interface. 041 */ 042 043 /** 044 * Returns all the message boards thread flags where uuid = ?. 045 * 046 * @param uuid the uuid 047 * @return the matching message boards thread flags 048 */ 049 public java.util.List<MBThreadFlag> findByUuid(java.lang.String uuid); 050 051 /** 052 * Returns a range of all the message boards thread flags where uuid = ?. 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 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 MBThreadFlagModelImpl}. 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 uuid the uuid 059 * @param start the lower bound of the range of message boards thread flags 060 * @param end the upper bound of the range of message boards thread flags (not inclusive) 061 * @return the range of matching message boards thread flags 062 */ 063 public java.util.List<MBThreadFlag> findByUuid(java.lang.String uuid, 064 int start, int end); 065 066 /** 067 * Returns an ordered range of all the message boards thread flags where uuid = ?. 068 * 069 * <p> 070 * 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 MBThreadFlagModelImpl}. 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. 071 * </p> 072 * 073 * @param uuid the uuid 074 * @param start the lower bound of the range of message boards thread flags 075 * @param end the upper bound of the range of message boards thread flags (not inclusive) 076 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 077 * @return the ordered range of matching message boards thread flags 078 */ 079 public java.util.List<MBThreadFlag> findByUuid(java.lang.String uuid, 080 int start, int end, 081 com.liferay.portal.kernel.util.OrderByComparator<MBThreadFlag> orderByComparator); 082 083 /** 084 * Returns the first message boards thread flag in the ordered set where uuid = ?. 085 * 086 * @param uuid the uuid 087 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 088 * @return the first matching message boards thread flag 089 * @throws NoSuchThreadFlagException if a matching message boards thread flag could not be found 090 */ 091 public MBThreadFlag findByUuid_First(java.lang.String uuid, 092 com.liferay.portal.kernel.util.OrderByComparator<MBThreadFlag> orderByComparator) 093 throws com.liferay.portlet.messageboards.NoSuchThreadFlagException; 094 095 /** 096 * Returns the first message boards thread flag in the ordered set where uuid = ?. 097 * 098 * @param uuid the uuid 099 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 100 * @return the first matching message boards thread flag, or <code>null</code> if a matching message boards thread flag could not be found 101 */ 102 public MBThreadFlag fetchByUuid_First(java.lang.String uuid, 103 com.liferay.portal.kernel.util.OrderByComparator<MBThreadFlag> orderByComparator); 104 105 /** 106 * Returns the last message boards thread flag in the ordered set where uuid = ?. 107 * 108 * @param uuid the uuid 109 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 110 * @return the last matching message boards thread flag 111 * @throws NoSuchThreadFlagException if a matching message boards thread flag could not be found 112 */ 113 public MBThreadFlag findByUuid_Last(java.lang.String uuid, 114 com.liferay.portal.kernel.util.OrderByComparator<MBThreadFlag> orderByComparator) 115 throws com.liferay.portlet.messageboards.NoSuchThreadFlagException; 116 117 /** 118 * Returns the last message boards thread flag in the ordered set where uuid = ?. 119 * 120 * @param uuid the uuid 121 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 122 * @return the last matching message boards thread flag, or <code>null</code> if a matching message boards thread flag could not be found 123 */ 124 public MBThreadFlag fetchByUuid_Last(java.lang.String uuid, 125 com.liferay.portal.kernel.util.OrderByComparator<MBThreadFlag> orderByComparator); 126 127 /** 128 * Returns the message boards thread flags before and after the current message boards thread flag in the ordered set where uuid = ?. 129 * 130 * @param threadFlagId the primary key of the current message boards thread flag 131 * @param uuid the uuid 132 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 133 * @return the previous, current, and next message boards thread flag 134 * @throws NoSuchThreadFlagException if a message boards thread flag with the primary key could not be found 135 */ 136 public MBThreadFlag[] findByUuid_PrevAndNext(long threadFlagId, 137 java.lang.String uuid, 138 com.liferay.portal.kernel.util.OrderByComparator<MBThreadFlag> orderByComparator) 139 throws com.liferay.portlet.messageboards.NoSuchThreadFlagException; 140 141 /** 142 * Removes all the message boards thread flags where uuid = ? from the database. 143 * 144 * @param uuid the uuid 145 */ 146 public void removeByUuid(java.lang.String uuid); 147 148 /** 149 * Returns the number of message boards thread flags where uuid = ?. 150 * 151 * @param uuid the uuid 152 * @return the number of matching message boards thread flags 153 */ 154 public int countByUuid(java.lang.String uuid); 155 156 /** 157 * Returns the message boards thread flag where uuid = ? and groupId = ? or throws a {@link NoSuchThreadFlagException} if it could not be found. 158 * 159 * @param uuid the uuid 160 * @param groupId the group ID 161 * @return the matching message boards thread flag 162 * @throws NoSuchThreadFlagException if a matching message boards thread flag could not be found 163 */ 164 public MBThreadFlag findByUUID_G(java.lang.String uuid, long groupId) 165 throws com.liferay.portlet.messageboards.NoSuchThreadFlagException; 166 167 /** 168 * Returns the message boards thread flag where uuid = ? and groupId = ? or returns <code>null</code> if it could not be found. Uses the finder cache. 169 * 170 * @param uuid the uuid 171 * @param groupId the group ID 172 * @return the matching message boards thread flag, or <code>null</code> if a matching message boards thread flag could not be found 173 */ 174 public MBThreadFlag fetchByUUID_G(java.lang.String uuid, long groupId); 175 176 /** 177 * Returns the message boards thread flag where uuid = ? and groupId = ? or returns <code>null</code> if it could not be found, optionally using the finder cache. 178 * 179 * @param uuid the uuid 180 * @param groupId the group ID 181 * @param retrieveFromCache whether to use the finder cache 182 * @return the matching message boards thread flag, or <code>null</code> if a matching message boards thread flag could not be found 183 */ 184 public MBThreadFlag fetchByUUID_G(java.lang.String uuid, long groupId, 185 boolean retrieveFromCache); 186 187 /** 188 * Removes the message boards thread flag where uuid = ? and groupId = ? from the database. 189 * 190 * @param uuid the uuid 191 * @param groupId the group ID 192 * @return the message boards thread flag that was removed 193 */ 194 public MBThreadFlag removeByUUID_G(java.lang.String uuid, long groupId) 195 throws com.liferay.portlet.messageboards.NoSuchThreadFlagException; 196 197 /** 198 * Returns the number of message boards thread flags where uuid = ? and groupId = ?. 199 * 200 * @param uuid the uuid 201 * @param groupId the group ID 202 * @return the number of matching message boards thread flags 203 */ 204 public int countByUUID_G(java.lang.String uuid, long groupId); 205 206 /** 207 * Returns all the message boards thread flags where uuid = ? and companyId = ?. 208 * 209 * @param uuid the uuid 210 * @param companyId the company ID 211 * @return the matching message boards thread flags 212 */ 213 public java.util.List<MBThreadFlag> findByUuid_C(java.lang.String uuid, 214 long companyId); 215 216 /** 217 * Returns a range of all the message boards thread flags where uuid = ? and companyId = ?. 218 * 219 * <p> 220 * 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 MBThreadFlagModelImpl}. 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. 221 * </p> 222 * 223 * @param uuid the uuid 224 * @param companyId the company ID 225 * @param start the lower bound of the range of message boards thread flags 226 * @param end the upper bound of the range of message boards thread flags (not inclusive) 227 * @return the range of matching message boards thread flags 228 */ 229 public java.util.List<MBThreadFlag> findByUuid_C(java.lang.String uuid, 230 long companyId, int start, int end); 231 232 /** 233 * Returns an ordered range of all the message boards thread flags where uuid = ? and companyId = ?. 234 * 235 * <p> 236 * 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 MBThreadFlagModelImpl}. 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. 237 * </p> 238 * 239 * @param uuid the uuid 240 * @param companyId the company ID 241 * @param start the lower bound of the range of message boards thread flags 242 * @param end the upper bound of the range of message boards thread flags (not inclusive) 243 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 244 * @return the ordered range of matching message boards thread flags 245 */ 246 public java.util.List<MBThreadFlag> findByUuid_C(java.lang.String uuid, 247 long companyId, int start, int end, 248 com.liferay.portal.kernel.util.OrderByComparator<MBThreadFlag> orderByComparator); 249 250 /** 251 * Returns the first message boards thread flag in the ordered set where uuid = ? and companyId = ?. 252 * 253 * @param uuid the uuid 254 * @param companyId the company ID 255 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 256 * @return the first matching message boards thread flag 257 * @throws NoSuchThreadFlagException if a matching message boards thread flag could not be found 258 */ 259 public MBThreadFlag findByUuid_C_First(java.lang.String uuid, 260 long companyId, 261 com.liferay.portal.kernel.util.OrderByComparator<MBThreadFlag> orderByComparator) 262 throws com.liferay.portlet.messageboards.NoSuchThreadFlagException; 263 264 /** 265 * Returns the first message boards thread flag in the ordered set where uuid = ? and companyId = ?. 266 * 267 * @param uuid the uuid 268 * @param companyId the company ID 269 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 270 * @return the first matching message boards thread flag, or <code>null</code> if a matching message boards thread flag could not be found 271 */ 272 public MBThreadFlag fetchByUuid_C_First(java.lang.String uuid, 273 long companyId, 274 com.liferay.portal.kernel.util.OrderByComparator<MBThreadFlag> orderByComparator); 275 276 /** 277 * Returns the last message boards thread flag in the ordered set where uuid = ? and companyId = ?. 278 * 279 * @param uuid the uuid 280 * @param companyId the company ID 281 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 282 * @return the last matching message boards thread flag 283 * @throws NoSuchThreadFlagException if a matching message boards thread flag could not be found 284 */ 285 public MBThreadFlag findByUuid_C_Last(java.lang.String uuid, 286 long companyId, 287 com.liferay.portal.kernel.util.OrderByComparator<MBThreadFlag> orderByComparator) 288 throws com.liferay.portlet.messageboards.NoSuchThreadFlagException; 289 290 /** 291 * Returns the last message boards thread flag in the ordered set where uuid = ? and companyId = ?. 292 * 293 * @param uuid the uuid 294 * @param companyId the company ID 295 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 296 * @return the last matching message boards thread flag, or <code>null</code> if a matching message boards thread flag could not be found 297 */ 298 public MBThreadFlag fetchByUuid_C_Last(java.lang.String uuid, 299 long companyId, 300 com.liferay.portal.kernel.util.OrderByComparator<MBThreadFlag> orderByComparator); 301 302 /** 303 * Returns the message boards thread flags before and after the current message boards thread flag in the ordered set where uuid = ? and companyId = ?. 304 * 305 * @param threadFlagId the primary key of the current message boards thread flag 306 * @param uuid the uuid 307 * @param companyId the company ID 308 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 309 * @return the previous, current, and next message boards thread flag 310 * @throws NoSuchThreadFlagException if a message boards thread flag with the primary key could not be found 311 */ 312 public MBThreadFlag[] findByUuid_C_PrevAndNext(long threadFlagId, 313 java.lang.String uuid, long companyId, 314 com.liferay.portal.kernel.util.OrderByComparator<MBThreadFlag> orderByComparator) 315 throws com.liferay.portlet.messageboards.NoSuchThreadFlagException; 316 317 /** 318 * Removes all the message boards thread flags where uuid = ? and companyId = ? from the database. 319 * 320 * @param uuid the uuid 321 * @param companyId the company ID 322 */ 323 public void removeByUuid_C(java.lang.String uuid, long companyId); 324 325 /** 326 * Returns the number of message boards thread flags where uuid = ? and companyId = ?. 327 * 328 * @param uuid the uuid 329 * @param companyId the company ID 330 * @return the number of matching message boards thread flags 331 */ 332 public int countByUuid_C(java.lang.String uuid, long companyId); 333 334 /** 335 * Returns all the message boards thread flags where userId = ?. 336 * 337 * @param userId the user ID 338 * @return the matching message boards thread flags 339 */ 340 public java.util.List<MBThreadFlag> findByUserId(long userId); 341 342 /** 343 * Returns a range of all the message boards thread flags where userId = ?. 344 * 345 * <p> 346 * 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 MBThreadFlagModelImpl}. 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. 347 * </p> 348 * 349 * @param userId the user ID 350 * @param start the lower bound of the range of message boards thread flags 351 * @param end the upper bound of the range of message boards thread flags (not inclusive) 352 * @return the range of matching message boards thread flags 353 */ 354 public java.util.List<MBThreadFlag> findByUserId(long userId, int start, 355 int end); 356 357 /** 358 * Returns an ordered range of all the message boards thread flags where userId = ?. 359 * 360 * <p> 361 * 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 MBThreadFlagModelImpl}. 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. 362 * </p> 363 * 364 * @param userId the user ID 365 * @param start the lower bound of the range of message boards thread flags 366 * @param end the upper bound of the range of message boards thread flags (not inclusive) 367 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 368 * @return the ordered range of matching message boards thread flags 369 */ 370 public java.util.List<MBThreadFlag> findByUserId(long userId, int start, 371 int end, 372 com.liferay.portal.kernel.util.OrderByComparator<MBThreadFlag> orderByComparator); 373 374 /** 375 * Returns the first message boards thread flag in the ordered set where userId = ?. 376 * 377 * @param userId the user ID 378 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 379 * @return the first matching message boards thread flag 380 * @throws NoSuchThreadFlagException if a matching message boards thread flag could not be found 381 */ 382 public MBThreadFlag findByUserId_First(long userId, 383 com.liferay.portal.kernel.util.OrderByComparator<MBThreadFlag> orderByComparator) 384 throws com.liferay.portlet.messageboards.NoSuchThreadFlagException; 385 386 /** 387 * Returns the first message boards thread flag in the ordered set where userId = ?. 388 * 389 * @param userId the user ID 390 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 391 * @return the first matching message boards thread flag, or <code>null</code> if a matching message boards thread flag could not be found 392 */ 393 public MBThreadFlag fetchByUserId_First(long userId, 394 com.liferay.portal.kernel.util.OrderByComparator<MBThreadFlag> orderByComparator); 395 396 /** 397 * Returns the last message boards thread flag in the ordered set where userId = ?. 398 * 399 * @param userId the user ID 400 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 401 * @return the last matching message boards thread flag 402 * @throws NoSuchThreadFlagException if a matching message boards thread flag could not be found 403 */ 404 public MBThreadFlag findByUserId_Last(long userId, 405 com.liferay.portal.kernel.util.OrderByComparator<MBThreadFlag> orderByComparator) 406 throws com.liferay.portlet.messageboards.NoSuchThreadFlagException; 407 408 /** 409 * Returns the last message boards thread flag in the ordered set where userId = ?. 410 * 411 * @param userId the user ID 412 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 413 * @return the last matching message boards thread flag, or <code>null</code> if a matching message boards thread flag could not be found 414 */ 415 public MBThreadFlag fetchByUserId_Last(long userId, 416 com.liferay.portal.kernel.util.OrderByComparator<MBThreadFlag> orderByComparator); 417 418 /** 419 * Returns the message boards thread flags before and after the current message boards thread flag in the ordered set where userId = ?. 420 * 421 * @param threadFlagId the primary key of the current message boards thread flag 422 * @param userId the 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 thread flag 425 * @throws NoSuchThreadFlagException if a message boards thread flag with the primary key could not be found 426 */ 427 public MBThreadFlag[] findByUserId_PrevAndNext(long threadFlagId, 428 long userId, 429 com.liferay.portal.kernel.util.OrderByComparator<MBThreadFlag> orderByComparator) 430 throws com.liferay.portlet.messageboards.NoSuchThreadFlagException; 431 432 /** 433 * Removes all the message boards thread flags where userId = ? from the database. 434 * 435 * @param userId the user ID 436 */ 437 public void removeByUserId(long userId); 438 439 /** 440 * Returns the number of message boards thread flags where userId = ?. 441 * 442 * @param userId the user ID 443 * @return the number of matching message boards thread flags 444 */ 445 public int countByUserId(long userId); 446 447 /** 448 * Returns all the message boards thread flags where threadId = ?. 449 * 450 * @param threadId the thread ID 451 * @return the matching message boards thread flags 452 */ 453 public java.util.List<MBThreadFlag> findByThreadId(long threadId); 454 455 /** 456 * Returns a range of all the message boards thread flags where threadId = ?. 457 * 458 * <p> 459 * 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 MBThreadFlagModelImpl}. 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. 460 * </p> 461 * 462 * @param threadId the thread ID 463 * @param start the lower bound of the range of message boards thread flags 464 * @param end the upper bound of the range of message boards thread flags (not inclusive) 465 * @return the range of matching message boards thread flags 466 */ 467 public java.util.List<MBThreadFlag> findByThreadId(long threadId, 468 int start, int end); 469 470 /** 471 * Returns an ordered range of all the message boards thread flags where threadId = ?. 472 * 473 * <p> 474 * 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 MBThreadFlagModelImpl}. 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. 475 * </p> 476 * 477 * @param threadId the thread ID 478 * @param start the lower bound of the range of message boards thread flags 479 * @param end the upper bound of the range of message boards thread flags (not inclusive) 480 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 481 * @return the ordered range of matching message boards thread flags 482 */ 483 public java.util.List<MBThreadFlag> findByThreadId(long threadId, 484 int start, int end, 485 com.liferay.portal.kernel.util.OrderByComparator<MBThreadFlag> orderByComparator); 486 487 /** 488 * Returns the first message boards thread flag in the ordered set where threadId = ?. 489 * 490 * @param threadId the thread ID 491 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 492 * @return the first matching message boards thread flag 493 * @throws NoSuchThreadFlagException if a matching message boards thread flag could not be found 494 */ 495 public MBThreadFlag findByThreadId_First(long threadId, 496 com.liferay.portal.kernel.util.OrderByComparator<MBThreadFlag> orderByComparator) 497 throws com.liferay.portlet.messageboards.NoSuchThreadFlagException; 498 499 /** 500 * Returns the first message boards thread flag in the ordered set where threadId = ?. 501 * 502 * @param threadId the thread ID 503 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 504 * @return the first matching message boards thread flag, or <code>null</code> if a matching message boards thread flag could not be found 505 */ 506 public MBThreadFlag fetchByThreadId_First(long threadId, 507 com.liferay.portal.kernel.util.OrderByComparator<MBThreadFlag> orderByComparator); 508 509 /** 510 * Returns the last message boards thread flag in the ordered set where threadId = ?. 511 * 512 * @param threadId the thread ID 513 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 514 * @return the last matching message boards thread flag 515 * @throws NoSuchThreadFlagException if a matching message boards thread flag could not be found 516 */ 517 public MBThreadFlag findByThreadId_Last(long threadId, 518 com.liferay.portal.kernel.util.OrderByComparator<MBThreadFlag> orderByComparator) 519 throws com.liferay.portlet.messageboards.NoSuchThreadFlagException; 520 521 /** 522 * Returns the last message boards thread flag in the ordered set where threadId = ?. 523 * 524 * @param threadId the thread ID 525 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 526 * @return the last matching message boards thread flag, or <code>null</code> if a matching message boards thread flag could not be found 527 */ 528 public MBThreadFlag fetchByThreadId_Last(long threadId, 529 com.liferay.portal.kernel.util.OrderByComparator<MBThreadFlag> orderByComparator); 530 531 /** 532 * Returns the message boards thread flags before and after the current message boards thread flag in the ordered set where threadId = ?. 533 * 534 * @param threadFlagId the primary key of the current message boards thread flag 535 * @param threadId the thread ID 536 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 537 * @return the previous, current, and next message boards thread flag 538 * @throws NoSuchThreadFlagException if a message boards thread flag with the primary key could not be found 539 */ 540 public MBThreadFlag[] findByThreadId_PrevAndNext(long threadFlagId, 541 long threadId, 542 com.liferay.portal.kernel.util.OrderByComparator<MBThreadFlag> orderByComparator) 543 throws com.liferay.portlet.messageboards.NoSuchThreadFlagException; 544 545 /** 546 * Removes all the message boards thread flags where threadId = ? from the database. 547 * 548 * @param threadId the thread ID 549 */ 550 public void removeByThreadId(long threadId); 551 552 /** 553 * Returns the number of message boards thread flags where threadId = ?. 554 * 555 * @param threadId the thread ID 556 * @return the number of matching message boards thread flags 557 */ 558 public int countByThreadId(long threadId); 559 560 /** 561 * Returns the message boards thread flag where userId = ? and threadId = ? or throws a {@link NoSuchThreadFlagException} if it could not be found. 562 * 563 * @param userId the user ID 564 * @param threadId the thread ID 565 * @return the matching message boards thread flag 566 * @throws NoSuchThreadFlagException if a matching message boards thread flag could not be found 567 */ 568 public MBThreadFlag findByU_T(long userId, long threadId) 569 throws com.liferay.portlet.messageboards.NoSuchThreadFlagException; 570 571 /** 572 * Returns the message boards thread flag where userId = ? and threadId = ? or returns <code>null</code> if it could not be found. Uses the finder cache. 573 * 574 * @param userId the user ID 575 * @param threadId the thread ID 576 * @return the matching message boards thread flag, or <code>null</code> if a matching message boards thread flag could not be found 577 */ 578 public MBThreadFlag fetchByU_T(long userId, long threadId); 579 580 /** 581 * Returns the message boards thread flag where userId = ? and threadId = ? or returns <code>null</code> if it could not be found, optionally using the finder cache. 582 * 583 * @param userId the user ID 584 * @param threadId the thread ID 585 * @param retrieveFromCache whether to use the finder cache 586 * @return the matching message boards thread flag, or <code>null</code> if a matching message boards thread flag could not be found 587 */ 588 public MBThreadFlag fetchByU_T(long userId, long threadId, 589 boolean retrieveFromCache); 590 591 /** 592 * Removes the message boards thread flag where userId = ? and threadId = ? from the database. 593 * 594 * @param userId the user ID 595 * @param threadId the thread ID 596 * @return the message boards thread flag that was removed 597 */ 598 public MBThreadFlag removeByU_T(long userId, long threadId) 599 throws com.liferay.portlet.messageboards.NoSuchThreadFlagException; 600 601 /** 602 * Returns the number of message boards thread flags where userId = ? and threadId = ?. 603 * 604 * @param userId the user ID 605 * @param threadId the thread ID 606 * @return the number of matching message boards thread flags 607 */ 608 public int countByU_T(long userId, long threadId); 609 610 /** 611 * Caches the message boards thread flag in the entity cache if it is enabled. 612 * 613 * @param mbThreadFlag the message boards thread flag 614 */ 615 public void cacheResult(MBThreadFlag mbThreadFlag); 616 617 /** 618 * Caches the message boards thread flags in the entity cache if it is enabled. 619 * 620 * @param mbThreadFlags the message boards thread flags 621 */ 622 public void cacheResult(java.util.List<MBThreadFlag> mbThreadFlags); 623 624 /** 625 * Creates a new message boards thread flag with the primary key. Does not add the message boards thread flag to the database. 626 * 627 * @param threadFlagId the primary key for the new message boards thread flag 628 * @return the new message boards thread flag 629 */ 630 public MBThreadFlag create(long threadFlagId); 631 632 /** 633 * Removes the message boards thread flag with the primary key from the database. Also notifies the appropriate model listeners. 634 * 635 * @param threadFlagId the primary key of the message boards thread flag 636 * @return the message boards thread flag that was removed 637 * @throws NoSuchThreadFlagException if a message boards thread flag with the primary key could not be found 638 */ 639 public MBThreadFlag remove(long threadFlagId) 640 throws com.liferay.portlet.messageboards.NoSuchThreadFlagException; 641 642 public MBThreadFlag updateImpl(MBThreadFlag mbThreadFlag); 643 644 /** 645 * Returns the message boards thread flag with the primary key or throws a {@link NoSuchThreadFlagException} if it could not be found. 646 * 647 * @param threadFlagId the primary key of the message boards thread flag 648 * @return the message boards thread flag 649 * @throws NoSuchThreadFlagException if a message boards thread flag with the primary key could not be found 650 */ 651 public MBThreadFlag findByPrimaryKey(long threadFlagId) 652 throws com.liferay.portlet.messageboards.NoSuchThreadFlagException; 653 654 /** 655 * Returns the message boards thread flag with the primary key or returns <code>null</code> if it could not be found. 656 * 657 * @param threadFlagId the primary key of the message boards thread flag 658 * @return the message boards thread flag, or <code>null</code> if a message boards thread flag with the primary key could not be found 659 */ 660 public MBThreadFlag fetchByPrimaryKey(long threadFlagId); 661 662 @Override 663 public java.util.Map<java.io.Serializable, MBThreadFlag> fetchByPrimaryKeys( 664 java.util.Set<java.io.Serializable> primaryKeys); 665 666 /** 667 * Returns all the message boards thread flags. 668 * 669 * @return the message boards thread flags 670 */ 671 public java.util.List<MBThreadFlag> findAll(); 672 673 /** 674 * Returns a range of all the message boards thread flags. 675 * 676 * <p> 677 * 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 MBThreadFlagModelImpl}. 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. 678 * </p> 679 * 680 * @param start the lower bound of the range of message boards thread flags 681 * @param end the upper bound of the range of message boards thread flags (not inclusive) 682 * @return the range of message boards thread flags 683 */ 684 public java.util.List<MBThreadFlag> findAll(int start, int end); 685 686 /** 687 * Returns an ordered range of all the message boards thread flags. 688 * 689 * <p> 690 * 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 MBThreadFlagModelImpl}. 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. 691 * </p> 692 * 693 * @param start the lower bound of the range of message boards thread flags 694 * @param end the upper bound of the range of message boards thread flags (not inclusive) 695 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 696 * @return the ordered range of message boards thread flags 697 */ 698 public java.util.List<MBThreadFlag> findAll(int start, int end, 699 com.liferay.portal.kernel.util.OrderByComparator<MBThreadFlag> orderByComparator); 700 701 /** 702 * Removes all the message boards thread flags from the database. 703 */ 704 public void removeAll(); 705 706 /** 707 * Returns the number of message boards thread flags. 708 * 709 * @return the number of message boards thread flags 710 */ 711 public int countAll(); 712 }