1   /**
2    * Copyright (c) 2000-2009 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   * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
12   * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
13   * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
14   * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
15   * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
16   * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
17   * SOFTWARE.
18   */
19  
20  package com.liferay.portlet.imagegallery.service.persistence;
21  
22  /**
23   * <a href="IGFolderUtil.java.html"><b><i>View Source</i></b></a>
24   *
25   * @author Brian Wing Shun Chan
26   *
27   */
28  public class IGFolderUtil {
29      public static com.liferay.portlet.imagegallery.model.IGFolder create(
30          long folderId) {
31          return getPersistence().create(folderId);
32      }
33  
34      public static com.liferay.portlet.imagegallery.model.IGFolder remove(
35          long folderId)
36          throws com.liferay.portal.SystemException,
37              com.liferay.portlet.imagegallery.NoSuchFolderException {
38          return getPersistence().remove(folderId);
39      }
40  
41      public static com.liferay.portlet.imagegallery.model.IGFolder remove(
42          com.liferay.portlet.imagegallery.model.IGFolder igFolder)
43          throws com.liferay.portal.SystemException {
44          return getPersistence().remove(igFolder);
45      }
46  
47      /**
48       * @deprecated Use <code>update(IGFolder igFolder, boolean merge)</code>.
49       */
50      public static com.liferay.portlet.imagegallery.model.IGFolder update(
51          com.liferay.portlet.imagegallery.model.IGFolder igFolder)
52          throws com.liferay.portal.SystemException {
53          return getPersistence().update(igFolder);
54      }
55  
56      /**
57       * Add, update, or merge, the entity. This method also calls the model
58       * listeners to trigger the proper events associated with adding, deleting,
59       * or updating an entity.
60       *
61       * @param        igFolder the entity to add, update, or merge
62       * @param        merge boolean value for whether to merge the entity. The
63       *                default value is false. Setting merge to true is more
64       *                expensive and should only be true when igFolder is
65       *                transient. See LEP-5473 for a detailed discussion of this
66       *                method.
67       * @return        true if the portlet can be displayed via Ajax
68       */
69      public static com.liferay.portlet.imagegallery.model.IGFolder update(
70          com.liferay.portlet.imagegallery.model.IGFolder igFolder, boolean merge)
71          throws com.liferay.portal.SystemException {
72          return getPersistence().update(igFolder, merge);
73      }
74  
75      public static com.liferay.portlet.imagegallery.model.IGFolder updateImpl(
76          com.liferay.portlet.imagegallery.model.IGFolder igFolder, boolean merge)
77          throws com.liferay.portal.SystemException {
78          return getPersistence().updateImpl(igFolder, merge);
79      }
80  
81      public static com.liferay.portlet.imagegallery.model.IGFolder findByPrimaryKey(
82          long folderId)
83          throws com.liferay.portal.SystemException,
84              com.liferay.portlet.imagegallery.NoSuchFolderException {
85          return getPersistence().findByPrimaryKey(folderId);
86      }
87  
88      public static com.liferay.portlet.imagegallery.model.IGFolder fetchByPrimaryKey(
89          long folderId) throws com.liferay.portal.SystemException {
90          return getPersistence().fetchByPrimaryKey(folderId);
91      }
92  
93      public static java.util.List<com.liferay.portlet.imagegallery.model.IGFolder> findByUuid(
94          java.lang.String uuid) throws com.liferay.portal.SystemException {
95          return getPersistence().findByUuid(uuid);
96      }
97  
98      public static java.util.List<com.liferay.portlet.imagegallery.model.IGFolder> findByUuid(
99          java.lang.String uuid, int start, int end)
100         throws com.liferay.portal.SystemException {
101         return getPersistence().findByUuid(uuid, start, end);
102     }
103 
104     public static java.util.List<com.liferay.portlet.imagegallery.model.IGFolder> findByUuid(
105         java.lang.String uuid, int start, int end,
106         com.liferay.portal.kernel.util.OrderByComparator obc)
107         throws com.liferay.portal.SystemException {
108         return getPersistence().findByUuid(uuid, start, end, obc);
109     }
110 
111     public static com.liferay.portlet.imagegallery.model.IGFolder findByUuid_First(
112         java.lang.String uuid,
113         com.liferay.portal.kernel.util.OrderByComparator obc)
114         throws com.liferay.portal.SystemException,
115             com.liferay.portlet.imagegallery.NoSuchFolderException {
116         return getPersistence().findByUuid_First(uuid, obc);
117     }
118 
119     public static com.liferay.portlet.imagegallery.model.IGFolder findByUuid_Last(
120         java.lang.String uuid,
121         com.liferay.portal.kernel.util.OrderByComparator obc)
122         throws com.liferay.portal.SystemException,
123             com.liferay.portlet.imagegallery.NoSuchFolderException {
124         return getPersistence().findByUuid_Last(uuid, obc);
125     }
126 
127     public static com.liferay.portlet.imagegallery.model.IGFolder[] findByUuid_PrevAndNext(
128         long folderId, java.lang.String uuid,
129         com.liferay.portal.kernel.util.OrderByComparator obc)
130         throws com.liferay.portal.SystemException,
131             com.liferay.portlet.imagegallery.NoSuchFolderException {
132         return getPersistence().findByUuid_PrevAndNext(folderId, uuid, obc);
133     }
134 
135     public static com.liferay.portlet.imagegallery.model.IGFolder findByUUID_G(
136         java.lang.String uuid, long groupId)
137         throws com.liferay.portal.SystemException,
138             com.liferay.portlet.imagegallery.NoSuchFolderException {
139         return getPersistence().findByUUID_G(uuid, groupId);
140     }
141 
142     public static com.liferay.portlet.imagegallery.model.IGFolder fetchByUUID_G(
143         java.lang.String uuid, long groupId)
144         throws com.liferay.portal.SystemException {
145         return getPersistence().fetchByUUID_G(uuid, groupId);
146     }
147 
148     public static java.util.List<com.liferay.portlet.imagegallery.model.IGFolder> findByGroupId(
149         long groupId) throws com.liferay.portal.SystemException {
150         return getPersistence().findByGroupId(groupId);
151     }
152 
153     public static java.util.List<com.liferay.portlet.imagegallery.model.IGFolder> findByGroupId(
154         long groupId, int start, int end)
155         throws com.liferay.portal.SystemException {
156         return getPersistence().findByGroupId(groupId, start, end);
157     }
158 
159     public static java.util.List<com.liferay.portlet.imagegallery.model.IGFolder> findByGroupId(
160         long groupId, int start, int end,
161         com.liferay.portal.kernel.util.OrderByComparator obc)
162         throws com.liferay.portal.SystemException {
163         return getPersistence().findByGroupId(groupId, start, end, obc);
164     }
165 
166     public static com.liferay.portlet.imagegallery.model.IGFolder findByGroupId_First(
167         long groupId, com.liferay.portal.kernel.util.OrderByComparator obc)
168         throws com.liferay.portal.SystemException,
169             com.liferay.portlet.imagegallery.NoSuchFolderException {
170         return getPersistence().findByGroupId_First(groupId, obc);
171     }
172 
173     public static com.liferay.portlet.imagegallery.model.IGFolder findByGroupId_Last(
174         long groupId, com.liferay.portal.kernel.util.OrderByComparator obc)
175         throws com.liferay.portal.SystemException,
176             com.liferay.portlet.imagegallery.NoSuchFolderException {
177         return getPersistence().findByGroupId_Last(groupId, obc);
178     }
179 
180     public static com.liferay.portlet.imagegallery.model.IGFolder[] findByGroupId_PrevAndNext(
181         long folderId, long groupId,
182         com.liferay.portal.kernel.util.OrderByComparator obc)
183         throws com.liferay.portal.SystemException,
184             com.liferay.portlet.imagegallery.NoSuchFolderException {
185         return getPersistence().findByGroupId_PrevAndNext(folderId, groupId, obc);
186     }
187 
188     public static java.util.List<com.liferay.portlet.imagegallery.model.IGFolder> findByCompanyId(
189         long companyId) throws com.liferay.portal.SystemException {
190         return getPersistence().findByCompanyId(companyId);
191     }
192 
193     public static java.util.List<com.liferay.portlet.imagegallery.model.IGFolder> findByCompanyId(
194         long companyId, int start, int end)
195         throws com.liferay.portal.SystemException {
196         return getPersistence().findByCompanyId(companyId, start, end);
197     }
198 
199     public static java.util.List<com.liferay.portlet.imagegallery.model.IGFolder> findByCompanyId(
200         long companyId, int start, int end,
201         com.liferay.portal.kernel.util.OrderByComparator obc)
202         throws com.liferay.portal.SystemException {
203         return getPersistence().findByCompanyId(companyId, start, end, obc);
204     }
205 
206     public static com.liferay.portlet.imagegallery.model.IGFolder findByCompanyId_First(
207         long companyId, com.liferay.portal.kernel.util.OrderByComparator obc)
208         throws com.liferay.portal.SystemException,
209             com.liferay.portlet.imagegallery.NoSuchFolderException {
210         return getPersistence().findByCompanyId_First(companyId, obc);
211     }
212 
213     public static com.liferay.portlet.imagegallery.model.IGFolder findByCompanyId_Last(
214         long companyId, com.liferay.portal.kernel.util.OrderByComparator obc)
215         throws com.liferay.portal.SystemException,
216             com.liferay.portlet.imagegallery.NoSuchFolderException {
217         return getPersistence().findByCompanyId_Last(companyId, obc);
218     }
219 
220     public static com.liferay.portlet.imagegallery.model.IGFolder[] findByCompanyId_PrevAndNext(
221         long folderId, long companyId,
222         com.liferay.portal.kernel.util.OrderByComparator obc)
223         throws com.liferay.portal.SystemException,
224             com.liferay.portlet.imagegallery.NoSuchFolderException {
225         return getPersistence()
226                    .findByCompanyId_PrevAndNext(folderId, companyId, obc);
227     }
228 
229     public static java.util.List<com.liferay.portlet.imagegallery.model.IGFolder> findByG_P(
230         long groupId, long parentFolderId)
231         throws com.liferay.portal.SystemException {
232         return getPersistence().findByG_P(groupId, parentFolderId);
233     }
234 
235     public static java.util.List<com.liferay.portlet.imagegallery.model.IGFolder> findByG_P(
236         long groupId, long parentFolderId, int start, int end)
237         throws com.liferay.portal.SystemException {
238         return getPersistence().findByG_P(groupId, parentFolderId, start, end);
239     }
240 
241     public static java.util.List<com.liferay.portlet.imagegallery.model.IGFolder> findByG_P(
242         long groupId, long parentFolderId, int start, int end,
243         com.liferay.portal.kernel.util.OrderByComparator obc)
244         throws com.liferay.portal.SystemException {
245         return getPersistence()
246                    .findByG_P(groupId, parentFolderId, start, end, obc);
247     }
248 
249     public static com.liferay.portlet.imagegallery.model.IGFolder findByG_P_First(
250         long groupId, long parentFolderId,
251         com.liferay.portal.kernel.util.OrderByComparator obc)
252         throws com.liferay.portal.SystemException,
253             com.liferay.portlet.imagegallery.NoSuchFolderException {
254         return getPersistence().findByG_P_First(groupId, parentFolderId, obc);
255     }
256 
257     public static com.liferay.portlet.imagegallery.model.IGFolder findByG_P_Last(
258         long groupId, long parentFolderId,
259         com.liferay.portal.kernel.util.OrderByComparator obc)
260         throws com.liferay.portal.SystemException,
261             com.liferay.portlet.imagegallery.NoSuchFolderException {
262         return getPersistence().findByG_P_Last(groupId, parentFolderId, obc);
263     }
264 
265     public static com.liferay.portlet.imagegallery.model.IGFolder[] findByG_P_PrevAndNext(
266         long folderId, long groupId, long parentFolderId,
267         com.liferay.portal.kernel.util.OrderByComparator obc)
268         throws com.liferay.portal.SystemException,
269             com.liferay.portlet.imagegallery.NoSuchFolderException {
270         return getPersistence()
271                    .findByG_P_PrevAndNext(folderId, groupId, parentFolderId, obc);
272     }
273 
274     public static com.liferay.portlet.imagegallery.model.IGFolder findByG_P_N(
275         long groupId, long parentFolderId, java.lang.String name)
276         throws com.liferay.portal.SystemException,
277             com.liferay.portlet.imagegallery.NoSuchFolderException {
278         return getPersistence().findByG_P_N(groupId, parentFolderId, name);
279     }
280 
281     public static com.liferay.portlet.imagegallery.model.IGFolder fetchByG_P_N(
282         long groupId, long parentFolderId, java.lang.String name)
283         throws com.liferay.portal.SystemException {
284         return getPersistence().fetchByG_P_N(groupId, parentFolderId, name);
285     }
286 
287     public static java.util.List<Object> findWithDynamicQuery(
288         com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
289         throws com.liferay.portal.SystemException {
290         return getPersistence().findWithDynamicQuery(dynamicQuery);
291     }
292 
293     public static java.util.List<Object> findWithDynamicQuery(
294         com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
295         int end) throws com.liferay.portal.SystemException {
296         return getPersistence().findWithDynamicQuery(dynamicQuery, start, end);
297     }
298 
299     public static java.util.List<com.liferay.portlet.imagegallery.model.IGFolder> findAll()
300         throws com.liferay.portal.SystemException {
301         return getPersistence().findAll();
302     }
303 
304     public static java.util.List<com.liferay.portlet.imagegallery.model.IGFolder> findAll(
305         int start, int end) throws com.liferay.portal.SystemException {
306         return getPersistence().findAll(start, end);
307     }
308 
309     public static java.util.List<com.liferay.portlet.imagegallery.model.IGFolder> findAll(
310         int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
311         throws com.liferay.portal.SystemException {
312         return getPersistence().findAll(start, end, obc);
313     }
314 
315     public static void removeByUuid(java.lang.String uuid)
316         throws com.liferay.portal.SystemException {
317         getPersistence().removeByUuid(uuid);
318     }
319 
320     public static void removeByUUID_G(java.lang.String uuid, long groupId)
321         throws com.liferay.portal.SystemException,
322             com.liferay.portlet.imagegallery.NoSuchFolderException {
323         getPersistence().removeByUUID_G(uuid, groupId);
324     }
325 
326     public static void removeByGroupId(long groupId)
327         throws com.liferay.portal.SystemException {
328         getPersistence().removeByGroupId(groupId);
329     }
330 
331     public static void removeByCompanyId(long companyId)
332         throws com.liferay.portal.SystemException {
333         getPersistence().removeByCompanyId(companyId);
334     }
335 
336     public static void removeByG_P(long groupId, long parentFolderId)
337         throws com.liferay.portal.SystemException {
338         getPersistence().removeByG_P(groupId, parentFolderId);
339     }
340 
341     public static void removeByG_P_N(long groupId, long parentFolderId,
342         java.lang.String name)
343         throws com.liferay.portal.SystemException,
344             com.liferay.portlet.imagegallery.NoSuchFolderException {
345         getPersistence().removeByG_P_N(groupId, parentFolderId, name);
346     }
347 
348     public static void removeAll() throws com.liferay.portal.SystemException {
349         getPersistence().removeAll();
350     }
351 
352     public static int countByUuid(java.lang.String uuid)
353         throws com.liferay.portal.SystemException {
354         return getPersistence().countByUuid(uuid);
355     }
356 
357     public static int countByUUID_G(java.lang.String uuid, long groupId)
358         throws com.liferay.portal.SystemException {
359         return getPersistence().countByUUID_G(uuid, groupId);
360     }
361 
362     public static int countByGroupId(long groupId)
363         throws com.liferay.portal.SystemException {
364         return getPersistence().countByGroupId(groupId);
365     }
366 
367     public static int countByCompanyId(long companyId)
368         throws com.liferay.portal.SystemException {
369         return getPersistence().countByCompanyId(companyId);
370     }
371 
372     public static int countByG_P(long groupId, long parentFolderId)
373         throws com.liferay.portal.SystemException {
374         return getPersistence().countByG_P(groupId, parentFolderId);
375     }
376 
377     public static int countByG_P_N(long groupId, long parentFolderId,
378         java.lang.String name) throws com.liferay.portal.SystemException {
379         return getPersistence().countByG_P_N(groupId, parentFolderId, name);
380     }
381 
382     public static int countAll() throws com.liferay.portal.SystemException {
383         return getPersistence().countAll();
384     }
385 
386     public static IGFolderPersistence getPersistence() {
387         return _persistence;
388     }
389 
390     public void setPersistence(IGFolderPersistence persistence) {
391         _persistence = persistence;
392     }
393 
394     private static IGFolderPersistence _persistence;
395 }