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.MBThread;
22  
23  import java.util.List;
24  
25  /**
26   * <a href="MBThreadUtil.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       MBThreadPersistence
35   * @see       MBThreadPersistenceImpl
36   * @generated
37   */
38  public class MBThreadUtil {
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 MBThread remove(MBThread mbThread) throws SystemException {
66          return getPersistence().remove(mbThread);
67      }
68  
69      /**
70       * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, boolean)
71       */
72      public static MBThread update(MBThread mbThread, boolean merge)
73          throws SystemException {
74          return getPersistence().update(mbThread, merge);
75      }
76  
77      public static void cacheResult(
78          com.liferay.portlet.messageboards.model.MBThread mbThread) {
79          getPersistence().cacheResult(mbThread);
80      }
81  
82      public static void cacheResult(
83          java.util.List<com.liferay.portlet.messageboards.model.MBThread> mbThreads) {
84          getPersistence().cacheResult(mbThreads);
85      }
86  
87      public static com.liferay.portlet.messageboards.model.MBThread create(
88          long threadId) {
89          return getPersistence().create(threadId);
90      }
91  
92      public static com.liferay.portlet.messageboards.model.MBThread remove(
93          long threadId)
94          throws com.liferay.portal.kernel.exception.SystemException,
95              com.liferay.portlet.messageboards.NoSuchThreadException {
96          return getPersistence().remove(threadId);
97      }
98  
99      public static com.liferay.portlet.messageboards.model.MBThread updateImpl(
100         com.liferay.portlet.messageboards.model.MBThread mbThread, boolean merge)
101         throws com.liferay.portal.kernel.exception.SystemException {
102         return getPersistence().updateImpl(mbThread, merge);
103     }
104 
105     public static com.liferay.portlet.messageboards.model.MBThread findByPrimaryKey(
106         long threadId)
107         throws com.liferay.portal.kernel.exception.SystemException,
108             com.liferay.portlet.messageboards.NoSuchThreadException {
109         return getPersistence().findByPrimaryKey(threadId);
110     }
111 
112     public static com.liferay.portlet.messageboards.model.MBThread fetchByPrimaryKey(
113         long threadId)
114         throws com.liferay.portal.kernel.exception.SystemException {
115         return getPersistence().fetchByPrimaryKey(threadId);
116     }
117 
118     public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> findByGroupId(
119         long groupId)
120         throws com.liferay.portal.kernel.exception.SystemException {
121         return getPersistence().findByGroupId(groupId);
122     }
123 
124     public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> findByGroupId(
125         long groupId, int start, int end)
126         throws com.liferay.portal.kernel.exception.SystemException {
127         return getPersistence().findByGroupId(groupId, start, end);
128     }
129 
130     public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> findByGroupId(
131         long groupId, int start, int end,
132         com.liferay.portal.kernel.util.OrderByComparator obc)
133         throws com.liferay.portal.kernel.exception.SystemException {
134         return getPersistence().findByGroupId(groupId, start, end, obc);
135     }
136 
137     public static com.liferay.portlet.messageboards.model.MBThread findByGroupId_First(
138         long groupId, com.liferay.portal.kernel.util.OrderByComparator obc)
139         throws com.liferay.portal.kernel.exception.SystemException,
140             com.liferay.portlet.messageboards.NoSuchThreadException {
141         return getPersistence().findByGroupId_First(groupId, obc);
142     }
143 
144     public static com.liferay.portlet.messageboards.model.MBThread findByGroupId_Last(
145         long groupId, com.liferay.portal.kernel.util.OrderByComparator obc)
146         throws com.liferay.portal.kernel.exception.SystemException,
147             com.liferay.portlet.messageboards.NoSuchThreadException {
148         return getPersistence().findByGroupId_Last(groupId, obc);
149     }
150 
151     public static com.liferay.portlet.messageboards.model.MBThread[] findByGroupId_PrevAndNext(
152         long threadId, long groupId,
153         com.liferay.portal.kernel.util.OrderByComparator obc)
154         throws com.liferay.portal.kernel.exception.SystemException,
155             com.liferay.portlet.messageboards.NoSuchThreadException {
156         return getPersistence().findByGroupId_PrevAndNext(threadId, groupId, obc);
157     }
158 
159     public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> findByG_C(
160         long groupId, long categoryId)
161         throws com.liferay.portal.kernel.exception.SystemException {
162         return getPersistence().findByG_C(groupId, categoryId);
163     }
164 
165     public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> findByG_C(
166         long groupId, long categoryId, int start, int end)
167         throws com.liferay.portal.kernel.exception.SystemException {
168         return getPersistence().findByG_C(groupId, categoryId, start, end);
169     }
170 
171     public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> findByG_C(
172         long groupId, long categoryId, int start, int end,
173         com.liferay.portal.kernel.util.OrderByComparator obc)
174         throws com.liferay.portal.kernel.exception.SystemException {
175         return getPersistence().findByG_C(groupId, categoryId, start, end, obc);
176     }
177 
178     public static com.liferay.portlet.messageboards.model.MBThread findByG_C_First(
179         long groupId, long categoryId,
180         com.liferay.portal.kernel.util.OrderByComparator obc)
181         throws com.liferay.portal.kernel.exception.SystemException,
182             com.liferay.portlet.messageboards.NoSuchThreadException {
183         return getPersistence().findByG_C_First(groupId, categoryId, obc);
184     }
185 
186     public static com.liferay.portlet.messageboards.model.MBThread findByG_C_Last(
187         long groupId, long categoryId,
188         com.liferay.portal.kernel.util.OrderByComparator obc)
189         throws com.liferay.portal.kernel.exception.SystemException,
190             com.liferay.portlet.messageboards.NoSuchThreadException {
191         return getPersistence().findByG_C_Last(groupId, categoryId, obc);
192     }
193 
194     public static com.liferay.portlet.messageboards.model.MBThread[] findByG_C_PrevAndNext(
195         long threadId, long groupId, long categoryId,
196         com.liferay.portal.kernel.util.OrderByComparator obc)
197         throws com.liferay.portal.kernel.exception.SystemException,
198             com.liferay.portlet.messageboards.NoSuchThreadException {
199         return getPersistence()
200                    .findByG_C_PrevAndNext(threadId, groupId, categoryId, obc);
201     }
202 
203     public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> findByG_S(
204         long groupId, int status)
205         throws com.liferay.portal.kernel.exception.SystemException {
206         return getPersistence().findByG_S(groupId, status);
207     }
208 
209     public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> findByG_S(
210         long groupId, int status, int start, int end)
211         throws com.liferay.portal.kernel.exception.SystemException {
212         return getPersistence().findByG_S(groupId, status, start, end);
213     }
214 
215     public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> findByG_S(
216         long groupId, int status, int start, int end,
217         com.liferay.portal.kernel.util.OrderByComparator obc)
218         throws com.liferay.portal.kernel.exception.SystemException {
219         return getPersistence().findByG_S(groupId, status, start, end, obc);
220     }
221 
222     public static com.liferay.portlet.messageboards.model.MBThread findByG_S_First(
223         long groupId, int status,
224         com.liferay.portal.kernel.util.OrderByComparator obc)
225         throws com.liferay.portal.kernel.exception.SystemException,
226             com.liferay.portlet.messageboards.NoSuchThreadException {
227         return getPersistence().findByG_S_First(groupId, status, obc);
228     }
229 
230     public static com.liferay.portlet.messageboards.model.MBThread findByG_S_Last(
231         long groupId, int status,
232         com.liferay.portal.kernel.util.OrderByComparator obc)
233         throws com.liferay.portal.kernel.exception.SystemException,
234             com.liferay.portlet.messageboards.NoSuchThreadException {
235         return getPersistence().findByG_S_Last(groupId, status, obc);
236     }
237 
238     public static com.liferay.portlet.messageboards.model.MBThread[] findByG_S_PrevAndNext(
239         long threadId, long groupId, int status,
240         com.liferay.portal.kernel.util.OrderByComparator obc)
241         throws com.liferay.portal.kernel.exception.SystemException,
242             com.liferay.portlet.messageboards.NoSuchThreadException {
243         return getPersistence()
244                    .findByG_S_PrevAndNext(threadId, groupId, status, obc);
245     }
246 
247     public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> findByC_P(
248         long categoryId, double priority)
249         throws com.liferay.portal.kernel.exception.SystemException {
250         return getPersistence().findByC_P(categoryId, priority);
251     }
252 
253     public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> findByC_P(
254         long categoryId, double priority, int start, int end)
255         throws com.liferay.portal.kernel.exception.SystemException {
256         return getPersistence().findByC_P(categoryId, priority, start, end);
257     }
258 
259     public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> findByC_P(
260         long categoryId, double priority, int start, int end,
261         com.liferay.portal.kernel.util.OrderByComparator obc)
262         throws com.liferay.portal.kernel.exception.SystemException {
263         return getPersistence().findByC_P(categoryId, priority, start, end, obc);
264     }
265 
266     public static com.liferay.portlet.messageboards.model.MBThread findByC_P_First(
267         long categoryId, double priority,
268         com.liferay.portal.kernel.util.OrderByComparator obc)
269         throws com.liferay.portal.kernel.exception.SystemException,
270             com.liferay.portlet.messageboards.NoSuchThreadException {
271         return getPersistence().findByC_P_First(categoryId, priority, obc);
272     }
273 
274     public static com.liferay.portlet.messageboards.model.MBThread findByC_P_Last(
275         long categoryId, double priority,
276         com.liferay.portal.kernel.util.OrderByComparator obc)
277         throws com.liferay.portal.kernel.exception.SystemException,
278             com.liferay.portlet.messageboards.NoSuchThreadException {
279         return getPersistence().findByC_P_Last(categoryId, priority, obc);
280     }
281 
282     public static com.liferay.portlet.messageboards.model.MBThread[] findByC_P_PrevAndNext(
283         long threadId, long categoryId, double priority,
284         com.liferay.portal.kernel.util.OrderByComparator obc)
285         throws com.liferay.portal.kernel.exception.SystemException,
286             com.liferay.portlet.messageboards.NoSuchThreadException {
287         return getPersistence()
288                    .findByC_P_PrevAndNext(threadId, categoryId, priority, obc);
289     }
290 
291     public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> findByG_C_L(
292         long groupId, long categoryId, java.util.Date lastPostDate)
293         throws com.liferay.portal.kernel.exception.SystemException {
294         return getPersistence().findByG_C_L(groupId, categoryId, lastPostDate);
295     }
296 
297     public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> findByG_C_L(
298         long groupId, long categoryId, java.util.Date lastPostDate, int start,
299         int end) throws com.liferay.portal.kernel.exception.SystemException {
300         return getPersistence()
301                    .findByG_C_L(groupId, categoryId, lastPostDate, start, end);
302     }
303 
304     public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> findByG_C_L(
305         long groupId, long categoryId, java.util.Date lastPostDate, int start,
306         int end, com.liferay.portal.kernel.util.OrderByComparator obc)
307         throws com.liferay.portal.kernel.exception.SystemException {
308         return getPersistence()
309                    .findByG_C_L(groupId, categoryId, lastPostDate, start, end,
310             obc);
311     }
312 
313     public static com.liferay.portlet.messageboards.model.MBThread findByG_C_L_First(
314         long groupId, long categoryId, java.util.Date lastPostDate,
315         com.liferay.portal.kernel.util.OrderByComparator obc)
316         throws com.liferay.portal.kernel.exception.SystemException,
317             com.liferay.portlet.messageboards.NoSuchThreadException {
318         return getPersistence()
319                    .findByG_C_L_First(groupId, categoryId, lastPostDate, obc);
320     }
321 
322     public static com.liferay.portlet.messageboards.model.MBThread findByG_C_L_Last(
323         long groupId, long categoryId, java.util.Date lastPostDate,
324         com.liferay.portal.kernel.util.OrderByComparator obc)
325         throws com.liferay.portal.kernel.exception.SystemException,
326             com.liferay.portlet.messageboards.NoSuchThreadException {
327         return getPersistence()
328                    .findByG_C_L_Last(groupId, categoryId, lastPostDate, obc);
329     }
330 
331     public static com.liferay.portlet.messageboards.model.MBThread[] findByG_C_L_PrevAndNext(
332         long threadId, long groupId, long categoryId,
333         java.util.Date lastPostDate,
334         com.liferay.portal.kernel.util.OrderByComparator obc)
335         throws com.liferay.portal.kernel.exception.SystemException,
336             com.liferay.portlet.messageboards.NoSuchThreadException {
337         return getPersistence()
338                    .findByG_C_L_PrevAndNext(threadId, groupId, categoryId,
339             lastPostDate, obc);
340     }
341 
342     public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> findByG_C_S(
343         long groupId, long categoryId, int status)
344         throws com.liferay.portal.kernel.exception.SystemException {
345         return getPersistence().findByG_C_S(groupId, categoryId, status);
346     }
347 
348     public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> findByG_C_S(
349         long groupId, long categoryId, int status, int start, int end)
350         throws com.liferay.portal.kernel.exception.SystemException {
351         return getPersistence()
352                    .findByG_C_S(groupId, categoryId, status, start, end);
353     }
354 
355     public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> findByG_C_S(
356         long groupId, long categoryId, int status, int start, int end,
357         com.liferay.portal.kernel.util.OrderByComparator obc)
358         throws com.liferay.portal.kernel.exception.SystemException {
359         return getPersistence()
360                    .findByG_C_S(groupId, categoryId, status, start, end, obc);
361     }
362 
363     public static com.liferay.portlet.messageboards.model.MBThread findByG_C_S_First(
364         long groupId, long categoryId, int status,
365         com.liferay.portal.kernel.util.OrderByComparator obc)
366         throws com.liferay.portal.kernel.exception.SystemException,
367             com.liferay.portlet.messageboards.NoSuchThreadException {
368         return getPersistence()
369                    .findByG_C_S_First(groupId, categoryId, status, obc);
370     }
371 
372     public static com.liferay.portlet.messageboards.model.MBThread findByG_C_S_Last(
373         long groupId, long categoryId, int status,
374         com.liferay.portal.kernel.util.OrderByComparator obc)
375         throws com.liferay.portal.kernel.exception.SystemException,
376             com.liferay.portlet.messageboards.NoSuchThreadException {
377         return getPersistence()
378                    .findByG_C_S_Last(groupId, categoryId, status, obc);
379     }
380 
381     public static com.liferay.portlet.messageboards.model.MBThread[] findByG_C_S_PrevAndNext(
382         long threadId, long groupId, long categoryId, int status,
383         com.liferay.portal.kernel.util.OrderByComparator obc)
384         throws com.liferay.portal.kernel.exception.SystemException,
385             com.liferay.portlet.messageboards.NoSuchThreadException {
386         return getPersistence()
387                    .findByG_C_S_PrevAndNext(threadId, groupId, categoryId,
388             status, obc);
389     }
390 
391     public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> findAll()
392         throws com.liferay.portal.kernel.exception.SystemException {
393         return getPersistence().findAll();
394     }
395 
396     public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> findAll(
397         int start, int end)
398         throws com.liferay.portal.kernel.exception.SystemException {
399         return getPersistence().findAll(start, end);
400     }
401 
402     public static java.util.List<com.liferay.portlet.messageboards.model.MBThread> findAll(
403         int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
404         throws com.liferay.portal.kernel.exception.SystemException {
405         return getPersistence().findAll(start, end, obc);
406     }
407 
408     public static void removeByGroupId(long groupId)
409         throws com.liferay.portal.kernel.exception.SystemException {
410         getPersistence().removeByGroupId(groupId);
411     }
412 
413     public static void removeByG_C(long groupId, long categoryId)
414         throws com.liferay.portal.kernel.exception.SystemException {
415         getPersistence().removeByG_C(groupId, categoryId);
416     }
417 
418     public static void removeByG_S(long groupId, int status)
419         throws com.liferay.portal.kernel.exception.SystemException {
420         getPersistence().removeByG_S(groupId, status);
421     }
422 
423     public static void removeByC_P(long categoryId, double priority)
424         throws com.liferay.portal.kernel.exception.SystemException {
425         getPersistence().removeByC_P(categoryId, priority);
426     }
427 
428     public static void removeByG_C_L(long groupId, long categoryId,
429         java.util.Date lastPostDate)
430         throws com.liferay.portal.kernel.exception.SystemException {
431         getPersistence().removeByG_C_L(groupId, categoryId, lastPostDate);
432     }
433 
434     public static void removeByG_C_S(long groupId, long categoryId, int status)
435         throws com.liferay.portal.kernel.exception.SystemException {
436         getPersistence().removeByG_C_S(groupId, categoryId, status);
437     }
438 
439     public static void removeAll()
440         throws com.liferay.portal.kernel.exception.SystemException {
441         getPersistence().removeAll();
442     }
443 
444     public static int countByGroupId(long groupId)
445         throws com.liferay.portal.kernel.exception.SystemException {
446         return getPersistence().countByGroupId(groupId);
447     }
448 
449     public static int countByG_C(long groupId, long categoryId)
450         throws com.liferay.portal.kernel.exception.SystemException {
451         return getPersistence().countByG_C(groupId, categoryId);
452     }
453 
454     public static int countByG_S(long groupId, int status)
455         throws com.liferay.portal.kernel.exception.SystemException {
456         return getPersistence().countByG_S(groupId, status);
457     }
458 
459     public static int countByC_P(long categoryId, double priority)
460         throws com.liferay.portal.kernel.exception.SystemException {
461         return getPersistence().countByC_P(categoryId, priority);
462     }
463 
464     public static int countByG_C_L(long groupId, long categoryId,
465         java.util.Date lastPostDate)
466         throws com.liferay.portal.kernel.exception.SystemException {
467         return getPersistence().countByG_C_L(groupId, categoryId, lastPostDate);
468     }
469 
470     public static int countByG_C_S(long groupId, long categoryId, int status)
471         throws com.liferay.portal.kernel.exception.SystemException {
472         return getPersistence().countByG_C_S(groupId, categoryId, status);
473     }
474 
475     public static int countAll()
476         throws com.liferay.portal.kernel.exception.SystemException {
477         return getPersistence().countAll();
478     }
479 
480     public static MBThreadPersistence getPersistence() {
481         if (_persistence == null) {
482             _persistence = (MBThreadPersistence)PortalBeanLocatorUtil.locate(MBThreadPersistence.class.getName());
483         }
484 
485         return _persistence;
486     }
487 
488     public void setPersistence(MBThreadPersistence persistence) {
489         _persistence = persistence;
490     }
491 
492     private static MBThreadPersistence _persistence;
493 }