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.portal.service.persistence;
24  
25  /**
26   * <a href="LayoutPersistence.java.html"><b><i>View Source</i></b></a>
27   *
28   * @author Brian Wing Shun Chan
29   *
30   */
31  public interface LayoutPersistence {
32      public com.liferay.portal.model.Layout create(long plid);
33  
34      public com.liferay.portal.model.Layout remove(long plid)
35          throws com.liferay.portal.SystemException, 
36              com.liferay.portal.NoSuchLayoutException;
37  
38      public com.liferay.portal.model.Layout remove(
39          com.liferay.portal.model.Layout layout)
40          throws com.liferay.portal.SystemException;
41  
42      public com.liferay.portal.model.Layout update(
43          com.liferay.portal.model.Layout layout)
44          throws com.liferay.portal.SystemException;
45  
46      public com.liferay.portal.model.Layout update(
47          com.liferay.portal.model.Layout layout, boolean merge)
48          throws com.liferay.portal.SystemException;
49  
50      public com.liferay.portal.model.Layout updateImpl(
51          com.liferay.portal.model.Layout layout, boolean merge)
52          throws com.liferay.portal.SystemException;
53  
54      public com.liferay.portal.model.Layout findByPrimaryKey(long plid)
55          throws com.liferay.portal.SystemException, 
56              com.liferay.portal.NoSuchLayoutException;
57  
58      public com.liferay.portal.model.Layout fetchByPrimaryKey(long plid)
59          throws com.liferay.portal.SystemException;
60  
61      public java.util.List findByGroupId(long groupId)
62          throws com.liferay.portal.SystemException;
63  
64      public java.util.List findByGroupId(long groupId, int begin, int end)
65          throws com.liferay.portal.SystemException;
66  
67      public java.util.List findByGroupId(long groupId, int begin, int end,
68          com.liferay.portal.kernel.util.OrderByComparator obc)
69          throws com.liferay.portal.SystemException;
70  
71      public com.liferay.portal.model.Layout findByGroupId_First(long groupId,
72          com.liferay.portal.kernel.util.OrderByComparator obc)
73          throws com.liferay.portal.SystemException, 
74              com.liferay.portal.NoSuchLayoutException;
75  
76      public com.liferay.portal.model.Layout findByGroupId_Last(long groupId,
77          com.liferay.portal.kernel.util.OrderByComparator obc)
78          throws com.liferay.portal.SystemException, 
79              com.liferay.portal.NoSuchLayoutException;
80  
81      public com.liferay.portal.model.Layout[] findByGroupId_PrevAndNext(
82          long plid, long groupId,
83          com.liferay.portal.kernel.util.OrderByComparator obc)
84          throws com.liferay.portal.SystemException, 
85              com.liferay.portal.NoSuchLayoutException;
86  
87      public java.util.List findByCompanyId(long companyId)
88          throws com.liferay.portal.SystemException;
89  
90      public java.util.List findByCompanyId(long companyId, int begin, int end)
91          throws com.liferay.portal.SystemException;
92  
93      public java.util.List findByCompanyId(long companyId, int begin, int end,
94          com.liferay.portal.kernel.util.OrderByComparator obc)
95          throws com.liferay.portal.SystemException;
96  
97      public com.liferay.portal.model.Layout findByCompanyId_First(
98          long companyId, com.liferay.portal.kernel.util.OrderByComparator obc)
99          throws com.liferay.portal.SystemException, 
100             com.liferay.portal.NoSuchLayoutException;
101 
102     public com.liferay.portal.model.Layout findByCompanyId_Last(
103         long companyId, com.liferay.portal.kernel.util.OrderByComparator obc)
104         throws com.liferay.portal.SystemException, 
105             com.liferay.portal.NoSuchLayoutException;
106 
107     public com.liferay.portal.model.Layout[] findByCompanyId_PrevAndNext(
108         long plid, long companyId,
109         com.liferay.portal.kernel.util.OrderByComparator obc)
110         throws com.liferay.portal.SystemException, 
111             com.liferay.portal.NoSuchLayoutException;
112 
113     public com.liferay.portal.model.Layout findByDLFolderId(long dlFolderId)
114         throws com.liferay.portal.SystemException, 
115             com.liferay.portal.NoSuchLayoutException;
116 
117     public com.liferay.portal.model.Layout fetchByDLFolderId(long dlFolderId)
118         throws com.liferay.portal.SystemException;
119 
120     public com.liferay.portal.model.Layout findByIconImageId(long iconImageId)
121         throws com.liferay.portal.SystemException, 
122             com.liferay.portal.NoSuchLayoutException;
123 
124     public com.liferay.portal.model.Layout fetchByIconImageId(long iconImageId)
125         throws com.liferay.portal.SystemException;
126 
127     public java.util.List findByG_P(long groupId, boolean privateLayout)
128         throws com.liferay.portal.SystemException;
129 
130     public java.util.List findByG_P(long groupId, boolean privateLayout,
131         int begin, int end) throws com.liferay.portal.SystemException;
132 
133     public java.util.List findByG_P(long groupId, boolean privateLayout,
134         int begin, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
135         throws com.liferay.portal.SystemException;
136 
137     public com.liferay.portal.model.Layout findByG_P_First(long groupId,
138         boolean privateLayout,
139         com.liferay.portal.kernel.util.OrderByComparator obc)
140         throws com.liferay.portal.SystemException, 
141             com.liferay.portal.NoSuchLayoutException;
142 
143     public com.liferay.portal.model.Layout findByG_P_Last(long groupId,
144         boolean privateLayout,
145         com.liferay.portal.kernel.util.OrderByComparator obc)
146         throws com.liferay.portal.SystemException, 
147             com.liferay.portal.NoSuchLayoutException;
148 
149     public com.liferay.portal.model.Layout[] findByG_P_PrevAndNext(long plid,
150         long groupId, boolean privateLayout,
151         com.liferay.portal.kernel.util.OrderByComparator obc)
152         throws com.liferay.portal.SystemException, 
153             com.liferay.portal.NoSuchLayoutException;
154 
155     public com.liferay.portal.model.Layout findByG_P_L(long groupId,
156         boolean privateLayout, long layoutId)
157         throws com.liferay.portal.SystemException, 
158             com.liferay.portal.NoSuchLayoutException;
159 
160     public com.liferay.portal.model.Layout fetchByG_P_L(long groupId,
161         boolean privateLayout, long layoutId)
162         throws com.liferay.portal.SystemException;
163 
164     public java.util.List findByG_P_P(long groupId, boolean privateLayout,
165         long parentLayoutId) throws com.liferay.portal.SystemException;
166 
167     public java.util.List findByG_P_P(long groupId, boolean privateLayout,
168         long parentLayoutId, int begin, int end)
169         throws com.liferay.portal.SystemException;
170 
171     public java.util.List findByG_P_P(long groupId, boolean privateLayout,
172         long parentLayoutId, int begin, int end,
173         com.liferay.portal.kernel.util.OrderByComparator obc)
174         throws com.liferay.portal.SystemException;
175 
176     public com.liferay.portal.model.Layout findByG_P_P_First(long groupId,
177         boolean privateLayout, long parentLayoutId,
178         com.liferay.portal.kernel.util.OrderByComparator obc)
179         throws com.liferay.portal.SystemException, 
180             com.liferay.portal.NoSuchLayoutException;
181 
182     public com.liferay.portal.model.Layout findByG_P_P_Last(long groupId,
183         boolean privateLayout, long parentLayoutId,
184         com.liferay.portal.kernel.util.OrderByComparator obc)
185         throws com.liferay.portal.SystemException, 
186             com.liferay.portal.NoSuchLayoutException;
187 
188     public com.liferay.portal.model.Layout[] findByG_P_P_PrevAndNext(
189         long plid, long groupId, boolean privateLayout, long parentLayoutId,
190         com.liferay.portal.kernel.util.OrderByComparator obc)
191         throws com.liferay.portal.SystemException, 
192             com.liferay.portal.NoSuchLayoutException;
193 
194     public com.liferay.portal.model.Layout findByG_P_F(long groupId,
195         boolean privateLayout, java.lang.String friendlyURL)
196         throws com.liferay.portal.SystemException, 
197             com.liferay.portal.NoSuchLayoutException;
198 
199     public com.liferay.portal.model.Layout fetchByG_P_F(long groupId,
200         boolean privateLayout, java.lang.String friendlyURL)
201         throws com.liferay.portal.SystemException;
202 
203     public java.util.List findWithDynamicQuery(
204         com.liferay.portal.kernel.dao.DynamicQueryInitializer queryInitializer)
205         throws com.liferay.portal.SystemException;
206 
207     public java.util.List findWithDynamicQuery(
208         com.liferay.portal.kernel.dao.DynamicQueryInitializer queryInitializer,
209         int begin, int end) throws com.liferay.portal.SystemException;
210 
211     public java.util.List findAll() throws com.liferay.portal.SystemException;
212 
213     public java.util.List findAll(int begin, int end)
214         throws com.liferay.portal.SystemException;
215 
216     public java.util.List findAll(int begin, int end,
217         com.liferay.portal.kernel.util.OrderByComparator obc)
218         throws com.liferay.portal.SystemException;
219 
220     public void removeByGroupId(long groupId)
221         throws com.liferay.portal.SystemException;
222 
223     public void removeByCompanyId(long companyId)
224         throws com.liferay.portal.SystemException;
225 
226     public void removeByDLFolderId(long dlFolderId)
227         throws com.liferay.portal.SystemException, 
228             com.liferay.portal.NoSuchLayoutException;
229 
230     public void removeByIconImageId(long iconImageId)
231         throws com.liferay.portal.SystemException, 
232             com.liferay.portal.NoSuchLayoutException;
233 
234     public void removeByG_P(long groupId, boolean privateLayout)
235         throws com.liferay.portal.SystemException;
236 
237     public void removeByG_P_L(long groupId, boolean privateLayout, long layoutId)
238         throws com.liferay.portal.SystemException, 
239             com.liferay.portal.NoSuchLayoutException;
240 
241     public void removeByG_P_P(long groupId, boolean privateLayout,
242         long parentLayoutId) throws com.liferay.portal.SystemException;
243 
244     public void removeByG_P_F(long groupId, boolean privateLayout,
245         java.lang.String friendlyURL)
246         throws com.liferay.portal.SystemException, 
247             com.liferay.portal.NoSuchLayoutException;
248 
249     public void removeAll() throws com.liferay.portal.SystemException;
250 
251     public int countByGroupId(long groupId)
252         throws com.liferay.portal.SystemException;
253 
254     public int countByCompanyId(long companyId)
255         throws com.liferay.portal.SystemException;
256 
257     public int countByDLFolderId(long dlFolderId)
258         throws com.liferay.portal.SystemException;
259 
260     public int countByIconImageId(long iconImageId)
261         throws com.liferay.portal.SystemException;
262 
263     public int countByG_P(long groupId, boolean privateLayout)
264         throws com.liferay.portal.SystemException;
265 
266     public int countByG_P_L(long groupId, boolean privateLayout, long layoutId)
267         throws com.liferay.portal.SystemException;
268 
269     public int countByG_P_P(long groupId, boolean privateLayout,
270         long parentLayoutId) throws com.liferay.portal.SystemException;
271 
272     public int countByG_P_F(long groupId, boolean privateLayout,
273         java.lang.String friendlyURL) throws com.liferay.portal.SystemException;
274 
275     public int countAll() throws com.liferay.portal.SystemException;
276 }