1   /**
2    * Copyright (c) 2000-2010 Liferay, Inc. All rights reserved.
3    *
4    * This library is free software; you can redistribute it and/or modify it under
5    * the terms of the GNU Lesser General Public License as published by the Free
6    * Software Foundation; either version 2.1 of the License, or (at your option)
7    * any later version.
8    *
9    * This library is distributed in the hope that it will be useful, but WITHOUT
10   * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
11   * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
12   * details.
13   */
14  
15  package com.liferay.portlet.messageboards.service.persistence;
16  
17  import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
18  import com.liferay.portal.kernel.dao.orm.DynamicQuery;
19  import com.liferay.portal.kernel.exception.SystemException;
20  
21  import com.liferay.portlet.messageboards.model.MBMessageFlag;
22  
23  import java.util.List;
24  
25  /**
26   * <a href="MBMessageFlagUtil.java.html"><b><i>View Source</i></b></a>
27   *
28   * <p>
29   * ServiceBuilder generated this class. Modifications in this class will be
30   * overwritten the next time is generated.
31   * </p>
32   *
33   * @author    Brian Wing Shun Chan
34   * @see       MBMessageFlagPersistence
35   * @see       MBMessageFlagPersistenceImpl
36   * @generated
37   */
38  public class MBMessageFlagUtil {
39      /**
40       * @see com.liferay.portal.service.persistence.BasePersistence#clearCache()
41       */
42      public static void clearCache() {
43          getPersistence().clearCache();
44      }
45  
46      /**
47       * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery)
48       */
49      public static List<Object> findWithDynamicQuery(DynamicQuery dynamicQuery)
50          throws SystemException {
51          return getPersistence().findWithDynamicQuery(dynamicQuery);
52      }
53  
54      /**
55       * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int)
56       */
57      public static List<Object> findWithDynamicQuery(DynamicQuery dynamicQuery,
58          int start, int end) throws SystemException {
59          return getPersistence().findWithDynamicQuery(dynamicQuery, start, end);
60      }
61  
62      /**
63       * @see com.liferay.portal.service.persistence.BasePersistence#remove(com.liferay.portal.model.BaseModel)
64       */
65      public static MBMessageFlag remove(MBMessageFlag mbMessageFlag)
66          throws SystemException {
67          return getPersistence().remove(mbMessageFlag);
68      }
69  
70      /**
71       * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, boolean)
72       */
73      public static MBMessageFlag update(MBMessageFlag mbMessageFlag,
74          boolean merge) throws SystemException {
75          return getPersistence().update(mbMessageFlag, merge);
76      }
77  
78      public static void cacheResult(
79          com.liferay.portlet.messageboards.model.MBMessageFlag mbMessageFlag) {
80          getPersistence().cacheResult(mbMessageFlag);
81      }
82  
83      public static void cacheResult(
84          java.util.List<com.liferay.portlet.messageboards.model.MBMessageFlag> mbMessageFlags) {
85          getPersistence().cacheResult(mbMessageFlags);
86      }
87  
88      public static com.liferay.portlet.messageboards.model.MBMessageFlag create(
89          long messageFlagId) {
90          return getPersistence().create(messageFlagId);
91      }
92  
93      public static com.liferay.portlet.messageboards.model.MBMessageFlag remove(
94          long messageFlagId)
95          throws com.liferay.portal.kernel.exception.SystemException,
96              com.liferay.portlet.messageboards.NoSuchMessageFlagException {
97          return getPersistence().remove(messageFlagId);
98      }
99  
100     public static com.liferay.portlet.messageboards.model.MBMessageFlag updateImpl(
101         com.liferay.portlet.messageboards.model.MBMessageFlag mbMessageFlag,
102         boolean merge)
103         throws com.liferay.portal.kernel.exception.SystemException {
104         return getPersistence().updateImpl(mbMessageFlag, merge);
105     }
106 
107     public static com.liferay.portlet.messageboards.model.MBMessageFlag findByPrimaryKey(
108         long messageFlagId)
109         throws com.liferay.portal.kernel.exception.SystemException,
110             com.liferay.portlet.messageboards.NoSuchMessageFlagException {
111         return getPersistence().findByPrimaryKey(messageFlagId);
112     }
113 
114     public static com.liferay.portlet.messageboards.model.MBMessageFlag fetchByPrimaryKey(
115         long messageFlagId)
116         throws com.liferay.portal.kernel.exception.SystemException {
117         return getPersistence().fetchByPrimaryKey(messageFlagId);
118     }
119 
120     public static java.util.List<com.liferay.portlet.messageboards.model.MBMessageFlag> findByUserId(
121         long userId) throws com.liferay.portal.kernel.exception.SystemException {
122         return getPersistence().findByUserId(userId);
123     }
124 
125     public static java.util.List<com.liferay.portlet.messageboards.model.MBMessageFlag> findByUserId(
126         long userId, int start, int end)
127         throws com.liferay.portal.kernel.exception.SystemException {
128         return getPersistence().findByUserId(userId, start, end);
129     }
130 
131     public static java.util.List<com.liferay.portlet.messageboards.model.MBMessageFlag> findByUserId(
132         long userId, int start, int end,
133         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
134         throws com.liferay.portal.kernel.exception.SystemException {
135         return getPersistence()
136                    .findByUserId(userId, start, end, orderByComparator);
137     }
138 
139     public static com.liferay.portlet.messageboards.model.MBMessageFlag findByUserId_First(
140         long userId,
141         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
142         throws com.liferay.portal.kernel.exception.SystemException,
143             com.liferay.portlet.messageboards.NoSuchMessageFlagException {
144         return getPersistence().findByUserId_First(userId, orderByComparator);
145     }
146 
147     public static com.liferay.portlet.messageboards.model.MBMessageFlag findByUserId_Last(
148         long userId,
149         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
150         throws com.liferay.portal.kernel.exception.SystemException,
151             com.liferay.portlet.messageboards.NoSuchMessageFlagException {
152         return getPersistence().findByUserId_Last(userId, orderByComparator);
153     }
154 
155     public static com.liferay.portlet.messageboards.model.MBMessageFlag[] findByUserId_PrevAndNext(
156         long messageFlagId, long userId,
157         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
158         throws com.liferay.portal.kernel.exception.SystemException,
159             com.liferay.portlet.messageboards.NoSuchMessageFlagException {
160         return getPersistence()
161                    .findByUserId_PrevAndNext(messageFlagId, userId,
162             orderByComparator);
163     }
164 
165     public static java.util.List<com.liferay.portlet.messageboards.model.MBMessageFlag> findByThreadId(
166         long threadId)
167         throws com.liferay.portal.kernel.exception.SystemException {
168         return getPersistence().findByThreadId(threadId);
169     }
170 
171     public static java.util.List<com.liferay.portlet.messageboards.model.MBMessageFlag> findByThreadId(
172         long threadId, int start, int end)
173         throws com.liferay.portal.kernel.exception.SystemException {
174         return getPersistence().findByThreadId(threadId, start, end);
175     }
176 
177     public static java.util.List<com.liferay.portlet.messageboards.model.MBMessageFlag> findByThreadId(
178         long threadId, int start, int end,
179         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
180         throws com.liferay.portal.kernel.exception.SystemException {
181         return getPersistence()
182                    .findByThreadId(threadId, start, end, orderByComparator);
183     }
184 
185     public static com.liferay.portlet.messageboards.model.MBMessageFlag findByThreadId_First(
186         long threadId,
187         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
188         throws com.liferay.portal.kernel.exception.SystemException,
189             com.liferay.portlet.messageboards.NoSuchMessageFlagException {
190         return getPersistence().findByThreadId_First(threadId, orderByComparator);
191     }
192 
193     public static com.liferay.portlet.messageboards.model.MBMessageFlag findByThreadId_Last(
194         long threadId,
195         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
196         throws com.liferay.portal.kernel.exception.SystemException,
197             com.liferay.portlet.messageboards.NoSuchMessageFlagException {
198         return getPersistence().findByThreadId_Last(threadId, orderByComparator);
199     }
200 
201     public static com.liferay.portlet.messageboards.model.MBMessageFlag[] findByThreadId_PrevAndNext(
202         long messageFlagId, long threadId,
203         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
204         throws com.liferay.portal.kernel.exception.SystemException,
205             com.liferay.portlet.messageboards.NoSuchMessageFlagException {
206         return getPersistence()
207                    .findByThreadId_PrevAndNext(messageFlagId, threadId,
208             orderByComparator);
209     }
210 
211     public static java.util.List<com.liferay.portlet.messageboards.model.MBMessageFlag> findByMessageId(
212         long messageId)
213         throws com.liferay.portal.kernel.exception.SystemException {
214         return getPersistence().findByMessageId(messageId);
215     }
216 
217     public static java.util.List<com.liferay.portlet.messageboards.model.MBMessageFlag> findByMessageId(
218         long messageId, int start, int end)
219         throws com.liferay.portal.kernel.exception.SystemException {
220         return getPersistence().findByMessageId(messageId, start, end);
221     }
222 
223     public static java.util.List<com.liferay.portlet.messageboards.model.MBMessageFlag> findByMessageId(
224         long messageId, int start, int end,
225         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
226         throws com.liferay.portal.kernel.exception.SystemException {
227         return getPersistence()
228                    .findByMessageId(messageId, start, end, orderByComparator);
229     }
230 
231     public static com.liferay.portlet.messageboards.model.MBMessageFlag findByMessageId_First(
232         long messageId,
233         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
234         throws com.liferay.portal.kernel.exception.SystemException,
235             com.liferay.portlet.messageboards.NoSuchMessageFlagException {
236         return getPersistence()
237                    .findByMessageId_First(messageId, orderByComparator);
238     }
239 
240     public static com.liferay.portlet.messageboards.model.MBMessageFlag findByMessageId_Last(
241         long messageId,
242         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
243         throws com.liferay.portal.kernel.exception.SystemException,
244             com.liferay.portlet.messageboards.NoSuchMessageFlagException {
245         return getPersistence()
246                    .findByMessageId_Last(messageId, orderByComparator);
247     }
248 
249     public static com.liferay.portlet.messageboards.model.MBMessageFlag[] findByMessageId_PrevAndNext(
250         long messageFlagId, long messageId,
251         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
252         throws com.liferay.portal.kernel.exception.SystemException,
253             com.liferay.portlet.messageboards.NoSuchMessageFlagException {
254         return getPersistence()
255                    .findByMessageId_PrevAndNext(messageFlagId, messageId,
256             orderByComparator);
257     }
258 
259     public static java.util.List<com.liferay.portlet.messageboards.model.MBMessageFlag> findByT_F(
260         long threadId, int flag)
261         throws com.liferay.portal.kernel.exception.SystemException {
262         return getPersistence().findByT_F(threadId, flag);
263     }
264 
265     public static java.util.List<com.liferay.portlet.messageboards.model.MBMessageFlag> findByT_F(
266         long threadId, int flag, int start, int end)
267         throws com.liferay.portal.kernel.exception.SystemException {
268         return getPersistence().findByT_F(threadId, flag, start, end);
269     }
270 
271     public static java.util.List<com.liferay.portlet.messageboards.model.MBMessageFlag> findByT_F(
272         long threadId, int flag, int start, int end,
273         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
274         throws com.liferay.portal.kernel.exception.SystemException {
275         return getPersistence()
276                    .findByT_F(threadId, flag, start, end, orderByComparator);
277     }
278 
279     public static com.liferay.portlet.messageboards.model.MBMessageFlag findByT_F_First(
280         long threadId, int flag,
281         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
282         throws com.liferay.portal.kernel.exception.SystemException,
283             com.liferay.portlet.messageboards.NoSuchMessageFlagException {
284         return getPersistence()
285                    .findByT_F_First(threadId, flag, orderByComparator);
286     }
287 
288     public static com.liferay.portlet.messageboards.model.MBMessageFlag findByT_F_Last(
289         long threadId, int flag,
290         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
291         throws com.liferay.portal.kernel.exception.SystemException,
292             com.liferay.portlet.messageboards.NoSuchMessageFlagException {
293         return getPersistence().findByT_F_Last(threadId, flag, orderByComparator);
294     }
295 
296     public static com.liferay.portlet.messageboards.model.MBMessageFlag[] findByT_F_PrevAndNext(
297         long messageFlagId, long threadId, int flag,
298         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
299         throws com.liferay.portal.kernel.exception.SystemException,
300             com.liferay.portlet.messageboards.NoSuchMessageFlagException {
301         return getPersistence()
302                    .findByT_F_PrevAndNext(messageFlagId, threadId, flag,
303             orderByComparator);
304     }
305 
306     public static java.util.List<com.liferay.portlet.messageboards.model.MBMessageFlag> findByM_F(
307         long messageId, int flag)
308         throws com.liferay.portal.kernel.exception.SystemException {
309         return getPersistence().findByM_F(messageId, flag);
310     }
311 
312     public static java.util.List<com.liferay.portlet.messageboards.model.MBMessageFlag> findByM_F(
313         long messageId, int flag, int start, int end)
314         throws com.liferay.portal.kernel.exception.SystemException {
315         return getPersistence().findByM_F(messageId, flag, start, end);
316     }
317 
318     public static java.util.List<com.liferay.portlet.messageboards.model.MBMessageFlag> findByM_F(
319         long messageId, int flag, int start, int end,
320         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
321         throws com.liferay.portal.kernel.exception.SystemException {
322         return getPersistence()
323                    .findByM_F(messageId, flag, start, end, orderByComparator);
324     }
325 
326     public static com.liferay.portlet.messageboards.model.MBMessageFlag findByM_F_First(
327         long messageId, int flag,
328         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
329         throws com.liferay.portal.kernel.exception.SystemException,
330             com.liferay.portlet.messageboards.NoSuchMessageFlagException {
331         return getPersistence()
332                    .findByM_F_First(messageId, flag, orderByComparator);
333     }
334 
335     public static com.liferay.portlet.messageboards.model.MBMessageFlag findByM_F_Last(
336         long messageId, int flag,
337         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
338         throws com.liferay.portal.kernel.exception.SystemException,
339             com.liferay.portlet.messageboards.NoSuchMessageFlagException {
340         return getPersistence()
341                    .findByM_F_Last(messageId, flag, orderByComparator);
342     }
343 
344     public static com.liferay.portlet.messageboards.model.MBMessageFlag[] findByM_F_PrevAndNext(
345         long messageFlagId, long messageId, int flag,
346         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
347         throws com.liferay.portal.kernel.exception.SystemException,
348             com.liferay.portlet.messageboards.NoSuchMessageFlagException {
349         return getPersistence()
350                    .findByM_F_PrevAndNext(messageFlagId, messageId, flag,
351             orderByComparator);
352     }
353 
354     public static java.util.List<com.liferay.portlet.messageboards.model.MBMessageFlag> findByU_T_F(
355         long userId, long threadId, int flag)
356         throws com.liferay.portal.kernel.exception.SystemException {
357         return getPersistence().findByU_T_F(userId, threadId, flag);
358     }
359 
360     public static java.util.List<com.liferay.portlet.messageboards.model.MBMessageFlag> findByU_T_F(
361         long userId, long threadId, int flag, int start, int end)
362         throws com.liferay.portal.kernel.exception.SystemException {
363         return getPersistence().findByU_T_F(userId, threadId, flag, start, end);
364     }
365 
366     public static java.util.List<com.liferay.portlet.messageboards.model.MBMessageFlag> findByU_T_F(
367         long userId, long threadId, int flag, int start, int end,
368         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
369         throws com.liferay.portal.kernel.exception.SystemException {
370         return getPersistence()
371                    .findByU_T_F(userId, threadId, flag, start, end,
372             orderByComparator);
373     }
374 
375     public static com.liferay.portlet.messageboards.model.MBMessageFlag findByU_T_F_First(
376         long userId, long threadId, int flag,
377         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
378         throws com.liferay.portal.kernel.exception.SystemException,
379             com.liferay.portlet.messageboards.NoSuchMessageFlagException {
380         return getPersistence()
381                    .findByU_T_F_First(userId, threadId, flag, orderByComparator);
382     }
383 
384     public static com.liferay.portlet.messageboards.model.MBMessageFlag findByU_T_F_Last(
385         long userId, long threadId, int flag,
386         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
387         throws com.liferay.portal.kernel.exception.SystemException,
388             com.liferay.portlet.messageboards.NoSuchMessageFlagException {
389         return getPersistence()
390                    .findByU_T_F_Last(userId, threadId, flag, orderByComparator);
391     }
392 
393     public static com.liferay.portlet.messageboards.model.MBMessageFlag[] findByU_T_F_PrevAndNext(
394         long messageFlagId, long userId, long threadId, int flag,
395         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
396         throws com.liferay.portal.kernel.exception.SystemException,
397             com.liferay.portlet.messageboards.NoSuchMessageFlagException {
398         return getPersistence()
399                    .findByU_T_F_PrevAndNext(messageFlagId, userId, threadId,
400             flag, orderByComparator);
401     }
402 
403     public static com.liferay.portlet.messageboards.model.MBMessageFlag findByU_M_F(
404         long userId, long messageId, int flag)
405         throws com.liferay.portal.kernel.exception.SystemException,
406             com.liferay.portlet.messageboards.NoSuchMessageFlagException {
407         return getPersistence().findByU_M_F(userId, messageId, flag);
408     }
409 
410     public static com.liferay.portlet.messageboards.model.MBMessageFlag fetchByU_M_F(
411         long userId, long messageId, int flag)
412         throws com.liferay.portal.kernel.exception.SystemException {
413         return getPersistence().fetchByU_M_F(userId, messageId, flag);
414     }
415 
416     public static com.liferay.portlet.messageboards.model.MBMessageFlag fetchByU_M_F(
417         long userId, long messageId, int flag, boolean retrieveFromCache)
418         throws com.liferay.portal.kernel.exception.SystemException {
419         return getPersistence()
420                    .fetchByU_M_F(userId, messageId, flag, retrieveFromCache);
421     }
422 
423     public static java.util.List<com.liferay.portlet.messageboards.model.MBMessageFlag> findAll()
424         throws com.liferay.portal.kernel.exception.SystemException {
425         return getPersistence().findAll();
426     }
427 
428     public static java.util.List<com.liferay.portlet.messageboards.model.MBMessageFlag> findAll(
429         int start, int end)
430         throws com.liferay.portal.kernel.exception.SystemException {
431         return getPersistence().findAll(start, end);
432     }
433 
434     public static java.util.List<com.liferay.portlet.messageboards.model.MBMessageFlag> findAll(
435         int start, int end,
436         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
437         throws com.liferay.portal.kernel.exception.SystemException {
438         return getPersistence().findAll(start, end, orderByComparator);
439     }
440 
441     public static void removeByUserId(long userId)
442         throws com.liferay.portal.kernel.exception.SystemException {
443         getPersistence().removeByUserId(userId);
444     }
445 
446     public static void removeByThreadId(long threadId)
447         throws com.liferay.portal.kernel.exception.SystemException {
448         getPersistence().removeByThreadId(threadId);
449     }
450 
451     public static void removeByMessageId(long messageId)
452         throws com.liferay.portal.kernel.exception.SystemException {
453         getPersistence().removeByMessageId(messageId);
454     }
455 
456     public static void removeByT_F(long threadId, int flag)
457         throws com.liferay.portal.kernel.exception.SystemException {
458         getPersistence().removeByT_F(threadId, flag);
459     }
460 
461     public static void removeByM_F(long messageId, int flag)
462         throws com.liferay.portal.kernel.exception.SystemException {
463         getPersistence().removeByM_F(messageId, flag);
464     }
465 
466     public static void removeByU_T_F(long userId, long threadId, int flag)
467         throws com.liferay.portal.kernel.exception.SystemException {
468         getPersistence().removeByU_T_F(userId, threadId, flag);
469     }
470 
471     public static void removeByU_M_F(long userId, long messageId, int flag)
472         throws com.liferay.portal.kernel.exception.SystemException,
473             com.liferay.portlet.messageboards.NoSuchMessageFlagException {
474         getPersistence().removeByU_M_F(userId, messageId, flag);
475     }
476 
477     public static void removeAll()
478         throws com.liferay.portal.kernel.exception.SystemException {
479         getPersistence().removeAll();
480     }
481 
482     public static int countByUserId(long userId)
483         throws com.liferay.portal.kernel.exception.SystemException {
484         return getPersistence().countByUserId(userId);
485     }
486 
487     public static int countByThreadId(long threadId)
488         throws com.liferay.portal.kernel.exception.SystemException {
489         return getPersistence().countByThreadId(threadId);
490     }
491 
492     public static int countByMessageId(long messageId)
493         throws com.liferay.portal.kernel.exception.SystemException {
494         return getPersistence().countByMessageId(messageId);
495     }
496 
497     public static int countByT_F(long threadId, int flag)
498         throws com.liferay.portal.kernel.exception.SystemException {
499         return getPersistence().countByT_F(threadId, flag);
500     }
501 
502     public static int countByM_F(long messageId, int flag)
503         throws com.liferay.portal.kernel.exception.SystemException {
504         return getPersistence().countByM_F(messageId, flag);
505     }
506 
507     public static int countByU_T_F(long userId, long threadId, int flag)
508         throws com.liferay.portal.kernel.exception.SystemException {
509         return getPersistence().countByU_T_F(userId, threadId, flag);
510     }
511 
512     public static int countByU_M_F(long userId, long messageId, int flag)
513         throws com.liferay.portal.kernel.exception.SystemException {
514         return getPersistence().countByU_M_F(userId, messageId, flag);
515     }
516 
517     public static int countAll()
518         throws com.liferay.portal.kernel.exception.SystemException {
519         return getPersistence().countAll();
520     }
521 
522     public static MBMessageFlagPersistence getPersistence() {
523         if (_persistence == null) {
524             _persistence = (MBMessageFlagPersistence)PortalBeanLocatorUtil.locate(MBMessageFlagPersistence.class.getName());
525         }
526 
527         return _persistence;
528     }
529 
530     public void setPersistence(MBMessageFlagPersistence persistence) {
531         _persistence = persistence;
532     }
533 
534     private static MBMessageFlagPersistence _persistence;
535 }