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.ratings.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.ratings.model.RatingsEntry;
22  
23  import java.util.List;
24  
25  /**
26   * <a href="RatingsEntryUtil.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       RatingsEntryPersistence
35   * @see       RatingsEntryPersistenceImpl
36   * @generated
37   */
38  public class RatingsEntryUtil {
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 RatingsEntry remove(RatingsEntry ratingsEntry)
66          throws SystemException {
67          return getPersistence().remove(ratingsEntry);
68      }
69  
70      /**
71       * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, boolean)
72       */
73      public static RatingsEntry update(RatingsEntry ratingsEntry, boolean merge)
74          throws SystemException {
75          return getPersistence().update(ratingsEntry, merge);
76      }
77  
78      public static void cacheResult(
79          com.liferay.portlet.ratings.model.RatingsEntry ratingsEntry) {
80          getPersistence().cacheResult(ratingsEntry);
81      }
82  
83      public static void cacheResult(
84          java.util.List<com.liferay.portlet.ratings.model.RatingsEntry> ratingsEntries) {
85          getPersistence().cacheResult(ratingsEntries);
86      }
87  
88      public static com.liferay.portlet.ratings.model.RatingsEntry create(
89          long entryId) {
90          return getPersistence().create(entryId);
91      }
92  
93      public static com.liferay.portlet.ratings.model.RatingsEntry remove(
94          long entryId)
95          throws com.liferay.portal.SystemException,
96              com.liferay.portlet.ratings.NoSuchEntryException {
97          return getPersistence().remove(entryId);
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.ratings.model.RatingsEntry update(
104         com.liferay.portlet.ratings.model.RatingsEntry ratingsEntry)
105         throws com.liferay.portal.SystemException {
106         return getPersistence().update(ratingsEntry);
107     }
108 
109     public static com.liferay.portlet.ratings.model.RatingsEntry updateImpl(
110         com.liferay.portlet.ratings.model.RatingsEntry ratingsEntry,
111         boolean merge) throws com.liferay.portal.SystemException {
112         return getPersistence().updateImpl(ratingsEntry, merge);
113     }
114 
115     public static com.liferay.portlet.ratings.model.RatingsEntry findByPrimaryKey(
116         long entryId)
117         throws com.liferay.portal.SystemException,
118             com.liferay.portlet.ratings.NoSuchEntryException {
119         return getPersistence().findByPrimaryKey(entryId);
120     }
121 
122     public static com.liferay.portlet.ratings.model.RatingsEntry fetchByPrimaryKey(
123         long entryId) throws com.liferay.portal.SystemException {
124         return getPersistence().fetchByPrimaryKey(entryId);
125     }
126 
127     public static java.util.List<com.liferay.portlet.ratings.model.RatingsEntry> findByC_C(
128         long classNameId, long classPK)
129         throws com.liferay.portal.SystemException {
130         return getPersistence().findByC_C(classNameId, classPK);
131     }
132 
133     public static java.util.List<com.liferay.portlet.ratings.model.RatingsEntry> findByC_C(
134         long classNameId, long classPK, int start, int end)
135         throws com.liferay.portal.SystemException {
136         return getPersistence().findByC_C(classNameId, classPK, start, end);
137     }
138 
139     public static java.util.List<com.liferay.portlet.ratings.model.RatingsEntry> findByC_C(
140         long classNameId, long classPK, int start, int end,
141         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
142         throws com.liferay.portal.SystemException {
143         return getPersistence()
144                    .findByC_C(classNameId, classPK, start, end,
145             orderByComparator);
146     }
147 
148     public static com.liferay.portlet.ratings.model.RatingsEntry findByC_C_First(
149         long classNameId, long classPK,
150         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
151         throws com.liferay.portal.SystemException,
152             com.liferay.portlet.ratings.NoSuchEntryException {
153         return getPersistence()
154                    .findByC_C_First(classNameId, classPK, orderByComparator);
155     }
156 
157     public static com.liferay.portlet.ratings.model.RatingsEntry findByC_C_Last(
158         long classNameId, long classPK,
159         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
160         throws com.liferay.portal.SystemException,
161             com.liferay.portlet.ratings.NoSuchEntryException {
162         return getPersistence()
163                    .findByC_C_Last(classNameId, classPK, orderByComparator);
164     }
165 
166     public static com.liferay.portlet.ratings.model.RatingsEntry[] findByC_C_PrevAndNext(
167         long entryId, long classNameId, long classPK,
168         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
169         throws com.liferay.portal.SystemException,
170             com.liferay.portlet.ratings.NoSuchEntryException {
171         return getPersistence()
172                    .findByC_C_PrevAndNext(entryId, classNameId, classPK,
173             orderByComparator);
174     }
175 
176     public static com.liferay.portlet.ratings.model.RatingsEntry findByU_C_C(
177         long userId, long classNameId, long classPK)
178         throws com.liferay.portal.SystemException,
179             com.liferay.portlet.ratings.NoSuchEntryException {
180         return getPersistence().findByU_C_C(userId, classNameId, classPK);
181     }
182 
183     public static com.liferay.portlet.ratings.model.RatingsEntry fetchByU_C_C(
184         long userId, long classNameId, long classPK)
185         throws com.liferay.portal.SystemException {
186         return getPersistence().fetchByU_C_C(userId, classNameId, classPK);
187     }
188 
189     public static com.liferay.portlet.ratings.model.RatingsEntry fetchByU_C_C(
190         long userId, long classNameId, long classPK, boolean retrieveFromCache)
191         throws com.liferay.portal.SystemException {
192         return getPersistence()
193                    .fetchByU_C_C(userId, classNameId, classPK, retrieveFromCache);
194     }
195 
196     public static java.util.List<com.liferay.portlet.ratings.model.RatingsEntry> findAll()
197         throws com.liferay.portal.SystemException {
198         return getPersistence().findAll();
199     }
200 
201     public static java.util.List<com.liferay.portlet.ratings.model.RatingsEntry> findAll(
202         int start, int end) throws com.liferay.portal.SystemException {
203         return getPersistence().findAll(start, end);
204     }
205 
206     public static java.util.List<com.liferay.portlet.ratings.model.RatingsEntry> findAll(
207         int start, int end,
208         com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
209         throws com.liferay.portal.SystemException {
210         return getPersistence().findAll(start, end, orderByComparator);
211     }
212 
213     public static void removeByC_C(long classNameId, long classPK)
214         throws com.liferay.portal.SystemException {
215         getPersistence().removeByC_C(classNameId, classPK);
216     }
217 
218     public static void removeByU_C_C(long userId, long classNameId, long classPK)
219         throws com.liferay.portal.SystemException,
220             com.liferay.portlet.ratings.NoSuchEntryException {
221         getPersistence().removeByU_C_C(userId, classNameId, classPK);
222     }
223 
224     public static void removeAll() throws com.liferay.portal.SystemException {
225         getPersistence().removeAll();
226     }
227 
228     public static int countByC_C(long classNameId, long classPK)
229         throws com.liferay.portal.SystemException {
230         return getPersistence().countByC_C(classNameId, classPK);
231     }
232 
233     public static int countByU_C_C(long userId, long classNameId, long classPK)
234         throws com.liferay.portal.SystemException {
235         return getPersistence().countByU_C_C(userId, classNameId, classPK);
236     }
237 
238     public static int countAll() throws com.liferay.portal.SystemException {
239         return getPersistence().countAll();
240     }
241 
242     public static RatingsEntryPersistence getPersistence() {
243         if (_persistence == null) {
244             _persistence = (RatingsEntryPersistence)PortalBeanLocatorUtil.locate(RatingsEntryPersistence.class.getName());
245         }
246 
247         return _persistence;
248     }
249 
250     public void setPersistence(RatingsEntryPersistence persistence) {
251         _persistence = persistence;
252     }
253 
254     private static RatingsEntryPersistence _persistence;
255 }