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.softwarecatalog.service.persistence;
24  
25  import com.liferay.portal.PortalException;
26  import com.liferay.portal.SystemException;
27  import com.liferay.portal.kernel.annotation.Propagation;
28  import com.liferay.portal.kernel.annotation.Transactional;
29  
30  /**
31   * <a href="SCFrameworkVersionPersistence.java.html"><b><i>View Source</i></b></a>
32   *
33   * @author Brian Wing Shun Chan
34   *
35   */
36  @Transactional(rollbackFor =  {
37      PortalException.class, SystemException.class})
38  public interface SCFrameworkVersionPersistence {
39      public com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion create(
40          long frameworkVersionId);
41  
42      public com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion remove(
43          long frameworkVersionId)
44          throws com.liferay.portal.SystemException,
45              com.liferay.portlet.softwarecatalog.NoSuchFrameworkVersionException;
46  
47      public com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion remove(
48          com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion scFrameworkVersion)
49          throws com.liferay.portal.SystemException;
50  
51      /**
52       * @deprecated Use <code>update(SCFrameworkVersion scFrameworkVersion, boolean merge)</code>.
53       */
54      public com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion update(
55          com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion scFrameworkVersion)
56          throws com.liferay.portal.SystemException;
57  
58      /**
59       * Add, update, or merge, the entity. This method also calls the model
60       * listeners to trigger the proper events associated with adding, deleting,
61       * or updating an entity.
62       *
63       * @param        scFrameworkVersion the entity to add, update, or merge
64       * @param        merge boolean value for whether to merge the entity. The
65       *                default value is false. Setting merge to true is more
66       *                expensive and should only be true when scFrameworkVersion is
67       *                transient. See LEP-5473 for a detailed discussion of this
68       *                method.
69       * @return        true if the portlet can be displayed via Ajax
70       */
71      public com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion update(
72          com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion scFrameworkVersion,
73          boolean merge) throws com.liferay.portal.SystemException;
74  
75      public com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion updateImpl(
76          com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion scFrameworkVersion,
77          boolean merge) throws com.liferay.portal.SystemException;
78  
79      @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
80      public com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion findByPrimaryKey(
81          long frameworkVersionId)
82          throws com.liferay.portal.SystemException,
83              com.liferay.portlet.softwarecatalog.NoSuchFrameworkVersionException;
84  
85      public com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion fetchByPrimaryKey(
86          long frameworkVersionId) throws com.liferay.portal.SystemException;
87  
88      @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
89      public java.util.List<com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion> findByGroupId(
90          long groupId) throws com.liferay.portal.SystemException;
91  
92      @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
93      public java.util.List<com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion> findByGroupId(
94          long groupId, int start, int end)
95          throws com.liferay.portal.SystemException;
96  
97      @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
98      public java.util.List<com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion> findByGroupId(
99          long groupId, int start, int end,
100         com.liferay.portal.kernel.util.OrderByComparator obc)
101         throws com.liferay.portal.SystemException;
102 
103     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
104     public com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion findByGroupId_First(
105         long groupId, com.liferay.portal.kernel.util.OrderByComparator obc)
106         throws com.liferay.portal.SystemException,
107             com.liferay.portlet.softwarecatalog.NoSuchFrameworkVersionException;
108 
109     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
110     public com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion findByGroupId_Last(
111         long groupId, com.liferay.portal.kernel.util.OrderByComparator obc)
112         throws com.liferay.portal.SystemException,
113             com.liferay.portlet.softwarecatalog.NoSuchFrameworkVersionException;
114 
115     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
116     public com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion[] findByGroupId_PrevAndNext(
117         long frameworkVersionId, long groupId,
118         com.liferay.portal.kernel.util.OrderByComparator obc)
119         throws com.liferay.portal.SystemException,
120             com.liferay.portlet.softwarecatalog.NoSuchFrameworkVersionException;
121 
122     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
123     public java.util.List<com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion> findByCompanyId(
124         long companyId) throws com.liferay.portal.SystemException;
125 
126     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
127     public java.util.List<com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion> findByCompanyId(
128         long companyId, int start, int end)
129         throws com.liferay.portal.SystemException;
130 
131     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
132     public java.util.List<com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion> findByCompanyId(
133         long companyId, int start, int end,
134         com.liferay.portal.kernel.util.OrderByComparator obc)
135         throws com.liferay.portal.SystemException;
136 
137     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
138     public com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion findByCompanyId_First(
139         long companyId, com.liferay.portal.kernel.util.OrderByComparator obc)
140         throws com.liferay.portal.SystemException,
141             com.liferay.portlet.softwarecatalog.NoSuchFrameworkVersionException;
142 
143     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
144     public com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion findByCompanyId_Last(
145         long companyId, com.liferay.portal.kernel.util.OrderByComparator obc)
146         throws com.liferay.portal.SystemException,
147             com.liferay.portlet.softwarecatalog.NoSuchFrameworkVersionException;
148 
149     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
150     public com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion[] findByCompanyId_PrevAndNext(
151         long frameworkVersionId, long companyId,
152         com.liferay.portal.kernel.util.OrderByComparator obc)
153         throws com.liferay.portal.SystemException,
154             com.liferay.portlet.softwarecatalog.NoSuchFrameworkVersionException;
155 
156     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
157     public java.util.List<com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion> findByG_A(
158         long groupId, boolean active) throws com.liferay.portal.SystemException;
159 
160     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
161     public java.util.List<com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion> findByG_A(
162         long groupId, boolean active, int start, int end)
163         throws com.liferay.portal.SystemException;
164 
165     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
166     public java.util.List<com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion> findByG_A(
167         long groupId, boolean active, int start, int end,
168         com.liferay.portal.kernel.util.OrderByComparator obc)
169         throws com.liferay.portal.SystemException;
170 
171     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
172     public com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion findByG_A_First(
173         long groupId, boolean active,
174         com.liferay.portal.kernel.util.OrderByComparator obc)
175         throws com.liferay.portal.SystemException,
176             com.liferay.portlet.softwarecatalog.NoSuchFrameworkVersionException;
177 
178     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
179     public com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion findByG_A_Last(
180         long groupId, boolean active,
181         com.liferay.portal.kernel.util.OrderByComparator obc)
182         throws com.liferay.portal.SystemException,
183             com.liferay.portlet.softwarecatalog.NoSuchFrameworkVersionException;
184 
185     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
186     public com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion[] findByG_A_PrevAndNext(
187         long frameworkVersionId, long groupId, boolean active,
188         com.liferay.portal.kernel.util.OrderByComparator obc)
189         throws com.liferay.portal.SystemException,
190             com.liferay.portlet.softwarecatalog.NoSuchFrameworkVersionException;
191 
192     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
193     public java.util.List<Object> findWithDynamicQuery(
194         com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
195         throws com.liferay.portal.SystemException;
196 
197     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
198     public java.util.List<Object> findWithDynamicQuery(
199         com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
200         int end) throws com.liferay.portal.SystemException;
201 
202     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
203     public java.util.List<com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion> findAll()
204         throws com.liferay.portal.SystemException;
205 
206     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
207     public java.util.List<com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion> findAll(
208         int start, int end) throws com.liferay.portal.SystemException;
209 
210     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
211     public java.util.List<com.liferay.portlet.softwarecatalog.model.SCFrameworkVersion> findAll(
212         int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
213         throws com.liferay.portal.SystemException;
214 
215     public void removeByGroupId(long groupId)
216         throws com.liferay.portal.SystemException;
217 
218     public void removeByCompanyId(long companyId)
219         throws com.liferay.portal.SystemException;
220 
221     public void removeByG_A(long groupId, boolean active)
222         throws com.liferay.portal.SystemException;
223 
224     public void removeAll() throws com.liferay.portal.SystemException;
225 
226     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
227     public int countByGroupId(long groupId)
228         throws com.liferay.portal.SystemException;
229 
230     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
231     public int countByCompanyId(long companyId)
232         throws com.liferay.portal.SystemException;
233 
234     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
235     public int countByG_A(long groupId, boolean active)
236         throws com.liferay.portal.SystemException;
237 
238     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
239     public int countAll() throws com.liferay.portal.SystemException;
240 
241     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
242     public java.util.List<com.liferay.portlet.softwarecatalog.model.SCProductVersion> getSCProductVersions(
243         long pk) throws com.liferay.portal.SystemException;
244 
245     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
246     public java.util.List<com.liferay.portlet.softwarecatalog.model.SCProductVersion> getSCProductVersions(
247         long pk, int start, int end) throws com.liferay.portal.SystemException;
248 
249     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
250     public java.util.List<com.liferay.portlet.softwarecatalog.model.SCProductVersion> getSCProductVersions(
251         long pk, int start, int end,
252         com.liferay.portal.kernel.util.OrderByComparator obc)
253         throws com.liferay.portal.SystemException;
254 
255     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
256     public int getSCProductVersionsSize(long pk)
257         throws com.liferay.portal.SystemException;
258 
259     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
260     public boolean containsSCProductVersion(long pk, long scProductVersionPK)
261         throws com.liferay.portal.SystemException;
262 
263     @Transactional(propagation = Propagation.SUPPORTS, readOnly = true)
264     public boolean containsSCProductVersions(long pk)
265         throws com.liferay.portal.SystemException;
266 
267     public void addSCProductVersion(long pk, long scProductVersionPK)
268         throws com.liferay.portal.SystemException;
269 
270     public void addSCProductVersion(long pk,
271         com.liferay.portlet.softwarecatalog.model.SCProductVersion scProductVersion)
272         throws com.liferay.portal.SystemException;
273 
274     public void addSCProductVersions(long pk, long[] scProductVersionPKs)
275         throws com.liferay.portal.SystemException;
276 
277     public void addSCProductVersions(long pk,
278         java.util.List<com.liferay.portlet.softwarecatalog.model.SCProductVersion> scProductVersions)
279         throws com.liferay.portal.SystemException;
280 
281     public void clearSCProductVersions(long pk)
282         throws com.liferay.portal.SystemException;
283 
284     public void removeSCProductVersion(long pk, long scProductVersionPK)
285         throws com.liferay.portal.SystemException;
286 
287     public void removeSCProductVersion(long pk,
288         com.liferay.portlet.softwarecatalog.model.SCProductVersion scProductVersion)
289         throws com.liferay.portal.SystemException;
290 
291     public void removeSCProductVersions(long pk, long[] scProductVersionPKs)
292         throws com.liferay.portal.SystemException;
293 
294     public void removeSCProductVersions(long pk,
295         java.util.List<com.liferay.portlet.softwarecatalog.model.SCProductVersion> scProductVersions)
296         throws com.liferay.portal.SystemException;
297 
298     public void setSCProductVersions(long pk, long[] scProductVersionPKs)
299         throws com.liferay.portal.SystemException;
300 
301     public void setSCProductVersions(long pk,
302         java.util.List<com.liferay.portlet.softwarecatalog.model.SCProductVersion> scProductVersions)
303         throws com.liferay.portal.SystemException;
304 
305     public void registerListener(
306         com.liferay.portal.model.ModelListener listener);
307 
308     public void unregisterListener(
309         com.liferay.portal.model.ModelListener listener);
310 }