1   /**
2    * Copyright (c) 2000-2008 Liferay, Inc. All rights reserved.
3    *
4    * Permission is hereby granted, free of charge, to any person obtaining a copy
5    * of this software and associated documentation files (the "Software"), to deal
6    * in the Software without restriction, including without limitation the rights
7    * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
8    * copies of the Software, and to permit persons to whom the Software is
9    * furnished to do so, subject to the following conditions:
10   *
11   * The above copyright notice and this permission notice shall be included in
12   * all copies or substantial portions of the Software.
13   *
14   * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15   * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16   * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
17   * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
18   * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
19   * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
20   * SOFTWARE.
21   */
22  
23  package com.liferay.portlet.journal.service.persistence;
24  
25  /**
26   * <a href="JournalTemplateUtil.java.html"><b><i>View Source</i></b></a>
27   *
28   * @author Brian Wing Shun Chan
29   *
30   */
31  public class JournalTemplateUtil {
32      public static com.liferay.portlet.journal.model.JournalTemplate create(
33          long id) {
34          return getPersistence().create(id);
35      }
36  
37      public static com.liferay.portlet.journal.model.JournalTemplate remove(
38          long id)
39          throws com.liferay.portal.SystemException, 
40              com.liferay.portlet.journal.NoSuchTemplateException {
41          return getPersistence().remove(id);
42      }
43  
44      public static com.liferay.portlet.journal.model.JournalTemplate remove(
45          com.liferay.portlet.journal.model.JournalTemplate journalTemplate)
46          throws com.liferay.portal.SystemException {
47          return getPersistence().remove(journalTemplate);
48      }
49  
50      public static com.liferay.portlet.journal.model.JournalTemplate update(
51          com.liferay.portlet.journal.model.JournalTemplate journalTemplate)
52          throws com.liferay.portal.SystemException {
53          return getPersistence().update(journalTemplate);
54      }
55  
56      public static com.liferay.portlet.journal.model.JournalTemplate update(
57          com.liferay.portlet.journal.model.JournalTemplate journalTemplate,
58          boolean merge) throws com.liferay.portal.SystemException {
59          return getPersistence().update(journalTemplate, merge);
60      }
61  
62      public static com.liferay.portlet.journal.model.JournalTemplate updateImpl(
63          com.liferay.portlet.journal.model.JournalTemplate journalTemplate,
64          boolean merge) throws com.liferay.portal.SystemException {
65          return getPersistence().updateImpl(journalTemplate, merge);
66      }
67  
68      public static com.liferay.portlet.journal.model.JournalTemplate findByPrimaryKey(
69          long id)
70          throws com.liferay.portal.SystemException, 
71              com.liferay.portlet.journal.NoSuchTemplateException {
72          return getPersistence().findByPrimaryKey(id);
73      }
74  
75      public static com.liferay.portlet.journal.model.JournalTemplate fetchByPrimaryKey(
76          long id) throws com.liferay.portal.SystemException {
77          return getPersistence().fetchByPrimaryKey(id);
78      }
79  
80      public static java.util.List findByUuid(java.lang.String uuid)
81          throws com.liferay.portal.SystemException {
82          return getPersistence().findByUuid(uuid);
83      }
84  
85      public static java.util.List findByUuid(java.lang.String uuid, int begin,
86          int end) throws com.liferay.portal.SystemException {
87          return getPersistence().findByUuid(uuid, begin, end);
88      }
89  
90      public static java.util.List findByUuid(java.lang.String uuid, int begin,
91          int end, com.liferay.portal.kernel.util.OrderByComparator obc)
92          throws com.liferay.portal.SystemException {
93          return getPersistence().findByUuid(uuid, begin, end, obc);
94      }
95  
96      public static com.liferay.portlet.journal.model.JournalTemplate findByUuid_First(
97          java.lang.String uuid,
98          com.liferay.portal.kernel.util.OrderByComparator obc)
99          throws com.liferay.portal.SystemException, 
100             com.liferay.portlet.journal.NoSuchTemplateException {
101         return getPersistence().findByUuid_First(uuid, obc);
102     }
103 
104     public static com.liferay.portlet.journal.model.JournalTemplate findByUuid_Last(
105         java.lang.String uuid,
106         com.liferay.portal.kernel.util.OrderByComparator obc)
107         throws com.liferay.portal.SystemException, 
108             com.liferay.portlet.journal.NoSuchTemplateException {
109         return getPersistence().findByUuid_Last(uuid, obc);
110     }
111 
112     public static com.liferay.portlet.journal.model.JournalTemplate[] findByUuid_PrevAndNext(
113         long id, java.lang.String uuid,
114         com.liferay.portal.kernel.util.OrderByComparator obc)
115         throws com.liferay.portal.SystemException, 
116             com.liferay.portlet.journal.NoSuchTemplateException {
117         return getPersistence().findByUuid_PrevAndNext(id, uuid, obc);
118     }
119 
120     public static com.liferay.portlet.journal.model.JournalTemplate findByUUID_G(
121         java.lang.String uuid, long groupId)
122         throws com.liferay.portal.SystemException, 
123             com.liferay.portlet.journal.NoSuchTemplateException {
124         return getPersistence().findByUUID_G(uuid, groupId);
125     }
126 
127     public static com.liferay.portlet.journal.model.JournalTemplate fetchByUUID_G(
128         java.lang.String uuid, long groupId)
129         throws com.liferay.portal.SystemException {
130         return getPersistence().fetchByUUID_G(uuid, groupId);
131     }
132 
133     public static java.util.List findByGroupId(long groupId)
134         throws com.liferay.portal.SystemException {
135         return getPersistence().findByGroupId(groupId);
136     }
137 
138     public static java.util.List findByGroupId(long groupId, int begin, int end)
139         throws com.liferay.portal.SystemException {
140         return getPersistence().findByGroupId(groupId, begin, end);
141     }
142 
143     public static java.util.List findByGroupId(long groupId, int begin,
144         int end, com.liferay.portal.kernel.util.OrderByComparator obc)
145         throws com.liferay.portal.SystemException {
146         return getPersistence().findByGroupId(groupId, begin, end, obc);
147     }
148 
149     public static com.liferay.portlet.journal.model.JournalTemplate findByGroupId_First(
150         long groupId, com.liferay.portal.kernel.util.OrderByComparator obc)
151         throws com.liferay.portal.SystemException, 
152             com.liferay.portlet.journal.NoSuchTemplateException {
153         return getPersistence().findByGroupId_First(groupId, obc);
154     }
155 
156     public static com.liferay.portlet.journal.model.JournalTemplate findByGroupId_Last(
157         long groupId, com.liferay.portal.kernel.util.OrderByComparator obc)
158         throws com.liferay.portal.SystemException, 
159             com.liferay.portlet.journal.NoSuchTemplateException {
160         return getPersistence().findByGroupId_Last(groupId, obc);
161     }
162 
163     public static com.liferay.portlet.journal.model.JournalTemplate[] findByGroupId_PrevAndNext(
164         long id, long groupId,
165         com.liferay.portal.kernel.util.OrderByComparator obc)
166         throws com.liferay.portal.SystemException, 
167             com.liferay.portlet.journal.NoSuchTemplateException {
168         return getPersistence().findByGroupId_PrevAndNext(id, groupId, obc);
169     }
170 
171     public static java.util.List findByTemplateId(java.lang.String templateId)
172         throws com.liferay.portal.SystemException {
173         return getPersistence().findByTemplateId(templateId);
174     }
175 
176     public static java.util.List findByTemplateId(java.lang.String templateId,
177         int begin, int end) throws com.liferay.portal.SystemException {
178         return getPersistence().findByTemplateId(templateId, begin, end);
179     }
180 
181     public static java.util.List findByTemplateId(java.lang.String templateId,
182         int begin, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
183         throws com.liferay.portal.SystemException {
184         return getPersistence().findByTemplateId(templateId, begin, end, obc);
185     }
186 
187     public static com.liferay.portlet.journal.model.JournalTemplate findByTemplateId_First(
188         java.lang.String templateId,
189         com.liferay.portal.kernel.util.OrderByComparator obc)
190         throws com.liferay.portal.SystemException, 
191             com.liferay.portlet.journal.NoSuchTemplateException {
192         return getPersistence().findByTemplateId_First(templateId, obc);
193     }
194 
195     public static com.liferay.portlet.journal.model.JournalTemplate findByTemplateId_Last(
196         java.lang.String templateId,
197         com.liferay.portal.kernel.util.OrderByComparator obc)
198         throws com.liferay.portal.SystemException, 
199             com.liferay.portlet.journal.NoSuchTemplateException {
200         return getPersistence().findByTemplateId_Last(templateId, obc);
201     }
202 
203     public static com.liferay.portlet.journal.model.JournalTemplate[] findByTemplateId_PrevAndNext(
204         long id, java.lang.String templateId,
205         com.liferay.portal.kernel.util.OrderByComparator obc)
206         throws com.liferay.portal.SystemException, 
207             com.liferay.portlet.journal.NoSuchTemplateException {
208         return getPersistence().findByTemplateId_PrevAndNext(id, templateId, obc);
209     }
210 
211     public static com.liferay.portlet.journal.model.JournalTemplate findBySmallImageId(
212         long smallImageId)
213         throws com.liferay.portal.SystemException, 
214             com.liferay.portlet.journal.NoSuchTemplateException {
215         return getPersistence().findBySmallImageId(smallImageId);
216     }
217 
218     public static com.liferay.portlet.journal.model.JournalTemplate fetchBySmallImageId(
219         long smallImageId) throws com.liferay.portal.SystemException {
220         return getPersistence().fetchBySmallImageId(smallImageId);
221     }
222 
223     public static com.liferay.portlet.journal.model.JournalTemplate findByG_T(
224         long groupId, java.lang.String templateId)
225         throws com.liferay.portal.SystemException, 
226             com.liferay.portlet.journal.NoSuchTemplateException {
227         return getPersistence().findByG_T(groupId, templateId);
228     }
229 
230     public static com.liferay.portlet.journal.model.JournalTemplate fetchByG_T(
231         long groupId, java.lang.String templateId)
232         throws com.liferay.portal.SystemException {
233         return getPersistence().fetchByG_T(groupId, templateId);
234     }
235 
236     public static java.util.List findByG_S(long groupId,
237         java.lang.String structureId) throws com.liferay.portal.SystemException {
238         return getPersistence().findByG_S(groupId, structureId);
239     }
240 
241     public static java.util.List findByG_S(long groupId,
242         java.lang.String structureId, int begin, int end)
243         throws com.liferay.portal.SystemException {
244         return getPersistence().findByG_S(groupId, structureId, begin, end);
245     }
246 
247     public static java.util.List findByG_S(long groupId,
248         java.lang.String structureId, int begin, int end,
249         com.liferay.portal.kernel.util.OrderByComparator obc)
250         throws com.liferay.portal.SystemException {
251         return getPersistence().findByG_S(groupId, structureId, begin, end, obc);
252     }
253 
254     public static com.liferay.portlet.journal.model.JournalTemplate findByG_S_First(
255         long groupId, java.lang.String structureId,
256         com.liferay.portal.kernel.util.OrderByComparator obc)
257         throws com.liferay.portal.SystemException, 
258             com.liferay.portlet.journal.NoSuchTemplateException {
259         return getPersistence().findByG_S_First(groupId, structureId, obc);
260     }
261 
262     public static com.liferay.portlet.journal.model.JournalTemplate findByG_S_Last(
263         long groupId, java.lang.String structureId,
264         com.liferay.portal.kernel.util.OrderByComparator obc)
265         throws com.liferay.portal.SystemException, 
266             com.liferay.portlet.journal.NoSuchTemplateException {
267         return getPersistence().findByG_S_Last(groupId, structureId, obc);
268     }
269 
270     public static com.liferay.portlet.journal.model.JournalTemplate[] findByG_S_PrevAndNext(
271         long id, long groupId, java.lang.String structureId,
272         com.liferay.portal.kernel.util.OrderByComparator obc)
273         throws com.liferay.portal.SystemException, 
274             com.liferay.portlet.journal.NoSuchTemplateException {
275         return getPersistence().findByG_S_PrevAndNext(id, groupId, structureId,
276             obc);
277     }
278 
279     public static java.util.List findWithDynamicQuery(
280         com.liferay.portal.kernel.dao.DynamicQueryInitializer queryInitializer)
281         throws com.liferay.portal.SystemException {
282         return getPersistence().findWithDynamicQuery(queryInitializer);
283     }
284 
285     public static java.util.List findWithDynamicQuery(
286         com.liferay.portal.kernel.dao.DynamicQueryInitializer queryInitializer,
287         int begin, int end) throws com.liferay.portal.SystemException {
288         return getPersistence().findWithDynamicQuery(queryInitializer, begin,
289             end);
290     }
291 
292     public static java.util.List findAll()
293         throws com.liferay.portal.SystemException {
294         return getPersistence().findAll();
295     }
296 
297     public static java.util.List findAll(int begin, int end)
298         throws com.liferay.portal.SystemException {
299         return getPersistence().findAll(begin, end);
300     }
301 
302     public static java.util.List findAll(int begin, int end,
303         com.liferay.portal.kernel.util.OrderByComparator obc)
304         throws com.liferay.portal.SystemException {
305         return getPersistence().findAll(begin, end, obc);
306     }
307 
308     public static void removeByUuid(java.lang.String uuid)
309         throws com.liferay.portal.SystemException {
310         getPersistence().removeByUuid(uuid);
311     }
312 
313     public static void removeByUUID_G(java.lang.String uuid, long groupId)
314         throws com.liferay.portal.SystemException, 
315             com.liferay.portlet.journal.NoSuchTemplateException {
316         getPersistence().removeByUUID_G(uuid, groupId);
317     }
318 
319     public static void removeByGroupId(long groupId)
320         throws com.liferay.portal.SystemException {
321         getPersistence().removeByGroupId(groupId);
322     }
323 
324     public static void removeByTemplateId(java.lang.String templateId)
325         throws com.liferay.portal.SystemException {
326         getPersistence().removeByTemplateId(templateId);
327     }
328 
329     public static void removeBySmallImageId(long smallImageId)
330         throws com.liferay.portal.SystemException, 
331             com.liferay.portlet.journal.NoSuchTemplateException {
332         getPersistence().removeBySmallImageId(smallImageId);
333     }
334 
335     public static void removeByG_T(long groupId, java.lang.String templateId)
336         throws com.liferay.portal.SystemException, 
337             com.liferay.portlet.journal.NoSuchTemplateException {
338         getPersistence().removeByG_T(groupId, templateId);
339     }
340 
341     public static void removeByG_S(long groupId, java.lang.String structureId)
342         throws com.liferay.portal.SystemException {
343         getPersistence().removeByG_S(groupId, structureId);
344     }
345 
346     public static void removeAll() throws com.liferay.portal.SystemException {
347         getPersistence().removeAll();
348     }
349 
350     public static int countByUuid(java.lang.String uuid)
351         throws com.liferay.portal.SystemException {
352         return getPersistence().countByUuid(uuid);
353     }
354 
355     public static int countByUUID_G(java.lang.String uuid, long groupId)
356         throws com.liferay.portal.SystemException {
357         return getPersistence().countByUUID_G(uuid, groupId);
358     }
359 
360     public static int countByGroupId(long groupId)
361         throws com.liferay.portal.SystemException {
362         return getPersistence().countByGroupId(groupId);
363     }
364 
365     public static int countByTemplateId(java.lang.String templateId)
366         throws com.liferay.portal.SystemException {
367         return getPersistence().countByTemplateId(templateId);
368     }
369 
370     public static int countBySmallImageId(long smallImageId)
371         throws com.liferay.portal.SystemException {
372         return getPersistence().countBySmallImageId(smallImageId);
373     }
374 
375     public static int countByG_T(long groupId, java.lang.String templateId)
376         throws com.liferay.portal.SystemException {
377         return getPersistence().countByG_T(groupId, templateId);
378     }
379 
380     public static int countByG_S(long groupId, java.lang.String structureId)
381         throws com.liferay.portal.SystemException {
382         return getPersistence().countByG_S(groupId, structureId);
383     }
384 
385     public static int countAll() throws com.liferay.portal.SystemException {
386         return getPersistence().countAll();
387     }
388 
389     public static JournalTemplatePersistence getPersistence() {
390         return _getUtil()._persistence;
391     }
392 
393     public void setPersistence(JournalTemplatePersistence persistence) {
394         _persistence = persistence;
395     }
396 
397     private static JournalTemplateUtil _getUtil() {
398         if (_util == null) {
399             _util = (JournalTemplateUtil)com.liferay.portal.kernel.bean.BeanLocatorUtil.locate(_UTIL);
400         }
401 
402         return _util;
403     }
404 
405     private static final String _UTIL = JournalTemplateUtil.class.getName();
406     private static JournalTemplateUtil _util;
407     private JournalTemplatePersistence _persistence;
408 }