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