1   /**
2    * Copyright (c) 2000-2010 Liferay, Inc. All rights reserved.
3    *
4    * The contents of this file are subject to the terms of the Liferay Enterprise
5    * Subscription License ("License"). You may not use this file except in
6    * compliance with the License. You can obtain a copy of the License by
7    * contacting Liferay, Inc. See the License for the specific language governing
8    * permissions and limitations under the License, including but not limited to
9    * distribution rights of the Software.
10   *
11   *
12   * 
13   */
14  
15  package com.liferay.portlet.messageboards.service.persistence;
16  
17  import com.liferay.portal.SystemException;
18  import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
19  import com.liferay.portal.kernel.dao.orm.DynamicQuery;
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.SystemException,
96              com.liferay.portlet.messageboards.NoSuchStatsUserException {
97          return getPersistence().remove(statsUserId);
98      }
99  
100     /**
101      * @deprecated Use {@link com.liferay.portal.service.persistence.BasePersistence.#update(com.liferay.portal.model.BaseModel, boolean)}.
102      */
103     public static com.liferay.portlet.messageboards.model.MBStatsUser update(
104         com.liferay.portlet.messageboards.model.MBStatsUser mbStatsUser)
105         throws com.liferay.portal.SystemException {
106         return getPersistence().update(mbStatsUser);
107     }
108 
109     public static com.liferay.portlet.messageboards.model.MBStatsUser updateImpl(
110         com.liferay.portlet.messageboards.model.MBStatsUser mbStatsUser,
111         boolean merge) throws com.liferay.portal.SystemException {
112         return getPersistence().updateImpl(mbStatsUser, merge);
113     }
114 
115     public static com.liferay.portlet.messageboards.model.MBStatsUser findByPrimaryKey(
116         long statsUserId)
117         throws com.liferay.portal.SystemException,
118             com.liferay.portlet.messageboards.NoSuchStatsUserException {
119         return getPersistence().findByPrimaryKey(statsUserId);
120     }
121 
122     public static com.liferay.portlet.messageboards.model.MBStatsUser fetchByPrimaryKey(
123         long statsUserId) throws com.liferay.portal.SystemException {
124         return getPersistence().fetchByPrimaryKey(statsUserId);
125     }
126 
127     public static java.util.List<com.liferay.portlet.messageboards.model.MBStatsUser> findByGroupId(
128         long groupId) throws com.liferay.portal.SystemException {
129         return getPersistence().findByGroupId(groupId);
130     }
131 
132     public static java.util.List<com.liferay.portlet.messageboards.model.MBStatsUser> findByGroupId(
133         long groupId, int start, int end)
134         throws com.liferay.portal.SystemException {
135         return getPersistence().findByGroupId(groupId, start, end);
136     }
137 
138     public static java.util.List<com.liferay.portlet.messageboards.model.MBStatsUser> findByGroupId(
139         long groupId, int start, int end,
140         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
141         throws com.liferay.portal.SystemException {
142         return getPersistence()
143                    .findByGroupId(groupId, start, end, orderByComparator);
144     }
145 
146     public static com.liferay.portlet.messageboards.model.MBStatsUser findByGroupId_First(
147         long groupId,
148         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
149         throws com.liferay.portal.SystemException,
150             com.liferay.portlet.messageboards.NoSuchStatsUserException {
151         return getPersistence().findByGroupId_First(groupId, orderByComparator);
152     }
153 
154     public static com.liferay.portlet.messageboards.model.MBStatsUser findByGroupId_Last(
155         long groupId,
156         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
157         throws com.liferay.portal.SystemException,
158             com.liferay.portlet.messageboards.NoSuchStatsUserException {
159         return getPersistence().findByGroupId_Last(groupId, orderByComparator);
160     }
161 
162     public static com.liferay.portlet.messageboards.model.MBStatsUser[] findByGroupId_PrevAndNext(
163         long statsUserId, long groupId,
164         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
165         throws com.liferay.portal.SystemException,
166             com.liferay.portlet.messageboards.NoSuchStatsUserException {
167         return getPersistence()
168                    .findByGroupId_PrevAndNext(statsUserId, groupId,
169             orderByComparator);
170     }
171 
172     public static java.util.List<com.liferay.portlet.messageboards.model.MBStatsUser> findByUserId(
173         long userId) throws com.liferay.portal.SystemException {
174         return getPersistence().findByUserId(userId);
175     }
176 
177     public static java.util.List<com.liferay.portlet.messageboards.model.MBStatsUser> findByUserId(
178         long userId, int start, int end)
179         throws com.liferay.portal.SystemException {
180         return getPersistence().findByUserId(userId, start, end);
181     }
182 
183     public static java.util.List<com.liferay.portlet.messageboards.model.MBStatsUser> findByUserId(
184         long userId, int start, int end,
185         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
186         throws com.liferay.portal.SystemException {
187         return getPersistence()
188                    .findByUserId(userId, start, end, orderByComparator);
189     }
190 
191     public static com.liferay.portlet.messageboards.model.MBStatsUser findByUserId_First(
192         long userId,
193         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
194         throws com.liferay.portal.SystemException,
195             com.liferay.portlet.messageboards.NoSuchStatsUserException {
196         return getPersistence().findByUserId_First(userId, orderByComparator);
197     }
198 
199     public static com.liferay.portlet.messageboards.model.MBStatsUser findByUserId_Last(
200         long userId,
201         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
202         throws com.liferay.portal.SystemException,
203             com.liferay.portlet.messageboards.NoSuchStatsUserException {
204         return getPersistence().findByUserId_Last(userId, orderByComparator);
205     }
206 
207     public static com.liferay.portlet.messageboards.model.MBStatsUser[] findByUserId_PrevAndNext(
208         long statsUserId, long userId,
209         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
210         throws com.liferay.portal.SystemException,
211             com.liferay.portlet.messageboards.NoSuchStatsUserException {
212         return getPersistence()
213                    .findByUserId_PrevAndNext(statsUserId, userId,
214             orderByComparator);
215     }
216 
217     public static com.liferay.portlet.messageboards.model.MBStatsUser findByG_U(
218         long groupId, long userId)
219         throws com.liferay.portal.SystemException,
220             com.liferay.portlet.messageboards.NoSuchStatsUserException {
221         return getPersistence().findByG_U(groupId, userId);
222     }
223 
224     public static com.liferay.portlet.messageboards.model.MBStatsUser fetchByG_U(
225         long groupId, long userId) throws com.liferay.portal.SystemException {
226         return getPersistence().fetchByG_U(groupId, userId);
227     }
228 
229     public static com.liferay.portlet.messageboards.model.MBStatsUser fetchByG_U(
230         long groupId, long userId, boolean retrieveFromCache)
231         throws com.liferay.portal.SystemException {
232         return getPersistence().fetchByG_U(groupId, userId, retrieveFromCache);
233     }
234 
235     public static java.util.List<com.liferay.portlet.messageboards.model.MBStatsUser> findByG_M(
236         long groupId, int messageCount)
237         throws com.liferay.portal.SystemException {
238         return getPersistence().findByG_M(groupId, messageCount);
239     }
240 
241     public static java.util.List<com.liferay.portlet.messageboards.model.MBStatsUser> findByG_M(
242         long groupId, int messageCount, int start, int end)
243         throws com.liferay.portal.SystemException {
244         return getPersistence().findByG_M(groupId, messageCount, start, end);
245     }
246 
247     public static java.util.List<com.liferay.portlet.messageboards.model.MBStatsUser> findByG_M(
248         long groupId, int messageCount, int start, int end,
249         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
250         throws com.liferay.portal.SystemException {
251         return getPersistence()
252                    .findByG_M(groupId, messageCount, start, end,
253             orderByComparator);
254     }
255 
256     public static com.liferay.portlet.messageboards.model.MBStatsUser findByG_M_First(
257         long groupId, int messageCount,
258         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
259         throws com.liferay.portal.SystemException,
260             com.liferay.portlet.messageboards.NoSuchStatsUserException {
261         return getPersistence()
262                    .findByG_M_First(groupId, messageCount, orderByComparator);
263     }
264 
265     public static com.liferay.portlet.messageboards.model.MBStatsUser findByG_M_Last(
266         long groupId, int messageCount,
267         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
268         throws com.liferay.portal.SystemException,
269             com.liferay.portlet.messageboards.NoSuchStatsUserException {
270         return getPersistence()
271                    .findByG_M_Last(groupId, messageCount, orderByComparator);
272     }
273 
274     public static com.liferay.portlet.messageboards.model.MBStatsUser[] findByG_M_PrevAndNext(
275         long statsUserId, long groupId, int messageCount,
276         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
277         throws com.liferay.portal.SystemException,
278             com.liferay.portlet.messageboards.NoSuchStatsUserException {
279         return getPersistence()
280                    .findByG_M_PrevAndNext(statsUserId, groupId, messageCount,
281             orderByComparator);
282     }
283 
284     public static java.util.List<com.liferay.portlet.messageboards.model.MBStatsUser> findAll()
285         throws com.liferay.portal.SystemException {
286         return getPersistence().findAll();
287     }
288 
289     public static java.util.List<com.liferay.portlet.messageboards.model.MBStatsUser> findAll(
290         int start, int end) throws com.liferay.portal.SystemException {
291         return getPersistence().findAll(start, end);
292     }
293 
294     public static java.util.List<com.liferay.portlet.messageboards.model.MBStatsUser> findAll(
295         int start, int end,
296         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
297         throws com.liferay.portal.SystemException {
298         return getPersistence().findAll(start, end, orderByComparator);
299     }
300 
301     public static void removeByGroupId(long groupId)
302         throws com.liferay.portal.SystemException {
303         getPersistence().removeByGroupId(groupId);
304     }
305 
306     public static void removeByUserId(long userId)
307         throws com.liferay.portal.SystemException {
308         getPersistence().removeByUserId(userId);
309     }
310 
311     public static void removeByG_U(long groupId, long userId)
312         throws com.liferay.portal.SystemException,
313             com.liferay.portlet.messageboards.NoSuchStatsUserException {
314         getPersistence().removeByG_U(groupId, userId);
315     }
316 
317     public static void removeByG_M(long groupId, int messageCount)
318         throws com.liferay.portal.SystemException {
319         getPersistence().removeByG_M(groupId, messageCount);
320     }
321 
322     public static void removeAll() throws com.liferay.portal.SystemException {
323         getPersistence().removeAll();
324     }
325 
326     public static int countByGroupId(long groupId)
327         throws com.liferay.portal.SystemException {
328         return getPersistence().countByGroupId(groupId);
329     }
330 
331     public static int countByUserId(long userId)
332         throws com.liferay.portal.SystemException {
333         return getPersistence().countByUserId(userId);
334     }
335 
336     public static int countByG_U(long groupId, long userId)
337         throws com.liferay.portal.SystemException {
338         return getPersistence().countByG_U(groupId, userId);
339     }
340 
341     public static int countByG_M(long groupId, int messageCount)
342         throws com.liferay.portal.SystemException {
343         return getPersistence().countByG_M(groupId, messageCount);
344     }
345 
346     public static int countAll() throws com.liferay.portal.SystemException {
347         return getPersistence().countAll();
348     }
349 
350     public static MBStatsUserPersistence getPersistence() {
351         if (_persistence == null) {
352             _persistence = (MBStatsUserPersistence)PortalBeanLocatorUtil.locate(MBStatsUserPersistence.class.getName());
353         }
354 
355         return _persistence;
356     }
357 
358     public void setPersistence(MBStatsUserPersistence persistence) {
359         _persistence = persistence;
360     }
361 
362     private static MBStatsUserPersistence _persistence;
363 }