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.MBStatsUser;
22  
23  import java.util.List;
24  
25  /**
26   * <a href="MBStatsUserUtil.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       MBStatsUserPersistence
35   * @see       MBStatsUserPersistenceImpl
36   * @generated
37   */
38  public class MBStatsUserUtil {
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 MBStatsUser remove(MBStatsUser mbStatsUser)
66          throws SystemException {
67          return getPersistence().remove(mbStatsUser);
68      }
69  
70      /**
71       * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, boolean)
72       */
73      public static MBStatsUser update(MBStatsUser mbStatsUser, boolean merge)
74          throws SystemException {
75          return getPersistence().update(mbStatsUser, merge);
76      }
77  
78      public static void cacheResult(
79          com.liferay.portlet.messageboards.model.MBStatsUser mbStatsUser) {
80          getPersistence().cacheResult(mbStatsUser);
81      }
82  
83      public static void cacheResult(
84          java.util.List<com.liferay.portlet.messageboards.model.MBStatsUser> mbStatsUsers) {
85          getPersistence().cacheResult(mbStatsUsers);
86      }
87  
88      public static com.liferay.portlet.messageboards.model.MBStatsUser create(
89          long statsUserId) {
90          return getPersistence().create(statsUserId);
91      }
92  
93      public static com.liferay.portlet.messageboards.model.MBStatsUser remove(
94          long statsUserId)
95          throws com.liferay.portal.kernel.exception.SystemException,
96              com.liferay.portlet.messageboards.NoSuchStatsUserException {
97          return getPersistence().remove(statsUserId);
98      }
99  
100     public static com.liferay.portlet.messageboards.model.MBStatsUser updateImpl(
101         com.liferay.portlet.messageboards.model.MBStatsUser mbStatsUser,
102         boolean merge)
103         throws com.liferay.portal.kernel.exception.SystemException {
104         return getPersistence().updateImpl(mbStatsUser, merge);
105     }
106 
107     public static com.liferay.portlet.messageboards.model.MBStatsUser findByPrimaryKey(
108         long statsUserId)
109         throws com.liferay.portal.kernel.exception.SystemException,
110             com.liferay.portlet.messageboards.NoSuchStatsUserException {
111         return getPersistence().findByPrimaryKey(statsUserId);
112     }
113 
114     public static com.liferay.portlet.messageboards.model.MBStatsUser fetchByPrimaryKey(
115         long statsUserId)
116         throws com.liferay.portal.kernel.exception.SystemException {
117         return getPersistence().fetchByPrimaryKey(statsUserId);
118     }
119 
120     public static java.util.List<com.liferay.portlet.messageboards.model.MBStatsUser> findByGroupId(
121         long groupId)
122         throws com.liferay.portal.kernel.exception.SystemException {
123         return getPersistence().findByGroupId(groupId);
124     }
125 
126     public static java.util.List<com.liferay.portlet.messageboards.model.MBStatsUser> findByGroupId(
127         long groupId, int start, int end)
128         throws com.liferay.portal.kernel.exception.SystemException {
129         return getPersistence().findByGroupId(groupId, start, end);
130     }
131 
132     public static java.util.List<com.liferay.portlet.messageboards.model.MBStatsUser> findByGroupId(
133         long groupId, int start, int end,
134         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
135         throws com.liferay.portal.kernel.exception.SystemException {
136         return getPersistence()
137                    .findByGroupId(groupId, start, end, orderByComparator);
138     }
139 
140     public static com.liferay.portlet.messageboards.model.MBStatsUser findByGroupId_First(
141         long groupId,
142         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
143         throws com.liferay.portal.kernel.exception.SystemException,
144             com.liferay.portlet.messageboards.NoSuchStatsUserException {
145         return getPersistence().findByGroupId_First(groupId, orderByComparator);
146     }
147 
148     public static com.liferay.portlet.messageboards.model.MBStatsUser findByGroupId_Last(
149         long groupId,
150         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
151         throws com.liferay.portal.kernel.exception.SystemException,
152             com.liferay.portlet.messageboards.NoSuchStatsUserException {
153         return getPersistence().findByGroupId_Last(groupId, orderByComparator);
154     }
155 
156     public static com.liferay.portlet.messageboards.model.MBStatsUser[] findByGroupId_PrevAndNext(
157         long statsUserId, long groupId,
158         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
159         throws com.liferay.portal.kernel.exception.SystemException,
160             com.liferay.portlet.messageboards.NoSuchStatsUserException {
161         return getPersistence()
162                    .findByGroupId_PrevAndNext(statsUserId, groupId,
163             orderByComparator);
164     }
165 
166     public static java.util.List<com.liferay.portlet.messageboards.model.MBStatsUser> findByUserId(
167         long userId) throws com.liferay.portal.kernel.exception.SystemException {
168         return getPersistence().findByUserId(userId);
169     }
170 
171     public static java.util.List<com.liferay.portlet.messageboards.model.MBStatsUser> findByUserId(
172         long userId, int start, int end)
173         throws com.liferay.portal.kernel.exception.SystemException {
174         return getPersistence().findByUserId(userId, start, end);
175     }
176 
177     public static java.util.List<com.liferay.portlet.messageboards.model.MBStatsUser> findByUserId(
178         long userId, int start, int end,
179         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
180         throws com.liferay.portal.kernel.exception.SystemException {
181         return getPersistence()
182                    .findByUserId(userId, start, end, orderByComparator);
183     }
184 
185     public static com.liferay.portlet.messageboards.model.MBStatsUser findByUserId_First(
186         long userId,
187         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
188         throws com.liferay.portal.kernel.exception.SystemException,
189             com.liferay.portlet.messageboards.NoSuchStatsUserException {
190         return getPersistence().findByUserId_First(userId, orderByComparator);
191     }
192 
193     public static com.liferay.portlet.messageboards.model.MBStatsUser findByUserId_Last(
194         long userId,
195         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
196         throws com.liferay.portal.kernel.exception.SystemException,
197             com.liferay.portlet.messageboards.NoSuchStatsUserException {
198         return getPersistence().findByUserId_Last(userId, orderByComparator);
199     }
200 
201     public static com.liferay.portlet.messageboards.model.MBStatsUser[] findByUserId_PrevAndNext(
202         long statsUserId, long userId,
203         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
204         throws com.liferay.portal.kernel.exception.SystemException,
205             com.liferay.portlet.messageboards.NoSuchStatsUserException {
206         return getPersistence()
207                    .findByUserId_PrevAndNext(statsUserId, userId,
208             orderByComparator);
209     }
210 
211     public static com.liferay.portlet.messageboards.model.MBStatsUser findByG_U(
212         long groupId, long userId)
213         throws com.liferay.portal.kernel.exception.SystemException,
214             com.liferay.portlet.messageboards.NoSuchStatsUserException {
215         return getPersistence().findByG_U(groupId, userId);
216     }
217 
218     public static com.liferay.portlet.messageboards.model.MBStatsUser fetchByG_U(
219         long groupId, long userId)
220         throws com.liferay.portal.kernel.exception.SystemException {
221         return getPersistence().fetchByG_U(groupId, userId);
222     }
223 
224     public static com.liferay.portlet.messageboards.model.MBStatsUser fetchByG_U(
225         long groupId, long userId, boolean retrieveFromCache)
226         throws com.liferay.portal.kernel.exception.SystemException {
227         return getPersistence().fetchByG_U(groupId, userId, retrieveFromCache);
228     }
229 
230     public static java.util.List<com.liferay.portlet.messageboards.model.MBStatsUser> findByG_M(
231         long groupId, int messageCount)
232         throws com.liferay.portal.kernel.exception.SystemException {
233         return getPersistence().findByG_M(groupId, messageCount);
234     }
235 
236     public static java.util.List<com.liferay.portlet.messageboards.model.MBStatsUser> findByG_M(
237         long groupId, int messageCount, int start, int end)
238         throws com.liferay.portal.kernel.exception.SystemException {
239         return getPersistence().findByG_M(groupId, messageCount, start, end);
240     }
241 
242     public static java.util.List<com.liferay.portlet.messageboards.model.MBStatsUser> findByG_M(
243         long groupId, int messageCount, int start, int end,
244         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
245         throws com.liferay.portal.kernel.exception.SystemException {
246         return getPersistence()
247                    .findByG_M(groupId, messageCount, start, end,
248             orderByComparator);
249     }
250 
251     public static com.liferay.portlet.messageboards.model.MBStatsUser findByG_M_First(
252         long groupId, int messageCount,
253         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
254         throws com.liferay.portal.kernel.exception.SystemException,
255             com.liferay.portlet.messageboards.NoSuchStatsUserException {
256         return getPersistence()
257                    .findByG_M_First(groupId, messageCount, orderByComparator);
258     }
259 
260     public static com.liferay.portlet.messageboards.model.MBStatsUser findByG_M_Last(
261         long groupId, int messageCount,
262         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
263         throws com.liferay.portal.kernel.exception.SystemException,
264             com.liferay.portlet.messageboards.NoSuchStatsUserException {
265         return getPersistence()
266                    .findByG_M_Last(groupId, messageCount, orderByComparator);
267     }
268 
269     public static com.liferay.portlet.messageboards.model.MBStatsUser[] findByG_M_PrevAndNext(
270         long statsUserId, long groupId, int messageCount,
271         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
272         throws com.liferay.portal.kernel.exception.SystemException,
273             com.liferay.portlet.messageboards.NoSuchStatsUserException {
274         return getPersistence()
275                    .findByG_M_PrevAndNext(statsUserId, groupId, messageCount,
276             orderByComparator);
277     }
278 
279     public static java.util.List<com.liferay.portlet.messageboards.model.MBStatsUser> findAll()
280         throws com.liferay.portal.kernel.exception.SystemException {
281         return getPersistence().findAll();
282     }
283 
284     public static java.util.List<com.liferay.portlet.messageboards.model.MBStatsUser> findAll(
285         int start, int end)
286         throws com.liferay.portal.kernel.exception.SystemException {
287         return getPersistence().findAll(start, end);
288     }
289 
290     public static java.util.List<com.liferay.portlet.messageboards.model.MBStatsUser> findAll(
291         int start, int end,
292         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
293         throws com.liferay.portal.kernel.exception.SystemException {
294         return getPersistence().findAll(start, end, orderByComparator);
295     }
296 
297     public static void removeByGroupId(long groupId)
298         throws com.liferay.portal.kernel.exception.SystemException {
299         getPersistence().removeByGroupId(groupId);
300     }
301 
302     public static void removeByUserId(long userId)
303         throws com.liferay.portal.kernel.exception.SystemException {
304         getPersistence().removeByUserId(userId);
305     }
306 
307     public static void removeByG_U(long groupId, long userId)
308         throws com.liferay.portal.kernel.exception.SystemException,
309             com.liferay.portlet.messageboards.NoSuchStatsUserException {
310         getPersistence().removeByG_U(groupId, userId);
311     }
312 
313     public static void removeByG_M(long groupId, int messageCount)
314         throws com.liferay.portal.kernel.exception.SystemException {
315         getPersistence().removeByG_M(groupId, messageCount);
316     }
317 
318     public static void removeAll()
319         throws com.liferay.portal.kernel.exception.SystemException {
320         getPersistence().removeAll();
321     }
322 
323     public static int countByGroupId(long groupId)
324         throws com.liferay.portal.kernel.exception.SystemException {
325         return getPersistence().countByGroupId(groupId);
326     }
327 
328     public static int countByUserId(long userId)
329         throws com.liferay.portal.kernel.exception.SystemException {
330         return getPersistence().countByUserId(userId);
331     }
332 
333     public static int countByG_U(long groupId, long userId)
334         throws com.liferay.portal.kernel.exception.SystemException {
335         return getPersistence().countByG_U(groupId, userId);
336     }
337 
338     public static int countByG_M(long groupId, int messageCount)
339         throws com.liferay.portal.kernel.exception.SystemException {
340         return getPersistence().countByG_M(groupId, messageCount);
341     }
342 
343     public static int countAll()
344         throws com.liferay.portal.kernel.exception.SystemException {
345         return getPersistence().countAll();
346     }
347 
348     public static MBStatsUserPersistence getPersistence() {
349         if (_persistence == null) {
350             _persistence = (MBStatsUserPersistence)PortalBeanLocatorUtil.locate(MBStatsUserPersistence.class.getName());
351         }
352 
353         return _persistence;
354     }
355 
356     public void setPersistence(MBStatsUserPersistence persistence) {
357         _persistence = persistence;
358     }
359 
360     private static MBStatsUserPersistence _persistence;
361 }