1
22
23 package com.liferay.portlet.ratings.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.ResourceLocalService;
33 import com.liferay.portal.service.ResourceService;
34 import com.liferay.portal.service.UserLocalService;
35 import com.liferay.portal.service.UserService;
36 import com.liferay.portal.service.persistence.ResourceFinder;
37 import com.liferay.portal.service.persistence.ResourcePersistence;
38 import com.liferay.portal.service.persistence.UserFinder;
39 import com.liferay.portal.service.persistence.UserPersistence;
40 import com.liferay.portal.util.PortalUtil;
41
42 import com.liferay.portlet.blogs.service.BlogsEntryLocalService;
43 import com.liferay.portlet.blogs.service.BlogsEntryService;
44 import com.liferay.portlet.blogs.service.BlogsStatsUserLocalService;
45 import com.liferay.portlet.blogs.service.persistence.BlogsEntryFinder;
46 import com.liferay.portlet.blogs.service.persistence.BlogsEntryPersistence;
47 import com.liferay.portlet.blogs.service.persistence.BlogsStatsUserFinder;
48 import com.liferay.portlet.blogs.service.persistence.BlogsStatsUserPersistence;
49 import com.liferay.portlet.ratings.model.RatingsEntry;
50 import com.liferay.portlet.ratings.service.RatingsEntryLocalService;
51 import com.liferay.portlet.ratings.service.RatingsEntryService;
52 import com.liferay.portlet.ratings.service.RatingsStatsLocalService;
53 import com.liferay.portlet.ratings.service.persistence.RatingsEntryPersistence;
54 import com.liferay.portlet.ratings.service.persistence.RatingsStatsPersistence;
55
56 import java.util.List;
57
58
64 public abstract class RatingsEntryLocalServiceBaseImpl
65 implements RatingsEntryLocalService {
66 public RatingsEntry addRatingsEntry(RatingsEntry ratingsEntry)
67 throws SystemException {
68 ratingsEntry.setNew(true);
69
70 return ratingsEntryPersistence.update(ratingsEntry, false);
71 }
72
73 public RatingsEntry createRatingsEntry(long entryId) {
74 return ratingsEntryPersistence.create(entryId);
75 }
76
77 public void deleteRatingsEntry(long entryId)
78 throws PortalException, SystemException {
79 ratingsEntryPersistence.remove(entryId);
80 }
81
82 public void deleteRatingsEntry(RatingsEntry ratingsEntry)
83 throws SystemException {
84 ratingsEntryPersistence.remove(ratingsEntry);
85 }
86
87 public List<Object> dynamicQuery(DynamicQuery dynamicQuery)
88 throws SystemException {
89 return ratingsEntryPersistence.findWithDynamicQuery(dynamicQuery);
90 }
91
92 public List<Object> dynamicQuery(DynamicQuery dynamicQuery, int start,
93 int end) throws SystemException {
94 return ratingsEntryPersistence.findWithDynamicQuery(dynamicQuery,
95 start, end);
96 }
97
98 public RatingsEntry getRatingsEntry(long entryId)
99 throws PortalException, SystemException {
100 return ratingsEntryPersistence.findByPrimaryKey(entryId);
101 }
102
103 public List<RatingsEntry> getRatingsEntries(int start, int end)
104 throws SystemException {
105 return ratingsEntryPersistence.findAll(start, end);
106 }
107
108 public int getRatingsEntriesCount() throws SystemException {
109 return ratingsEntryPersistence.countAll();
110 }
111
112 public RatingsEntry updateRatingsEntry(RatingsEntry ratingsEntry)
113 throws SystemException {
114 ratingsEntry.setNew(false);
115
116 return ratingsEntryPersistence.update(ratingsEntry, true);
117 }
118
119 public RatingsEntry updateRatingsEntry(RatingsEntry ratingsEntry,
120 boolean merge) throws SystemException {
121 ratingsEntry.setNew(false);
122
123 return ratingsEntryPersistence.update(ratingsEntry, merge);
124 }
125
126 public RatingsEntryLocalService getRatingsEntryLocalService() {
127 return ratingsEntryLocalService;
128 }
129
130 public void setRatingsEntryLocalService(
131 RatingsEntryLocalService ratingsEntryLocalService) {
132 this.ratingsEntryLocalService = ratingsEntryLocalService;
133 }
134
135 public RatingsEntryService getRatingsEntryService() {
136 return ratingsEntryService;
137 }
138
139 public void setRatingsEntryService(RatingsEntryService ratingsEntryService) {
140 this.ratingsEntryService = ratingsEntryService;
141 }
142
143 public RatingsEntryPersistence getRatingsEntryPersistence() {
144 return ratingsEntryPersistence;
145 }
146
147 public void setRatingsEntryPersistence(
148 RatingsEntryPersistence ratingsEntryPersistence) {
149 this.ratingsEntryPersistence = ratingsEntryPersistence;
150 }
151
152 public RatingsStatsLocalService getRatingsStatsLocalService() {
153 return ratingsStatsLocalService;
154 }
155
156 public void setRatingsStatsLocalService(
157 RatingsStatsLocalService ratingsStatsLocalService) {
158 this.ratingsStatsLocalService = ratingsStatsLocalService;
159 }
160
161 public RatingsStatsPersistence getRatingsStatsPersistence() {
162 return ratingsStatsPersistence;
163 }
164
165 public void setRatingsStatsPersistence(
166 RatingsStatsPersistence ratingsStatsPersistence) {
167 this.ratingsStatsPersistence = ratingsStatsPersistence;
168 }
169
170 public CounterLocalService getCounterLocalService() {
171 return counterLocalService;
172 }
173
174 public void setCounterLocalService(CounterLocalService counterLocalService) {
175 this.counterLocalService = counterLocalService;
176 }
177
178 public CounterService getCounterService() {
179 return counterService;
180 }
181
182 public void setCounterService(CounterService counterService) {
183 this.counterService = counterService;
184 }
185
186 public ResourceLocalService getResourceLocalService() {
187 return resourceLocalService;
188 }
189
190 public void setResourceLocalService(
191 ResourceLocalService resourceLocalService) {
192 this.resourceLocalService = resourceLocalService;
193 }
194
195 public ResourceService getResourceService() {
196 return resourceService;
197 }
198
199 public void setResourceService(ResourceService resourceService) {
200 this.resourceService = resourceService;
201 }
202
203 public ResourcePersistence getResourcePersistence() {
204 return resourcePersistence;
205 }
206
207 public void setResourcePersistence(ResourcePersistence resourcePersistence) {
208 this.resourcePersistence = resourcePersistence;
209 }
210
211 public ResourceFinder getResourceFinder() {
212 return resourceFinder;
213 }
214
215 public void setResourceFinder(ResourceFinder resourceFinder) {
216 this.resourceFinder = resourceFinder;
217 }
218
219 public UserLocalService getUserLocalService() {
220 return userLocalService;
221 }
222
223 public void setUserLocalService(UserLocalService userLocalService) {
224 this.userLocalService = userLocalService;
225 }
226
227 public UserService getUserService() {
228 return userService;
229 }
230
231 public void setUserService(UserService userService) {
232 this.userService = userService;
233 }
234
235 public UserPersistence getUserPersistence() {
236 return userPersistence;
237 }
238
239 public void setUserPersistence(UserPersistence userPersistence) {
240 this.userPersistence = userPersistence;
241 }
242
243 public UserFinder getUserFinder() {
244 return userFinder;
245 }
246
247 public void setUserFinder(UserFinder userFinder) {
248 this.userFinder = userFinder;
249 }
250
251 public BlogsEntryLocalService getBlogsEntryLocalService() {
252 return blogsEntryLocalService;
253 }
254
255 public void setBlogsEntryLocalService(
256 BlogsEntryLocalService blogsEntryLocalService) {
257 this.blogsEntryLocalService = blogsEntryLocalService;
258 }
259
260 public BlogsEntryService getBlogsEntryService() {
261 return blogsEntryService;
262 }
263
264 public void setBlogsEntryService(BlogsEntryService blogsEntryService) {
265 this.blogsEntryService = blogsEntryService;
266 }
267
268 public BlogsEntryPersistence getBlogsEntryPersistence() {
269 return blogsEntryPersistence;
270 }
271
272 public void setBlogsEntryPersistence(
273 BlogsEntryPersistence blogsEntryPersistence) {
274 this.blogsEntryPersistence = blogsEntryPersistence;
275 }
276
277 public BlogsEntryFinder getBlogsEntryFinder() {
278 return blogsEntryFinder;
279 }
280
281 public void setBlogsEntryFinder(BlogsEntryFinder blogsEntryFinder) {
282 this.blogsEntryFinder = blogsEntryFinder;
283 }
284
285 public BlogsStatsUserLocalService getBlogsStatsUserLocalService() {
286 return blogsStatsUserLocalService;
287 }
288
289 public void setBlogsStatsUserLocalService(
290 BlogsStatsUserLocalService blogsStatsUserLocalService) {
291 this.blogsStatsUserLocalService = blogsStatsUserLocalService;
292 }
293
294 public BlogsStatsUserPersistence getBlogsStatsUserPersistence() {
295 return blogsStatsUserPersistence;
296 }
297
298 public void setBlogsStatsUserPersistence(
299 BlogsStatsUserPersistence blogsStatsUserPersistence) {
300 this.blogsStatsUserPersistence = blogsStatsUserPersistence;
301 }
302
303 public BlogsStatsUserFinder getBlogsStatsUserFinder() {
304 return blogsStatsUserFinder;
305 }
306
307 public void setBlogsStatsUserFinder(
308 BlogsStatsUserFinder blogsStatsUserFinder) {
309 this.blogsStatsUserFinder = blogsStatsUserFinder;
310 }
311
312 protected void runSQL(String sql) throws SystemException {
313 try {
314 PortalUtil.runSQL(sql);
315 }
316 catch (Exception e) {
317 throw new SystemException(e);
318 }
319 }
320
321 @BeanReference(name = "com.liferay.portlet.ratings.service.RatingsEntryLocalService.impl")
322 protected RatingsEntryLocalService ratingsEntryLocalService;
323 @BeanReference(name = "com.liferay.portlet.ratings.service.RatingsEntryService.impl")
324 protected RatingsEntryService ratingsEntryService;
325 @BeanReference(name = "com.liferay.portlet.ratings.service.persistence.RatingsEntryPersistence.impl")
326 protected RatingsEntryPersistence ratingsEntryPersistence;
327 @BeanReference(name = "com.liferay.portlet.ratings.service.RatingsStatsLocalService.impl")
328 protected RatingsStatsLocalService ratingsStatsLocalService;
329 @BeanReference(name = "com.liferay.portlet.ratings.service.persistence.RatingsStatsPersistence.impl")
330 protected RatingsStatsPersistence ratingsStatsPersistence;
331 @BeanReference(name = "com.liferay.counter.service.CounterLocalService.impl")
332 protected CounterLocalService counterLocalService;
333 @BeanReference(name = "com.liferay.counter.service.CounterService.impl")
334 protected CounterService counterService;
335 @BeanReference(name = "com.liferay.portal.service.ResourceLocalService.impl")
336 protected ResourceLocalService resourceLocalService;
337 @BeanReference(name = "com.liferay.portal.service.ResourceService.impl")
338 protected ResourceService resourceService;
339 @BeanReference(name = "com.liferay.portal.service.persistence.ResourcePersistence.impl")
340 protected ResourcePersistence resourcePersistence;
341 @BeanReference(name = "com.liferay.portal.service.persistence.ResourceFinder.impl")
342 protected ResourceFinder resourceFinder;
343 @BeanReference(name = "com.liferay.portal.service.UserLocalService.impl")
344 protected UserLocalService userLocalService;
345 @BeanReference(name = "com.liferay.portal.service.UserService.impl")
346 protected UserService userService;
347 @BeanReference(name = "com.liferay.portal.service.persistence.UserPersistence.impl")
348 protected UserPersistence userPersistence;
349 @BeanReference(name = "com.liferay.portal.service.persistence.UserFinder.impl")
350 protected UserFinder userFinder;
351 @BeanReference(name = "com.liferay.portlet.blogs.service.BlogsEntryLocalService.impl")
352 protected BlogsEntryLocalService blogsEntryLocalService;
353 @BeanReference(name = "com.liferay.portlet.blogs.service.BlogsEntryService.impl")
354 protected BlogsEntryService blogsEntryService;
355 @BeanReference(name = "com.liferay.portlet.blogs.service.persistence.BlogsEntryPersistence.impl")
356 protected BlogsEntryPersistence blogsEntryPersistence;
357 @BeanReference(name = "com.liferay.portlet.blogs.service.persistence.BlogsEntryFinder.impl")
358 protected BlogsEntryFinder blogsEntryFinder;
359 @BeanReference(name = "com.liferay.portlet.blogs.service.BlogsStatsUserLocalService.impl")
360 protected BlogsStatsUserLocalService blogsStatsUserLocalService;
361 @BeanReference(name = "com.liferay.portlet.blogs.service.persistence.BlogsStatsUserPersistence.impl")
362 protected BlogsStatsUserPersistence blogsStatsUserPersistence;
363 @BeanReference(name = "com.liferay.portlet.blogs.service.persistence.BlogsStatsUserFinder.impl")
364 protected BlogsStatsUserFinder blogsStatsUserFinder;
365 }