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.MBMailingList;
22  
23  import java.util.List;
24  
25  /**
26   * <a href="MBMailingListUtil.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       MBMailingListPersistence
35   * @see       MBMailingListPersistenceImpl
36   * @generated
37   */
38  public class MBMailingListUtil {
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 MBMailingList remove(MBMailingList mbMailingList)
66          throws SystemException {
67          return getPersistence().remove(mbMailingList);
68      }
69  
70      /**
71       * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, boolean)
72       */
73      public static MBMailingList update(MBMailingList mbMailingList,
74          boolean merge) throws SystemException {
75          return getPersistence().update(mbMailingList, merge);
76      }
77  
78      public static void cacheResult(
79          com.liferay.portlet.messageboards.model.MBMailingList mbMailingList) {
80          getPersistence().cacheResult(mbMailingList);
81      }
82  
83      public static void cacheResult(
84          java.util.List<com.liferay.portlet.messageboards.model.MBMailingList> mbMailingLists) {
85          getPersistence().cacheResult(mbMailingLists);
86      }
87  
88      public static com.liferay.portlet.messageboards.model.MBMailingList create(
89          long mailingListId) {
90          return getPersistence().create(mailingListId);
91      }
92  
93      public static com.liferay.portlet.messageboards.model.MBMailingList remove(
94          long mailingListId)
95          throws com.liferay.portal.SystemException,
96              com.liferay.portlet.messageboards.NoSuchMailingListException {
97          return getPersistence().remove(mailingListId);
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.MBMailingList update(
104         com.liferay.portlet.messageboards.model.MBMailingList mbMailingList)
105         throws com.liferay.portal.SystemException {
106         return getPersistence().update(mbMailingList);
107     }
108 
109     public static com.liferay.portlet.messageboards.model.MBMailingList updateImpl(
110         com.liferay.portlet.messageboards.model.MBMailingList mbMailingList,
111         boolean merge) throws com.liferay.portal.SystemException {
112         return getPersistence().updateImpl(mbMailingList, merge);
113     }
114 
115     public static com.liferay.portlet.messageboards.model.MBMailingList findByPrimaryKey(
116         long mailingListId)
117         throws com.liferay.portal.SystemException,
118             com.liferay.portlet.messageboards.NoSuchMailingListException {
119         return getPersistence().findByPrimaryKey(mailingListId);
120     }
121 
122     public static com.liferay.portlet.messageboards.model.MBMailingList fetchByPrimaryKey(
123         long mailingListId) throws com.liferay.portal.SystemException {
124         return getPersistence().fetchByPrimaryKey(mailingListId);
125     }
126 
127     public static java.util.List<com.liferay.portlet.messageboards.model.MBMailingList> findByUuid(
128         java.lang.String uuid) throws com.liferay.portal.SystemException {
129         return getPersistence().findByUuid(uuid);
130     }
131 
132     public static java.util.List<com.liferay.portlet.messageboards.model.MBMailingList> findByUuid(
133         java.lang.String uuid, int start, int end)
134         throws com.liferay.portal.SystemException {
135         return getPersistence().findByUuid(uuid, start, end);
136     }
137 
138     public static java.util.List<com.liferay.portlet.messageboards.model.MBMailingList> findByUuid(
139         java.lang.String uuid, int start, int end,
140         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
141         throws com.liferay.portal.SystemException {
142         return getPersistence().findByUuid(uuid, start, end, orderByComparator);
143     }
144 
145     public static com.liferay.portlet.messageboards.model.MBMailingList findByUuid_First(
146         java.lang.String uuid,
147         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
148         throws com.liferay.portal.SystemException,
149             com.liferay.portlet.messageboards.NoSuchMailingListException {
150         return getPersistence().findByUuid_First(uuid, orderByComparator);
151     }
152 
153     public static com.liferay.portlet.messageboards.model.MBMailingList findByUuid_Last(
154         java.lang.String uuid,
155         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
156         throws com.liferay.portal.SystemException,
157             com.liferay.portlet.messageboards.NoSuchMailingListException {
158         return getPersistence().findByUuid_Last(uuid, orderByComparator);
159     }
160 
161     public static com.liferay.portlet.messageboards.model.MBMailingList[] findByUuid_PrevAndNext(
162         long mailingListId, java.lang.String uuid,
163         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
164         throws com.liferay.portal.SystemException,
165             com.liferay.portlet.messageboards.NoSuchMailingListException {
166         return getPersistence()
167                    .findByUuid_PrevAndNext(mailingListId, uuid,
168             orderByComparator);
169     }
170 
171     public static com.liferay.portlet.messageboards.model.MBMailingList findByUUID_G(
172         java.lang.String uuid, long groupId)
173         throws com.liferay.portal.SystemException,
174             com.liferay.portlet.messageboards.NoSuchMailingListException {
175         return getPersistence().findByUUID_G(uuid, groupId);
176     }
177 
178     public static com.liferay.portlet.messageboards.model.MBMailingList fetchByUUID_G(
179         java.lang.String uuid, long groupId)
180         throws com.liferay.portal.SystemException {
181         return getPersistence().fetchByUUID_G(uuid, groupId);
182     }
183 
184     public static com.liferay.portlet.messageboards.model.MBMailingList fetchByUUID_G(
185         java.lang.String uuid, long groupId, boolean retrieveFromCache)
186         throws com.liferay.portal.SystemException {
187         return getPersistence().fetchByUUID_G(uuid, groupId, retrieveFromCache);
188     }
189 
190     public static com.liferay.portlet.messageboards.model.MBMailingList findByCategoryId(
191         long categoryId)
192         throws com.liferay.portal.SystemException,
193             com.liferay.portlet.messageboards.NoSuchMailingListException {
194         return getPersistence().findByCategoryId(categoryId);
195     }
196 
197     public static com.liferay.portlet.messageboards.model.MBMailingList fetchByCategoryId(
198         long categoryId) throws com.liferay.portal.SystemException {
199         return getPersistence().fetchByCategoryId(categoryId);
200     }
201 
202     public static com.liferay.portlet.messageboards.model.MBMailingList fetchByCategoryId(
203         long categoryId, boolean retrieveFromCache)
204         throws com.liferay.portal.SystemException {
205         return getPersistence().fetchByCategoryId(categoryId, retrieveFromCache);
206     }
207 
208     public static java.util.List<com.liferay.portlet.messageboards.model.MBMailingList> findByActive(
209         boolean active) throws com.liferay.portal.SystemException {
210         return getPersistence().findByActive(active);
211     }
212 
213     public static java.util.List<com.liferay.portlet.messageboards.model.MBMailingList> findByActive(
214         boolean active, int start, int end)
215         throws com.liferay.portal.SystemException {
216         return getPersistence().findByActive(active, start, end);
217     }
218 
219     public static java.util.List<com.liferay.portlet.messageboards.model.MBMailingList> findByActive(
220         boolean active, int start, int end,
221         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
222         throws com.liferay.portal.SystemException {
223         return getPersistence()
224                    .findByActive(active, start, end, orderByComparator);
225     }
226 
227     public static com.liferay.portlet.messageboards.model.MBMailingList findByActive_First(
228         boolean active,
229         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
230         throws com.liferay.portal.SystemException,
231             com.liferay.portlet.messageboards.NoSuchMailingListException {
232         return getPersistence().findByActive_First(active, orderByComparator);
233     }
234 
235     public static com.liferay.portlet.messageboards.model.MBMailingList findByActive_Last(
236         boolean active,
237         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
238         throws com.liferay.portal.SystemException,
239             com.liferay.portlet.messageboards.NoSuchMailingListException {
240         return getPersistence().findByActive_Last(active, orderByComparator);
241     }
242 
243     public static com.liferay.portlet.messageboards.model.MBMailingList[] findByActive_PrevAndNext(
244         long mailingListId, boolean active,
245         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
246         throws com.liferay.portal.SystemException,
247             com.liferay.portlet.messageboards.NoSuchMailingListException {
248         return getPersistence()
249                    .findByActive_PrevAndNext(mailingListId, active,
250             orderByComparator);
251     }
252 
253     public static java.util.List<com.liferay.portlet.messageboards.model.MBMailingList> findAll()
254         throws com.liferay.portal.SystemException {
255         return getPersistence().findAll();
256     }
257 
258     public static java.util.List<com.liferay.portlet.messageboards.model.MBMailingList> findAll(
259         int start, int end) throws com.liferay.portal.SystemException {
260         return getPersistence().findAll(start, end);
261     }
262 
263     public static java.util.List<com.liferay.portlet.messageboards.model.MBMailingList> findAll(
264         int start, int end,
265         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
266         throws com.liferay.portal.SystemException {
267         return getPersistence().findAll(start, end, orderByComparator);
268     }
269 
270     public static void removeByUuid(java.lang.String uuid)
271         throws com.liferay.portal.SystemException {
272         getPersistence().removeByUuid(uuid);
273     }
274 
275     public static void removeByUUID_G(java.lang.String uuid, long groupId)
276         throws com.liferay.portal.SystemException,
277             com.liferay.portlet.messageboards.NoSuchMailingListException {
278         getPersistence().removeByUUID_G(uuid, groupId);
279     }
280 
281     public static void removeByCategoryId(long categoryId)
282         throws com.liferay.portal.SystemException,
283             com.liferay.portlet.messageboards.NoSuchMailingListException {
284         getPersistence().removeByCategoryId(categoryId);
285     }
286 
287     public static void removeByActive(boolean active)
288         throws com.liferay.portal.SystemException {
289         getPersistence().removeByActive(active);
290     }
291 
292     public static void removeAll() throws com.liferay.portal.SystemException {
293         getPersistence().removeAll();
294     }
295 
296     public static int countByUuid(java.lang.String uuid)
297         throws com.liferay.portal.SystemException {
298         return getPersistence().countByUuid(uuid);
299     }
300 
301     public static int countByUUID_G(java.lang.String uuid, long groupId)
302         throws com.liferay.portal.SystemException {
303         return getPersistence().countByUUID_G(uuid, groupId);
304     }
305 
306     public static int countByCategoryId(long categoryId)
307         throws com.liferay.portal.SystemException {
308         return getPersistence().countByCategoryId(categoryId);
309     }
310 
311     public static int countByActive(boolean active)
312         throws com.liferay.portal.SystemException {
313         return getPersistence().countByActive(active);
314     }
315 
316     public static int countAll() throws com.liferay.portal.SystemException {
317         return getPersistence().countAll();
318     }
319 
320     public static MBMailingListPersistence getPersistence() {
321         if (_persistence == null) {
322             _persistence = (MBMailingListPersistence)PortalBeanLocatorUtil.locate(MBMailingListPersistence.class.getName());
323         }
324 
325         return _persistence;
326     }
327 
328     public void setPersistence(MBMailingListPersistence persistence) {
329         _persistence = persistence;
330     }
331 
332     private static MBMailingListPersistence _persistence;
333 }