1   /**
2    * Copyright (c) 2000-2009 Liferay, Inc. All rights reserved.
3    *
4    *
5    *
6    *
7    * The contents of this file are subject to the terms of the Liferay Enterprise
8    * Subscription License ("License"). You may not use this file except in
9    * compliance with the License. You can obtain a copy of the License by
10   * contacting Liferay, Inc. See the License for the specific language governing
11   * permissions and limitations under the License, including but not limited to
12   * distribution rights 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  import com.liferay.portal.SystemException;
26  import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
27  import com.liferay.portal.kernel.dao.orm.DynamicQuery;
28  
29  import com.liferay.portlet.journal.model.JournalTemplate;
30  
31  import java.util.List;
32  
33  /**
34   * <a href="JournalTemplateUtil.java.html"><b><i>View Source</i></b></a>
35   *
36   * <p>
37   * ServiceBuilder generated this class. Modifications in this class will be
38   * overwritten the next time is generated.
39   * </p>
40   *
41   * @author    Brian Wing Shun Chan
42   * @see       JournalTemplatePersistence
43   * @see       JournalTemplatePersistenceImpl
44   * @generated
45   */
46  public class JournalTemplateUtil {
47      /**
48       * @see com.liferay.portal.service.persistence.BasePersistence#clearCache()
49       */
50      public static void clearCache() {
51          getPersistence().clearCache();
52      }
53  
54      /**
55       * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery)
56       */
57      public static List<Object> findWithDynamicQuery(DynamicQuery dynamicQuery)
58          throws SystemException {
59          return getPersistence().findWithDynamicQuery(dynamicQuery);
60      }
61  
62      /**
63       * @see com.liferay.portal.service.persistence.BasePersistence#findWithDynamicQuery(DynamicQuery, int, int)
64       */
65      public static List<Object> findWithDynamicQuery(DynamicQuery dynamicQuery,
66          int start, int end) throws SystemException {
67          return getPersistence().findWithDynamicQuery(dynamicQuery, start, end);
68      }
69  
70      /**
71       * @see com.liferay.portal.service.persistence.BasePersistence#remove(com.liferay.portal.model.BaseModel)
72       */
73      public static JournalTemplate remove(JournalTemplate journalTemplate)
74          throws SystemException {
75          return getPersistence().remove(journalTemplate);
76      }
77  
78      /**
79       * @see com.liferay.portal.service.persistence.BasePersistence#update(com.liferay.portal.model.BaseModel, boolean)
80       */
81      public static JournalTemplate update(JournalTemplate journalTemplate,
82          boolean merge) throws SystemException {
83          return getPersistence().update(journalTemplate, merge);
84      }
85  
86      public static void cacheResult(
87          com.liferay.portlet.journal.model.JournalTemplate journalTemplate) {
88          getPersistence().cacheResult(journalTemplate);
89      }
90  
91      public static void cacheResult(
92          java.util.List<com.liferay.portlet.journal.model.JournalTemplate> journalTemplates) {
93          getPersistence().cacheResult(journalTemplates);
94      }
95  
96      public static com.liferay.portlet.journal.model.JournalTemplate create(
97          long id) {
98          return getPersistence().create(id);
99      }
100 
101     public static com.liferay.portlet.journal.model.JournalTemplate remove(
102         long id)
103         throws com.liferay.portal.SystemException,
104             com.liferay.portlet.journal.NoSuchTemplateException {
105         return getPersistence().remove(id);
106     }
107 
108     /**
109      * @deprecated Use {@link com.liferay.portal.service.persistence.BasePersistence.#update(com.liferay.portal.model.BaseModel, boolean)}.
110      */
111     public static com.liferay.portlet.journal.model.JournalTemplate update(
112         com.liferay.portlet.journal.model.JournalTemplate journalTemplate)
113         throws com.liferay.portal.SystemException {
114         return getPersistence().update(journalTemplate);
115     }
116 
117     public static com.liferay.portlet.journal.model.JournalTemplate updateImpl(
118         com.liferay.portlet.journal.model.JournalTemplate journalTemplate,
119         boolean merge) throws com.liferay.portal.SystemException {
120         return getPersistence().updateImpl(journalTemplate, merge);
121     }
122 
123     public static com.liferay.portlet.journal.model.JournalTemplate findByPrimaryKey(
124         long id)
125         throws com.liferay.portal.SystemException,
126             com.liferay.portlet.journal.NoSuchTemplateException {
127         return getPersistence().findByPrimaryKey(id);
128     }
129 
130     public static com.liferay.portlet.journal.model.JournalTemplate fetchByPrimaryKey(
131         long id) throws com.liferay.portal.SystemException {
132         return getPersistence().fetchByPrimaryKey(id);
133     }
134 
135     public static java.util.List<com.liferay.portlet.journal.model.JournalTemplate> findByUuid(
136         java.lang.String uuid) throws com.liferay.portal.SystemException {
137         return getPersistence().findByUuid(uuid);
138     }
139 
140     public static java.util.List<com.liferay.portlet.journal.model.JournalTemplate> findByUuid(
141         java.lang.String uuid, int start, int end)
142         throws com.liferay.portal.SystemException {
143         return getPersistence().findByUuid(uuid, start, end);
144     }
145 
146     public static java.util.List<com.liferay.portlet.journal.model.JournalTemplate> findByUuid(
147         java.lang.String uuid, int start, int end,
148         com.liferay.portal.kernel.util.OrderByComparator obc)
149         throws com.liferay.portal.SystemException {
150         return getPersistence().findByUuid(uuid, start, end, obc);
151     }
152 
153     public static com.liferay.portlet.journal.model.JournalTemplate findByUuid_First(
154         java.lang.String uuid,
155         com.liferay.portal.kernel.util.OrderByComparator obc)
156         throws com.liferay.portal.SystemException,
157             com.liferay.portlet.journal.NoSuchTemplateException {
158         return getPersistence().findByUuid_First(uuid, obc);
159     }
160 
161     public static com.liferay.portlet.journal.model.JournalTemplate findByUuid_Last(
162         java.lang.String uuid,
163         com.liferay.portal.kernel.util.OrderByComparator obc)
164         throws com.liferay.portal.SystemException,
165             com.liferay.portlet.journal.NoSuchTemplateException {
166         return getPersistence().findByUuid_Last(uuid, obc);
167     }
168 
169     public static com.liferay.portlet.journal.model.JournalTemplate[] findByUuid_PrevAndNext(
170         long id, java.lang.String uuid,
171         com.liferay.portal.kernel.util.OrderByComparator obc)
172         throws com.liferay.portal.SystemException,
173             com.liferay.portlet.journal.NoSuchTemplateException {
174         return getPersistence().findByUuid_PrevAndNext(id, uuid, obc);
175     }
176 
177     public static com.liferay.portlet.journal.model.JournalTemplate findByUUID_G(
178         java.lang.String uuid, long groupId)
179         throws com.liferay.portal.SystemException,
180             com.liferay.portlet.journal.NoSuchTemplateException {
181         return getPersistence().findByUUID_G(uuid, groupId);
182     }
183 
184     public static com.liferay.portlet.journal.model.JournalTemplate fetchByUUID_G(
185         java.lang.String uuid, long groupId)
186         throws com.liferay.portal.SystemException {
187         return getPersistence().fetchByUUID_G(uuid, groupId);
188     }
189 
190     public static com.liferay.portlet.journal.model.JournalTemplate fetchByUUID_G(
191         java.lang.String uuid, long groupId, boolean retrieveFromCache)
192         throws com.liferay.portal.SystemException {
193         return getPersistence().fetchByUUID_G(uuid, groupId, retrieveFromCache);
194     }
195 
196     public static java.util.List<com.liferay.portlet.journal.model.JournalTemplate> findByGroupId(
197         long groupId) throws com.liferay.portal.SystemException {
198         return getPersistence().findByGroupId(groupId);
199     }
200 
201     public static java.util.List<com.liferay.portlet.journal.model.JournalTemplate> findByGroupId(
202         long groupId, int start, int end)
203         throws com.liferay.portal.SystemException {
204         return getPersistence().findByGroupId(groupId, start, end);
205     }
206 
207     public static java.util.List<com.liferay.portlet.journal.model.JournalTemplate> findByGroupId(
208         long groupId, int start, int end,
209         com.liferay.portal.kernel.util.OrderByComparator obc)
210         throws com.liferay.portal.SystemException {
211         return getPersistence().findByGroupId(groupId, start, end, obc);
212     }
213 
214     public static com.liferay.portlet.journal.model.JournalTemplate findByGroupId_First(
215         long groupId, com.liferay.portal.kernel.util.OrderByComparator obc)
216         throws com.liferay.portal.SystemException,
217             com.liferay.portlet.journal.NoSuchTemplateException {
218         return getPersistence().findByGroupId_First(groupId, obc);
219     }
220 
221     public static com.liferay.portlet.journal.model.JournalTemplate findByGroupId_Last(
222         long groupId, com.liferay.portal.kernel.util.OrderByComparator obc)
223         throws com.liferay.portal.SystemException,
224             com.liferay.portlet.journal.NoSuchTemplateException {
225         return getPersistence().findByGroupId_Last(groupId, obc);
226     }
227 
228     public static com.liferay.portlet.journal.model.JournalTemplate[] findByGroupId_PrevAndNext(
229         long id, long groupId,
230         com.liferay.portal.kernel.util.OrderByComparator obc)
231         throws com.liferay.portal.SystemException,
232             com.liferay.portlet.journal.NoSuchTemplateException {
233         return getPersistence().findByGroupId_PrevAndNext(id, groupId, obc);
234     }
235 
236     public static java.util.List<com.liferay.portlet.journal.model.JournalTemplate> findByTemplateId(
237         java.lang.String templateId) throws com.liferay.portal.SystemException {
238         return getPersistence().findByTemplateId(templateId);
239     }
240 
241     public static java.util.List<com.liferay.portlet.journal.model.JournalTemplate> findByTemplateId(
242         java.lang.String templateId, int start, int end)
243         throws com.liferay.portal.SystemException {
244         return getPersistence().findByTemplateId(templateId, start, end);
245     }
246 
247     public static java.util.List<com.liferay.portlet.journal.model.JournalTemplate> findByTemplateId(
248         java.lang.String templateId, int start, int end,
249         com.liferay.portal.kernel.util.OrderByComparator obc)
250         throws com.liferay.portal.SystemException {
251         return getPersistence().findByTemplateId(templateId, start, end, obc);
252     }
253 
254     public static com.liferay.portlet.journal.model.JournalTemplate findByTemplateId_First(
255         java.lang.String templateId,
256         com.liferay.portal.kernel.util.OrderByComparator obc)
257         throws com.liferay.portal.SystemException,
258             com.liferay.portlet.journal.NoSuchTemplateException {
259         return getPersistence().findByTemplateId_First(templateId, obc);
260     }
261 
262     public static com.liferay.portlet.journal.model.JournalTemplate findByTemplateId_Last(
263         java.lang.String templateId,
264         com.liferay.portal.kernel.util.OrderByComparator obc)
265         throws com.liferay.portal.SystemException,
266             com.liferay.portlet.journal.NoSuchTemplateException {
267         return getPersistence().findByTemplateId_Last(templateId, obc);
268     }
269 
270     public static com.liferay.portlet.journal.model.JournalTemplate[] findByTemplateId_PrevAndNext(
271         long id, java.lang.String templateId,
272         com.liferay.portal.kernel.util.OrderByComparator obc)
273         throws com.liferay.portal.SystemException,
274             com.liferay.portlet.journal.NoSuchTemplateException {
275         return getPersistence().findByTemplateId_PrevAndNext(id, templateId, obc);
276     }
277 
278     public static com.liferay.portlet.journal.model.JournalTemplate findBySmallImageId(
279         long smallImageId)
280         throws com.liferay.portal.SystemException,
281             com.liferay.portlet.journal.NoSuchTemplateException {
282         return getPersistence().findBySmallImageId(smallImageId);
283     }
284 
285     public static com.liferay.portlet.journal.model.JournalTemplate fetchBySmallImageId(
286         long smallImageId) throws com.liferay.portal.SystemException {
287         return getPersistence().fetchBySmallImageId(smallImageId);
288     }
289 
290     public static com.liferay.portlet.journal.model.JournalTemplate fetchBySmallImageId(
291         long smallImageId, boolean retrieveFromCache)
292         throws com.liferay.portal.SystemException {
293         return getPersistence()
294                    .fetchBySmallImageId(smallImageId, retrieveFromCache);
295     }
296 
297     public static com.liferay.portlet.journal.model.JournalTemplate findByG_T(
298         long groupId, java.lang.String templateId)
299         throws com.liferay.portal.SystemException,
300             com.liferay.portlet.journal.NoSuchTemplateException {
301         return getPersistence().findByG_T(groupId, templateId);
302     }
303 
304     public static com.liferay.portlet.journal.model.JournalTemplate fetchByG_T(
305         long groupId, java.lang.String templateId)
306         throws com.liferay.portal.SystemException {
307         return getPersistence().fetchByG_T(groupId, templateId);
308     }
309 
310     public static com.liferay.portlet.journal.model.JournalTemplate fetchByG_T(
311         long groupId, java.lang.String templateId, boolean retrieveFromCache)
312         throws com.liferay.portal.SystemException {
313         return getPersistence()
314                    .fetchByG_T(groupId, templateId, retrieveFromCache);
315     }
316 
317     public static java.util.List<com.liferay.portlet.journal.model.JournalTemplate> findByG_S(
318         long groupId, java.lang.String structureId)
319         throws com.liferay.portal.SystemException {
320         return getPersistence().findByG_S(groupId, structureId);
321     }
322 
323     public static java.util.List<com.liferay.portlet.journal.model.JournalTemplate> findByG_S(
324         long groupId, java.lang.String structureId, int start, int end)
325         throws com.liferay.portal.SystemException {
326         return getPersistence().findByG_S(groupId, structureId, start, end);
327     }
328 
329     public static java.util.List<com.liferay.portlet.journal.model.JournalTemplate> findByG_S(
330         long groupId, java.lang.String structureId, int start, int end,
331         com.liferay.portal.kernel.util.OrderByComparator obc)
332         throws com.liferay.portal.SystemException {
333         return getPersistence().findByG_S(groupId, structureId, start, end, obc);
334     }
335 
336     public static com.liferay.portlet.journal.model.JournalTemplate findByG_S_First(
337         long groupId, java.lang.String structureId,
338         com.liferay.portal.kernel.util.OrderByComparator obc)
339         throws com.liferay.portal.SystemException,
340             com.liferay.portlet.journal.NoSuchTemplateException {
341         return getPersistence().findByG_S_First(groupId, structureId, obc);
342     }
343 
344     public static com.liferay.portlet.journal.model.JournalTemplate findByG_S_Last(
345         long groupId, java.lang.String structureId,
346         com.liferay.portal.kernel.util.OrderByComparator obc)
347         throws com.liferay.portal.SystemException,
348             com.liferay.portlet.journal.NoSuchTemplateException {
349         return getPersistence().findByG_S_Last(groupId, structureId, obc);
350     }
351 
352     public static com.liferay.portlet.journal.model.JournalTemplate[] findByG_S_PrevAndNext(
353         long id, long groupId, java.lang.String structureId,
354         com.liferay.portal.kernel.util.OrderByComparator obc)
355         throws com.liferay.portal.SystemException,
356             com.liferay.portlet.journal.NoSuchTemplateException {
357         return getPersistence()
358                    .findByG_S_PrevAndNext(id, groupId, structureId, obc);
359     }
360 
361     public static java.util.List<com.liferay.portlet.journal.model.JournalTemplate> findAll()
362         throws com.liferay.portal.SystemException {
363         return getPersistence().findAll();
364     }
365 
366     public static java.util.List<com.liferay.portlet.journal.model.JournalTemplate> findAll(
367         int start, int end) throws com.liferay.portal.SystemException {
368         return getPersistence().findAll(start, end);
369     }
370 
371     public static java.util.List<com.liferay.portlet.journal.model.JournalTemplate> findAll(
372         int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
373         throws com.liferay.portal.SystemException {
374         return getPersistence().findAll(start, end, obc);
375     }
376 
377     public static void removeByUuid(java.lang.String uuid)
378         throws com.liferay.portal.SystemException {
379         getPersistence().removeByUuid(uuid);
380     }
381 
382     public static void removeByUUID_G(java.lang.String uuid, long groupId)
383         throws com.liferay.portal.SystemException,
384             com.liferay.portlet.journal.NoSuchTemplateException {
385         getPersistence().removeByUUID_G(uuid, groupId);
386     }
387 
388     public static void removeByGroupId(long groupId)
389         throws com.liferay.portal.SystemException {
390         getPersistence().removeByGroupId(groupId);
391     }
392 
393     public static void removeByTemplateId(java.lang.String templateId)
394         throws com.liferay.portal.SystemException {
395         getPersistence().removeByTemplateId(templateId);
396     }
397 
398     public static void removeBySmallImageId(long smallImageId)
399         throws com.liferay.portal.SystemException,
400             com.liferay.portlet.journal.NoSuchTemplateException {
401         getPersistence().removeBySmallImageId(smallImageId);
402     }
403 
404     public static void removeByG_T(long groupId, java.lang.String templateId)
405         throws com.liferay.portal.SystemException,
406             com.liferay.portlet.journal.NoSuchTemplateException {
407         getPersistence().removeByG_T(groupId, templateId);
408     }
409 
410     public static void removeByG_S(long groupId, java.lang.String structureId)
411         throws com.liferay.portal.SystemException {
412         getPersistence().removeByG_S(groupId, structureId);
413     }
414 
415     public static void removeAll() throws com.liferay.portal.SystemException {
416         getPersistence().removeAll();
417     }
418 
419     public static int countByUuid(java.lang.String uuid)
420         throws com.liferay.portal.SystemException {
421         return getPersistence().countByUuid(uuid);
422     }
423 
424     public static int countByUUID_G(java.lang.String uuid, long groupId)
425         throws com.liferay.portal.SystemException {
426         return getPersistence().countByUUID_G(uuid, groupId);
427     }
428 
429     public static int countByGroupId(long groupId)
430         throws com.liferay.portal.SystemException {
431         return getPersistence().countByGroupId(groupId);
432     }
433 
434     public static int countByTemplateId(java.lang.String templateId)
435         throws com.liferay.portal.SystemException {
436         return getPersistence().countByTemplateId(templateId);
437     }
438 
439     public static int countBySmallImageId(long smallImageId)
440         throws com.liferay.portal.SystemException {
441         return getPersistence().countBySmallImageId(smallImageId);
442     }
443 
444     public static int countByG_T(long groupId, java.lang.String templateId)
445         throws com.liferay.portal.SystemException {
446         return getPersistence().countByG_T(groupId, templateId);
447     }
448 
449     public static int countByG_S(long groupId, java.lang.String structureId)
450         throws com.liferay.portal.SystemException {
451         return getPersistence().countByG_S(groupId, structureId);
452     }
453 
454     public static int countAll() throws com.liferay.portal.SystemException {
455         return getPersistence().countAll();
456     }
457 
458     public static JournalTemplatePersistence getPersistence() {
459         if (_persistence == null) {
460             _persistence = (JournalTemplatePersistence)PortalBeanLocatorUtil.locate(JournalTemplatePersistence.class.getName());
461         }
462 
463         return _persistence;
464     }
465 
466     public void setPersistence(JournalTemplatePersistence persistence) {
467         _persistence = persistence;
468     }
469 
470     private static JournalTemplatePersistence _persistence;
471 }