1   /**
2    * Copyright (c) 2000-2007 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="JournalTemplatePersistence.java.html"><b><i>View Source</i></b></a>
27   *
28   * @author Brian Wing Shun Chan
29   *
30   */
31  public interface JournalTemplatePersistence {
32      public com.liferay.portlet.journal.model.JournalTemplate create(long id);
33  
34      public com.liferay.portlet.journal.model.JournalTemplate remove(long id)
35          throws com.liferay.portal.SystemException, 
36              com.liferay.portlet.journal.NoSuchTemplateException;
37  
38      public com.liferay.portlet.journal.model.JournalTemplate remove(
39          com.liferay.portlet.journal.model.JournalTemplate journalTemplate)
40          throws com.liferay.portal.SystemException;
41  
42      public com.liferay.portlet.journal.model.JournalTemplate update(
43          com.liferay.portlet.journal.model.JournalTemplate journalTemplate)
44          throws com.liferay.portal.SystemException;
45  
46      public com.liferay.portlet.journal.model.JournalTemplate update(
47          com.liferay.portlet.journal.model.JournalTemplate journalTemplate,
48          boolean merge) throws com.liferay.portal.SystemException;
49  
50      public com.liferay.portlet.journal.model.JournalTemplate findByPrimaryKey(
51          long id)
52          throws com.liferay.portal.SystemException, 
53              com.liferay.portlet.journal.NoSuchTemplateException;
54  
55      public com.liferay.portlet.journal.model.JournalTemplate fetchByPrimaryKey(
56          long id) throws com.liferay.portal.SystemException;
57  
58      public java.util.List findByGroupId(long groupId)
59          throws com.liferay.portal.SystemException;
60  
61      public java.util.List findByGroupId(long groupId, int begin, int end)
62          throws com.liferay.portal.SystemException;
63  
64      public java.util.List findByGroupId(long groupId, int begin, int end,
65          com.liferay.portal.kernel.util.OrderByComparator obc)
66          throws com.liferay.portal.SystemException;
67  
68      public com.liferay.portlet.journal.model.JournalTemplate findByGroupId_First(
69          long groupId, com.liferay.portal.kernel.util.OrderByComparator obc)
70          throws com.liferay.portal.SystemException, 
71              com.liferay.portlet.journal.NoSuchTemplateException;
72  
73      public com.liferay.portlet.journal.model.JournalTemplate findByGroupId_Last(
74          long groupId, com.liferay.portal.kernel.util.OrderByComparator obc)
75          throws com.liferay.portal.SystemException, 
76              com.liferay.portlet.journal.NoSuchTemplateException;
77  
78      public com.liferay.portlet.journal.model.JournalTemplate[] findByGroupId_PrevAndNext(
79          long id, long groupId,
80          com.liferay.portal.kernel.util.OrderByComparator obc)
81          throws com.liferay.portal.SystemException, 
82              com.liferay.portlet.journal.NoSuchTemplateException;
83  
84      public java.util.List findByTemplateId(java.lang.String templateId)
85          throws com.liferay.portal.SystemException;
86  
87      public java.util.List findByTemplateId(java.lang.String templateId,
88          int begin, int end) throws com.liferay.portal.SystemException;
89  
90      public java.util.List findByTemplateId(java.lang.String templateId,
91          int begin, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
92          throws com.liferay.portal.SystemException;
93  
94      public com.liferay.portlet.journal.model.JournalTemplate findByTemplateId_First(
95          java.lang.String templateId,
96          com.liferay.portal.kernel.util.OrderByComparator obc)
97          throws com.liferay.portal.SystemException, 
98              com.liferay.portlet.journal.NoSuchTemplateException;
99  
100     public com.liferay.portlet.journal.model.JournalTemplate findByTemplateId_Last(
101         java.lang.String templateId,
102         com.liferay.portal.kernel.util.OrderByComparator obc)
103         throws com.liferay.portal.SystemException, 
104             com.liferay.portlet.journal.NoSuchTemplateException;
105 
106     public com.liferay.portlet.journal.model.JournalTemplate[] findByTemplateId_PrevAndNext(
107         long id, java.lang.String templateId,
108         com.liferay.portal.kernel.util.OrderByComparator obc)
109         throws com.liferay.portal.SystemException, 
110             com.liferay.portlet.journal.NoSuchTemplateException;
111 
112     public com.liferay.portlet.journal.model.JournalTemplate findByG_T(
113         long groupId, java.lang.String templateId)
114         throws com.liferay.portal.SystemException, 
115             com.liferay.portlet.journal.NoSuchTemplateException;
116 
117     public com.liferay.portlet.journal.model.JournalTemplate fetchByG_T(
118         long groupId, java.lang.String templateId)
119         throws com.liferay.portal.SystemException;
120 
121     public java.util.List findByG_S(long groupId, java.lang.String structureId)
122         throws com.liferay.portal.SystemException;
123 
124     public java.util.List findByG_S(long groupId, java.lang.String structureId,
125         int begin, int end) throws com.liferay.portal.SystemException;
126 
127     public java.util.List findByG_S(long groupId, java.lang.String structureId,
128         int begin, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
129         throws com.liferay.portal.SystemException;
130 
131     public com.liferay.portlet.journal.model.JournalTemplate findByG_S_First(
132         long groupId, java.lang.String structureId,
133         com.liferay.portal.kernel.util.OrderByComparator obc)
134         throws com.liferay.portal.SystemException, 
135             com.liferay.portlet.journal.NoSuchTemplateException;
136 
137     public com.liferay.portlet.journal.model.JournalTemplate findByG_S_Last(
138         long groupId, java.lang.String structureId,
139         com.liferay.portal.kernel.util.OrderByComparator obc)
140         throws com.liferay.portal.SystemException, 
141             com.liferay.portlet.journal.NoSuchTemplateException;
142 
143     public com.liferay.portlet.journal.model.JournalTemplate[] findByG_S_PrevAndNext(
144         long id, long groupId, java.lang.String structureId,
145         com.liferay.portal.kernel.util.OrderByComparator obc)
146         throws com.liferay.portal.SystemException, 
147             com.liferay.portlet.journal.NoSuchTemplateException;
148 
149     public java.util.List findWithDynamicQuery(
150         com.liferay.portal.kernel.dao.DynamicQueryInitializer queryInitializer)
151         throws com.liferay.portal.SystemException;
152 
153     public java.util.List findWithDynamicQuery(
154         com.liferay.portal.kernel.dao.DynamicQueryInitializer queryInitializer,
155         int begin, int end) throws com.liferay.portal.SystemException;
156 
157     public java.util.List findAll() throws com.liferay.portal.SystemException;
158 
159     public java.util.List findAll(int begin, int end)
160         throws com.liferay.portal.SystemException;
161 
162     public java.util.List findAll(int begin, int end,
163         com.liferay.portal.kernel.util.OrderByComparator obc)
164         throws com.liferay.portal.SystemException;
165 
166     public void removeByGroupId(long groupId)
167         throws com.liferay.portal.SystemException;
168 
169     public void removeByTemplateId(java.lang.String templateId)
170         throws com.liferay.portal.SystemException;
171 
172     public void removeByG_T(long groupId, java.lang.String templateId)
173         throws com.liferay.portal.SystemException, 
174             com.liferay.portlet.journal.NoSuchTemplateException;
175 
176     public void removeByG_S(long groupId, java.lang.String structureId)
177         throws com.liferay.portal.SystemException;
178 
179     public void removeAll() throws com.liferay.portal.SystemException;
180 
181     public int countByGroupId(long groupId)
182         throws com.liferay.portal.SystemException;
183 
184     public int countByTemplateId(java.lang.String templateId)
185         throws com.liferay.portal.SystemException;
186 
187     public int countByG_T(long groupId, java.lang.String templateId)
188         throws com.liferay.portal.SystemException;
189 
190     public int countByG_S(long groupId, java.lang.String structureId)
191         throws com.liferay.portal.SystemException;
192 
193     public int countAll() throws com.liferay.portal.SystemException;
194 }