1   /**
2    * Copyright (c) 2000-2009 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.base;
24  
25  import com.liferay.counter.service.CounterLocalService;
26  import com.liferay.counter.service.CounterService;
27  
28  import com.liferay.portal.PortalException;
29  import com.liferay.portal.SystemException;
30  import com.liferay.portal.kernel.annotation.BeanReference;
31  import com.liferay.portal.kernel.dao.orm.DynamicQuery;
32  import com.liferay.portal.service.UserLocalService;
33  import com.liferay.portal.service.UserService;
34  import com.liferay.portal.service.persistence.UserFinder;
35  import com.liferay.portal.service.persistence.UserPersistence;
36  
37  import com.liferay.portlet.softwarecatalog.model.SCProductVersion;
38  import com.liferay.portlet.softwarecatalog.service.SCFrameworkVersionLocalService;
39  import com.liferay.portlet.softwarecatalog.service.SCFrameworkVersionService;
40  import com.liferay.portlet.softwarecatalog.service.SCLicenseLocalService;
41  import com.liferay.portlet.softwarecatalog.service.SCLicenseService;
42  import com.liferay.portlet.softwarecatalog.service.SCProductEntryLocalService;
43  import com.liferay.portlet.softwarecatalog.service.SCProductEntryService;
44  import com.liferay.portlet.softwarecatalog.service.SCProductScreenshotLocalService;
45  import com.liferay.portlet.softwarecatalog.service.SCProductVersionLocalService;
46  import com.liferay.portlet.softwarecatalog.service.SCProductVersionService;
47  import com.liferay.portlet.softwarecatalog.service.persistence.SCFrameworkVersionPersistence;
48  import com.liferay.portlet.softwarecatalog.service.persistence.SCLicensePersistence;
49  import com.liferay.portlet.softwarecatalog.service.persistence.SCProductEntryPersistence;
50  import com.liferay.portlet.softwarecatalog.service.persistence.SCProductScreenshotPersistence;
51  import com.liferay.portlet.softwarecatalog.service.persistence.SCProductVersionPersistence;
52  
53  import java.util.List;
54  
55  /**
56   * <a href="SCProductVersionLocalServiceBaseImpl.java.html"><b><i>View Source</i></b></a>
57   *
58   * @author Brian Wing Shun Chan
59   *
60   */
61  public abstract class SCProductVersionLocalServiceBaseImpl
62      implements SCProductVersionLocalService {
63      public SCProductVersion addSCProductVersion(
64          SCProductVersion scProductVersion) throws SystemException {
65          scProductVersion.setNew(true);
66  
67          return scProductVersionPersistence.update(scProductVersion, false);
68      }
69  
70      public SCProductVersion createSCProductVersion(long productVersionId) {
71          return scProductVersionPersistence.create(productVersionId);
72      }
73  
74      public void deleteSCProductVersion(long productVersionId)
75          throws PortalException, SystemException {
76          scProductVersionPersistence.remove(productVersionId);
77      }
78  
79      public void deleteSCProductVersion(SCProductVersion scProductVersion)
80          throws SystemException {
81          scProductVersionPersistence.remove(scProductVersion);
82      }
83  
84      public List<Object> dynamicQuery(DynamicQuery dynamicQuery)
85          throws SystemException {
86          return scProductVersionPersistence.findWithDynamicQuery(dynamicQuery);
87      }
88  
89      public List<Object> dynamicQuery(DynamicQuery dynamicQuery, int start,
90          int end) throws SystemException {
91          return scProductVersionPersistence.findWithDynamicQuery(dynamicQuery,
92              start, end);
93      }
94  
95      public SCProductVersion getSCProductVersion(long productVersionId)
96          throws PortalException, SystemException {
97          return scProductVersionPersistence.findByPrimaryKey(productVersionId);
98      }
99  
100     public List<SCProductVersion> getSCProductVersions(int start, int end)
101         throws SystemException {
102         return scProductVersionPersistence.findAll(start, end);
103     }
104 
105     public int getSCProductVersionsCount() throws SystemException {
106         return scProductVersionPersistence.countAll();
107     }
108 
109     public SCProductVersion updateSCProductVersion(
110         SCProductVersion scProductVersion) throws SystemException {
111         scProductVersion.setNew(false);
112 
113         return scProductVersionPersistence.update(scProductVersion, true);
114     }
115 
116     public SCLicenseLocalService getSCLicenseLocalService() {
117         return scLicenseLocalService;
118     }
119 
120     public void setSCLicenseLocalService(
121         SCLicenseLocalService scLicenseLocalService) {
122         this.scLicenseLocalService = scLicenseLocalService;
123     }
124 
125     public SCLicenseService getSCLicenseService() {
126         return scLicenseService;
127     }
128 
129     public void setSCLicenseService(SCLicenseService scLicenseService) {
130         this.scLicenseService = scLicenseService;
131     }
132 
133     public SCLicensePersistence getSCLicensePersistence() {
134         return scLicensePersistence;
135     }
136 
137     public void setSCLicensePersistence(
138         SCLicensePersistence scLicensePersistence) {
139         this.scLicensePersistence = scLicensePersistence;
140     }
141 
142     public SCFrameworkVersionLocalService getSCFrameworkVersionLocalService() {
143         return scFrameworkVersionLocalService;
144     }
145 
146     public void setSCFrameworkVersionLocalService(
147         SCFrameworkVersionLocalService scFrameworkVersionLocalService) {
148         this.scFrameworkVersionLocalService = scFrameworkVersionLocalService;
149     }
150 
151     public SCFrameworkVersionService getSCFrameworkVersionService() {
152         return scFrameworkVersionService;
153     }
154 
155     public void setSCFrameworkVersionService(
156         SCFrameworkVersionService scFrameworkVersionService) {
157         this.scFrameworkVersionService = scFrameworkVersionService;
158     }
159 
160     public SCFrameworkVersionPersistence getSCFrameworkVersionPersistence() {
161         return scFrameworkVersionPersistence;
162     }
163 
164     public void setSCFrameworkVersionPersistence(
165         SCFrameworkVersionPersistence scFrameworkVersionPersistence) {
166         this.scFrameworkVersionPersistence = scFrameworkVersionPersistence;
167     }
168 
169     public SCProductEntryLocalService getSCProductEntryLocalService() {
170         return scProductEntryLocalService;
171     }
172 
173     public void setSCProductEntryLocalService(
174         SCProductEntryLocalService scProductEntryLocalService) {
175         this.scProductEntryLocalService = scProductEntryLocalService;
176     }
177 
178     public SCProductEntryService getSCProductEntryService() {
179         return scProductEntryService;
180     }
181 
182     public void setSCProductEntryService(
183         SCProductEntryService scProductEntryService) {
184         this.scProductEntryService = scProductEntryService;
185     }
186 
187     public SCProductEntryPersistence getSCProductEntryPersistence() {
188         return scProductEntryPersistence;
189     }
190 
191     public void setSCProductEntryPersistence(
192         SCProductEntryPersistence scProductEntryPersistence) {
193         this.scProductEntryPersistence = scProductEntryPersistence;
194     }
195 
196     public SCProductScreenshotLocalService getSCProductScreenshotLocalService() {
197         return scProductScreenshotLocalService;
198     }
199 
200     public void setSCProductScreenshotLocalService(
201         SCProductScreenshotLocalService scProductScreenshotLocalService) {
202         this.scProductScreenshotLocalService = scProductScreenshotLocalService;
203     }
204 
205     public SCProductScreenshotPersistence getSCProductScreenshotPersistence() {
206         return scProductScreenshotPersistence;
207     }
208 
209     public void setSCProductScreenshotPersistence(
210         SCProductScreenshotPersistence scProductScreenshotPersistence) {
211         this.scProductScreenshotPersistence = scProductScreenshotPersistence;
212     }
213 
214     public SCProductVersionLocalService getSCProductVersionLocalService() {
215         return scProductVersionLocalService;
216     }
217 
218     public void setSCProductVersionLocalService(
219         SCProductVersionLocalService scProductVersionLocalService) {
220         this.scProductVersionLocalService = scProductVersionLocalService;
221     }
222 
223     public SCProductVersionService getSCProductVersionService() {
224         return scProductVersionService;
225     }
226 
227     public void setSCProductVersionService(
228         SCProductVersionService scProductVersionService) {
229         this.scProductVersionService = scProductVersionService;
230     }
231 
232     public SCProductVersionPersistence getSCProductVersionPersistence() {
233         return scProductVersionPersistence;
234     }
235 
236     public void setSCProductVersionPersistence(
237         SCProductVersionPersistence scProductVersionPersistence) {
238         this.scProductVersionPersistence = scProductVersionPersistence;
239     }
240 
241     public CounterLocalService getCounterLocalService() {
242         return counterLocalService;
243     }
244 
245     public void setCounterLocalService(CounterLocalService counterLocalService) {
246         this.counterLocalService = counterLocalService;
247     }
248 
249     public CounterService getCounterService() {
250         return counterService;
251     }
252 
253     public void setCounterService(CounterService counterService) {
254         this.counterService = counterService;
255     }
256 
257     public UserLocalService getUserLocalService() {
258         return userLocalService;
259     }
260 
261     public void setUserLocalService(UserLocalService userLocalService) {
262         this.userLocalService = userLocalService;
263     }
264 
265     public UserService getUserService() {
266         return userService;
267     }
268 
269     public void setUserService(UserService userService) {
270         this.userService = userService;
271     }
272 
273     public UserPersistence getUserPersistence() {
274         return userPersistence;
275     }
276 
277     public void setUserPersistence(UserPersistence userPersistence) {
278         this.userPersistence = userPersistence;
279     }
280 
281     public UserFinder getUserFinder() {
282         return userFinder;
283     }
284 
285     public void setUserFinder(UserFinder userFinder) {
286         this.userFinder = userFinder;
287     }
288 
289     @BeanReference(name = "com.liferay.portlet.softwarecatalog.service.SCLicenseLocalService.impl")
290     protected SCLicenseLocalService scLicenseLocalService;
291     @BeanReference(name = "com.liferay.portlet.softwarecatalog.service.SCLicenseService.impl")
292     protected SCLicenseService scLicenseService;
293     @BeanReference(name = "com.liferay.portlet.softwarecatalog.service.persistence.SCLicensePersistence.impl")
294     protected SCLicensePersistence scLicensePersistence;
295     @BeanReference(name = "com.liferay.portlet.softwarecatalog.service.SCFrameworkVersionLocalService.impl")
296     protected SCFrameworkVersionLocalService scFrameworkVersionLocalService;
297     @BeanReference(name = "com.liferay.portlet.softwarecatalog.service.SCFrameworkVersionService.impl")
298     protected SCFrameworkVersionService scFrameworkVersionService;
299     @BeanReference(name = "com.liferay.portlet.softwarecatalog.service.persistence.SCFrameworkVersionPersistence.impl")
300     protected SCFrameworkVersionPersistence scFrameworkVersionPersistence;
301     @BeanReference(name = "com.liferay.portlet.softwarecatalog.service.SCProductEntryLocalService.impl")
302     protected SCProductEntryLocalService scProductEntryLocalService;
303     @BeanReference(name = "com.liferay.portlet.softwarecatalog.service.SCProductEntryService.impl")
304     protected SCProductEntryService scProductEntryService;
305     @BeanReference(name = "com.liferay.portlet.softwarecatalog.service.persistence.SCProductEntryPersistence.impl")
306     protected SCProductEntryPersistence scProductEntryPersistence;
307     @BeanReference(name = "com.liferay.portlet.softwarecatalog.service.SCProductScreenshotLocalService.impl")
308     protected SCProductScreenshotLocalService scProductScreenshotLocalService;
309     @BeanReference(name = "com.liferay.portlet.softwarecatalog.service.persistence.SCProductScreenshotPersistence.impl")
310     protected SCProductScreenshotPersistence scProductScreenshotPersistence;
311     @BeanReference(name = "com.liferay.portlet.softwarecatalog.service.SCProductVersionLocalService.impl")
312     protected SCProductVersionLocalService scProductVersionLocalService;
313     @BeanReference(name = "com.liferay.portlet.softwarecatalog.service.SCProductVersionService.impl")
314     protected SCProductVersionService scProductVersionService;
315     @BeanReference(name = "com.liferay.portlet.softwarecatalog.service.persistence.SCProductVersionPersistence.impl")
316     protected SCProductVersionPersistence scProductVersionPersistence;
317     @BeanReference(name = "com.liferay.counter.service.CounterLocalService.impl")
318     protected CounterLocalService counterLocalService;
319     @BeanReference(name = "com.liferay.counter.service.CounterService.impl")
320     protected CounterService counterService;
321     @BeanReference(name = "com.liferay.portal.service.UserLocalService.impl")
322     protected UserLocalService userLocalService;
323     @BeanReference(name = "com.liferay.portal.service.UserService.impl")
324     protected UserService userService;
325     @BeanReference(name = "com.liferay.portal.service.persistence.UserPersistence.impl")
326     protected UserPersistence userPersistence;
327     @BeanReference(name = "com.liferay.portal.service.persistence.UserFinder.impl")
328     protected UserFinder userFinder;
329 }