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.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 findByPrimaryKey(long plid)
51          throws com.liferay.portal.SystemException, 
52              com.liferay.portal.NoSuchLayoutException;
53  
54      public com.liferay.portal.model.Layout fetchByPrimaryKey(long plid)
55          throws com.liferay.portal.SystemException;
56  
57      public com.liferay.portal.model.Layout findByDLF(long dlFolderId)
58          throws com.liferay.portal.SystemException, 
59              com.liferay.portal.NoSuchLayoutException;
60  
61      public com.liferay.portal.model.Layout fetchByDLF(long dlFolderId)
62          throws com.liferay.portal.SystemException;
63  
64      public java.util.List findByG_P(long groupId, boolean privateLayout)
65          throws com.liferay.portal.SystemException;
66  
67      public java.util.List findByG_P(long groupId, boolean privateLayout,
68          int begin, int end) throws com.liferay.portal.SystemException;
69  
70      public java.util.List findByG_P(long groupId, boolean privateLayout,
71          int begin, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
72          throws com.liferay.portal.SystemException;
73  
74      public com.liferay.portal.model.Layout findByG_P_First(long groupId,
75          boolean privateLayout,
76          com.liferay.portal.kernel.util.OrderByComparator obc)
77          throws com.liferay.portal.SystemException, 
78              com.liferay.portal.NoSuchLayoutException;
79  
80      public com.liferay.portal.model.Layout findByG_P_Last(long groupId,
81          boolean privateLayout,
82          com.liferay.portal.kernel.util.OrderByComparator obc)
83          throws com.liferay.portal.SystemException, 
84              com.liferay.portal.NoSuchLayoutException;
85  
86      public com.liferay.portal.model.Layout[] findByG_P_PrevAndNext(long plid,
87          long groupId, boolean privateLayout,
88          com.liferay.portal.kernel.util.OrderByComparator obc)
89          throws com.liferay.portal.SystemException, 
90              com.liferay.portal.NoSuchLayoutException;
91  
92      public com.liferay.portal.model.Layout findByG_P_L(long groupId,
93          boolean privateLayout, long layoutId)
94          throws com.liferay.portal.SystemException, 
95              com.liferay.portal.NoSuchLayoutException;
96  
97      public com.liferay.portal.model.Layout fetchByG_P_L(long groupId,
98          boolean privateLayout, long layoutId)
99          throws com.liferay.portal.SystemException;
100 
101     public java.util.List findByG_P_P(long groupId, boolean privateLayout,
102         long parentLayoutId) throws com.liferay.portal.SystemException;
103 
104     public java.util.List findByG_P_P(long groupId, boolean privateLayout,
105         long parentLayoutId, int begin, int end)
106         throws com.liferay.portal.SystemException;
107 
108     public java.util.List findByG_P_P(long groupId, boolean privateLayout,
109         long parentLayoutId, int begin, int end,
110         com.liferay.portal.kernel.util.OrderByComparator obc)
111         throws com.liferay.portal.SystemException;
112 
113     public com.liferay.portal.model.Layout findByG_P_P_First(long groupId,
114         boolean privateLayout, long parentLayoutId,
115         com.liferay.portal.kernel.util.OrderByComparator obc)
116         throws com.liferay.portal.SystemException, 
117             com.liferay.portal.NoSuchLayoutException;
118 
119     public com.liferay.portal.model.Layout findByG_P_P_Last(long groupId,
120         boolean privateLayout, long parentLayoutId,
121         com.liferay.portal.kernel.util.OrderByComparator obc)
122         throws com.liferay.portal.SystemException, 
123             com.liferay.portal.NoSuchLayoutException;
124 
125     public com.liferay.portal.model.Layout[] findByG_P_P_PrevAndNext(
126         long plid, long groupId, boolean privateLayout, long parentLayoutId,
127         com.liferay.portal.kernel.util.OrderByComparator obc)
128         throws com.liferay.portal.SystemException, 
129             com.liferay.portal.NoSuchLayoutException;
130 
131     public com.liferay.portal.model.Layout findByG_P_F(long groupId,
132         boolean privateLayout, java.lang.String friendlyURL)
133         throws com.liferay.portal.SystemException, 
134             com.liferay.portal.NoSuchLayoutException;
135 
136     public com.liferay.portal.model.Layout fetchByG_P_F(long groupId,
137         boolean privateLayout, java.lang.String friendlyURL)
138         throws com.liferay.portal.SystemException;
139 
140     public java.util.List findWithDynamicQuery(
141         com.liferay.portal.kernel.dao.DynamicQueryInitializer queryInitializer)
142         throws com.liferay.portal.SystemException;
143 
144     public java.util.List findWithDynamicQuery(
145         com.liferay.portal.kernel.dao.DynamicQueryInitializer queryInitializer,
146         int begin, int end) throws com.liferay.portal.SystemException;
147 
148     public java.util.List findAll() throws com.liferay.portal.SystemException;
149 
150     public java.util.List findAll(int begin, int end)
151         throws com.liferay.portal.SystemException;
152 
153     public java.util.List findAll(int begin, int end,
154         com.liferay.portal.kernel.util.OrderByComparator obc)
155         throws com.liferay.portal.SystemException;
156 
157     public void removeByDLF(long dlFolderId)
158         throws com.liferay.portal.SystemException, 
159             com.liferay.portal.NoSuchLayoutException;
160 
161     public void removeByG_P(long groupId, boolean privateLayout)
162         throws com.liferay.portal.SystemException;
163 
164     public void removeByG_P_L(long groupId, boolean privateLayout, long layoutId)
165         throws com.liferay.portal.SystemException, 
166             com.liferay.portal.NoSuchLayoutException;
167 
168     public void removeByG_P_P(long groupId, boolean privateLayout,
169         long parentLayoutId) throws com.liferay.portal.SystemException;
170 
171     public void removeByG_P_F(long groupId, boolean privateLayout,
172         java.lang.String friendlyURL)
173         throws com.liferay.portal.SystemException, 
174             com.liferay.portal.NoSuchLayoutException;
175 
176     public void removeAll() throws com.liferay.portal.SystemException;
177 
178     public int countByDLF(long dlFolderId)
179         throws com.liferay.portal.SystemException;
180 
181     public int countByG_P(long groupId, boolean privateLayout)
182         throws com.liferay.portal.SystemException;
183 
184     public int countByG_P_L(long groupId, boolean privateLayout, long layoutId)
185         throws com.liferay.portal.SystemException;
186 
187     public int countByG_P_P(long groupId, boolean privateLayout,
188         long parentLayoutId) throws com.liferay.portal.SystemException;
189 
190     public int countByG_P_F(long groupId, boolean privateLayout,
191         java.lang.String friendlyURL) throws com.liferay.portal.SystemException;
192 
193     public int countAll() throws com.liferay.portal.SystemException;
194 }