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