1
22
23 package com.liferay.portlet.calendar.service.base;
24
25 import com.liferay.counter.service.CounterLocalService;
26 import com.liferay.counter.service.CounterService;
27
28 import com.liferay.mail.service.MailService;
29
30 import com.liferay.portal.PortalException;
31 import com.liferay.portal.SystemException;
32 import com.liferay.portal.kernel.annotation.BeanReference;
33 import com.liferay.portal.kernel.dao.db.DB;
34 import com.liferay.portal.kernel.dao.db.DBFactoryUtil;
35 import com.liferay.portal.kernel.dao.orm.DynamicQuery;
36 import com.liferay.portal.service.CompanyLocalService;
37 import com.liferay.portal.service.CompanyService;
38 import com.liferay.portal.service.GroupLocalService;
39 import com.liferay.portal.service.GroupService;
40 import com.liferay.portal.service.PortletPreferencesLocalService;
41 import com.liferay.portal.service.PortletPreferencesService;
42 import com.liferay.portal.service.ResourceLocalService;
43 import com.liferay.portal.service.ResourceService;
44 import com.liferay.portal.service.UserLocalService;
45 import com.liferay.portal.service.UserService;
46 import com.liferay.portal.service.persistence.CompanyPersistence;
47 import com.liferay.portal.service.persistence.GroupFinder;
48 import com.liferay.portal.service.persistence.GroupPersistence;
49 import com.liferay.portal.service.persistence.PortletPreferencesFinder;
50 import com.liferay.portal.service.persistence.PortletPreferencesPersistence;
51 import com.liferay.portal.service.persistence.ResourceFinder;
52 import com.liferay.portal.service.persistence.ResourcePersistence;
53 import com.liferay.portal.service.persistence.UserFinder;
54 import com.liferay.portal.service.persistence.UserPersistence;
55
56 import com.liferay.portlet.calendar.model.CalEvent;
57 import com.liferay.portlet.calendar.service.CalEventLocalService;
58 import com.liferay.portlet.calendar.service.CalEventService;
59 import com.liferay.portlet.calendar.service.persistence.CalEventFinder;
60 import com.liferay.portlet.calendar.service.persistence.CalEventPersistence;
61 import com.liferay.portlet.expando.service.ExpandoValueLocalService;
62 import com.liferay.portlet.expando.service.ExpandoValueService;
63 import com.liferay.portlet.expando.service.persistence.ExpandoValuePersistence;
64 import com.liferay.portlet.social.service.SocialActivityLocalService;
65 import com.liferay.portlet.social.service.persistence.SocialActivityFinder;
66 import com.liferay.portlet.social.service.persistence.SocialActivityPersistence;
67 import com.liferay.portlet.tags.service.TagsAssetLocalService;
68 import com.liferay.portlet.tags.service.TagsAssetService;
69 import com.liferay.portlet.tags.service.TagsEntryLocalService;
70 import com.liferay.portlet.tags.service.TagsEntryService;
71 import com.liferay.portlet.tags.service.persistence.TagsAssetFinder;
72 import com.liferay.portlet.tags.service.persistence.TagsAssetPersistence;
73 import com.liferay.portlet.tags.service.persistence.TagsEntryFinder;
74 import com.liferay.portlet.tags.service.persistence.TagsEntryPersistence;
75
76 import java.util.List;
77
78
84 public abstract class CalEventLocalServiceBaseImpl
85 implements CalEventLocalService {
86 public CalEvent addCalEvent(CalEvent calEvent) throws SystemException {
87 calEvent.setNew(true);
88
89 return calEventPersistence.update(calEvent, false);
90 }
91
92 public CalEvent createCalEvent(long eventId) {
93 return calEventPersistence.create(eventId);
94 }
95
96 public void deleteCalEvent(long eventId)
97 throws PortalException, SystemException {
98 calEventPersistence.remove(eventId);
99 }
100
101 public void deleteCalEvent(CalEvent calEvent) throws SystemException {
102 calEventPersistence.remove(calEvent);
103 }
104
105 public List<Object> dynamicQuery(DynamicQuery dynamicQuery)
106 throws SystemException {
107 return calEventPersistence.findWithDynamicQuery(dynamicQuery);
108 }
109
110 public List<Object> dynamicQuery(DynamicQuery dynamicQuery, int start,
111 int end) throws SystemException {
112 return calEventPersistence.findWithDynamicQuery(dynamicQuery, start, end);
113 }
114
115 public CalEvent getCalEvent(long eventId)
116 throws PortalException, SystemException {
117 return calEventPersistence.findByPrimaryKey(eventId);
118 }
119
120 public List<CalEvent> getCalEvents(int start, int end)
121 throws SystemException {
122 return calEventPersistence.findAll(start, end);
123 }
124
125 public int getCalEventsCount() throws SystemException {
126 return calEventPersistence.countAll();
127 }
128
129 public CalEvent updateCalEvent(CalEvent calEvent) throws SystemException {
130 calEvent.setNew(false);
131
132 return calEventPersistence.update(calEvent, true);
133 }
134
135 public CalEvent updateCalEvent(CalEvent calEvent, boolean merge)
136 throws SystemException {
137 calEvent.setNew(false);
138
139 return calEventPersistence.update(calEvent, merge);
140 }
141
142 public CalEventLocalService getCalEventLocalService() {
143 return calEventLocalService;
144 }
145
146 public void setCalEventLocalService(
147 CalEventLocalService calEventLocalService) {
148 this.calEventLocalService = calEventLocalService;
149 }
150
151 public CalEventService getCalEventService() {
152 return calEventService;
153 }
154
155 public void setCalEventService(CalEventService calEventService) {
156 this.calEventService = calEventService;
157 }
158
159 public CalEventPersistence getCalEventPersistence() {
160 return calEventPersistence;
161 }
162
163 public void setCalEventPersistence(CalEventPersistence calEventPersistence) {
164 this.calEventPersistence = calEventPersistence;
165 }
166
167 public CalEventFinder getCalEventFinder() {
168 return calEventFinder;
169 }
170
171 public void setCalEventFinder(CalEventFinder calEventFinder) {
172 this.calEventFinder = calEventFinder;
173 }
174
175 public CounterLocalService getCounterLocalService() {
176 return counterLocalService;
177 }
178
179 public void setCounterLocalService(CounterLocalService counterLocalService) {
180 this.counterLocalService = counterLocalService;
181 }
182
183 public CounterService getCounterService() {
184 return counterService;
185 }
186
187 public void setCounterService(CounterService counterService) {
188 this.counterService = counterService;
189 }
190
191 public MailService getMailService() {
192 return mailService;
193 }
194
195 public void setMailService(MailService mailService) {
196 this.mailService = mailService;
197 }
198
199 public CompanyLocalService getCompanyLocalService() {
200 return companyLocalService;
201 }
202
203 public void setCompanyLocalService(CompanyLocalService companyLocalService) {
204 this.companyLocalService = companyLocalService;
205 }
206
207 public CompanyService getCompanyService() {
208 return companyService;
209 }
210
211 public void setCompanyService(CompanyService companyService) {
212 this.companyService = companyService;
213 }
214
215 public CompanyPersistence getCompanyPersistence() {
216 return companyPersistence;
217 }
218
219 public void setCompanyPersistence(CompanyPersistence companyPersistence) {
220 this.companyPersistence = companyPersistence;
221 }
222
223 public GroupLocalService getGroupLocalService() {
224 return groupLocalService;
225 }
226
227 public void setGroupLocalService(GroupLocalService groupLocalService) {
228 this.groupLocalService = groupLocalService;
229 }
230
231 public GroupService getGroupService() {
232 return groupService;
233 }
234
235 public void setGroupService(GroupService groupService) {
236 this.groupService = groupService;
237 }
238
239 public GroupPersistence getGroupPersistence() {
240 return groupPersistence;
241 }
242
243 public void setGroupPersistence(GroupPersistence groupPersistence) {
244 this.groupPersistence = groupPersistence;
245 }
246
247 public GroupFinder getGroupFinder() {
248 return groupFinder;
249 }
250
251 public void setGroupFinder(GroupFinder groupFinder) {
252 this.groupFinder = groupFinder;
253 }
254
255 public PortletPreferencesLocalService getPortletPreferencesLocalService() {
256 return portletPreferencesLocalService;
257 }
258
259 public void setPortletPreferencesLocalService(
260 PortletPreferencesLocalService portletPreferencesLocalService) {
261 this.portletPreferencesLocalService = portletPreferencesLocalService;
262 }
263
264 public PortletPreferencesService getPortletPreferencesService() {
265 return portletPreferencesService;
266 }
267
268 public void setPortletPreferencesService(
269 PortletPreferencesService portletPreferencesService) {
270 this.portletPreferencesService = portletPreferencesService;
271 }
272
273 public PortletPreferencesPersistence getPortletPreferencesPersistence() {
274 return portletPreferencesPersistence;
275 }
276
277 public void setPortletPreferencesPersistence(
278 PortletPreferencesPersistence portletPreferencesPersistence) {
279 this.portletPreferencesPersistence = portletPreferencesPersistence;
280 }
281
282 public PortletPreferencesFinder getPortletPreferencesFinder() {
283 return portletPreferencesFinder;
284 }
285
286 public void setPortletPreferencesFinder(
287 PortletPreferencesFinder portletPreferencesFinder) {
288 this.portletPreferencesFinder = portletPreferencesFinder;
289 }
290
291 public ResourceLocalService getResourceLocalService() {
292 return resourceLocalService;
293 }
294
295 public void setResourceLocalService(
296 ResourceLocalService resourceLocalService) {
297 this.resourceLocalService = resourceLocalService;
298 }
299
300 public ResourceService getResourceService() {
301 return resourceService;
302 }
303
304 public void setResourceService(ResourceService resourceService) {
305 this.resourceService = resourceService;
306 }
307
308 public ResourcePersistence getResourcePersistence() {
309 return resourcePersistence;
310 }
311
312 public void setResourcePersistence(ResourcePersistence resourcePersistence) {
313 this.resourcePersistence = resourcePersistence;
314 }
315
316 public ResourceFinder getResourceFinder() {
317 return resourceFinder;
318 }
319
320 public void setResourceFinder(ResourceFinder resourceFinder) {
321 this.resourceFinder = resourceFinder;
322 }
323
324 public UserLocalService getUserLocalService() {
325 return userLocalService;
326 }
327
328 public void setUserLocalService(UserLocalService userLocalService) {
329 this.userLocalService = userLocalService;
330 }
331
332 public UserService getUserService() {
333 return userService;
334 }
335
336 public void setUserService(UserService userService) {
337 this.userService = userService;
338 }
339
340 public UserPersistence getUserPersistence() {
341 return userPersistence;
342 }
343
344 public void setUserPersistence(UserPersistence userPersistence) {
345 this.userPersistence = userPersistence;
346 }
347
348 public UserFinder getUserFinder() {
349 return userFinder;
350 }
351
352 public void setUserFinder(UserFinder userFinder) {
353 this.userFinder = userFinder;
354 }
355
356 public ExpandoValueLocalService getExpandoValueLocalService() {
357 return expandoValueLocalService;
358 }
359
360 public void setExpandoValueLocalService(
361 ExpandoValueLocalService expandoValueLocalService) {
362 this.expandoValueLocalService = expandoValueLocalService;
363 }
364
365 public ExpandoValueService getExpandoValueService() {
366 return expandoValueService;
367 }
368
369 public void setExpandoValueService(ExpandoValueService expandoValueService) {
370 this.expandoValueService = expandoValueService;
371 }
372
373 public ExpandoValuePersistence getExpandoValuePersistence() {
374 return expandoValuePersistence;
375 }
376
377 public void setExpandoValuePersistence(
378 ExpandoValuePersistence expandoValuePersistence) {
379 this.expandoValuePersistence = expandoValuePersistence;
380 }
381
382 public SocialActivityLocalService getSocialActivityLocalService() {
383 return socialActivityLocalService;
384 }
385
386 public void setSocialActivityLocalService(
387 SocialActivityLocalService socialActivityLocalService) {
388 this.socialActivityLocalService = socialActivityLocalService;
389 }
390
391 public SocialActivityPersistence getSocialActivityPersistence() {
392 return socialActivityPersistence;
393 }
394
395 public void setSocialActivityPersistence(
396 SocialActivityPersistence socialActivityPersistence) {
397 this.socialActivityPersistence = socialActivityPersistence;
398 }
399
400 public SocialActivityFinder getSocialActivityFinder() {
401 return socialActivityFinder;
402 }
403
404 public void setSocialActivityFinder(
405 SocialActivityFinder socialActivityFinder) {
406 this.socialActivityFinder = socialActivityFinder;
407 }
408
409 public TagsAssetLocalService getTagsAssetLocalService() {
410 return tagsAssetLocalService;
411 }
412
413 public void setTagsAssetLocalService(
414 TagsAssetLocalService tagsAssetLocalService) {
415 this.tagsAssetLocalService = tagsAssetLocalService;
416 }
417
418 public TagsAssetService getTagsAssetService() {
419 return tagsAssetService;
420 }
421
422 public void setTagsAssetService(TagsAssetService tagsAssetService) {
423 this.tagsAssetService = tagsAssetService;
424 }
425
426 public TagsAssetPersistence getTagsAssetPersistence() {
427 return tagsAssetPersistence;
428 }
429
430 public void setTagsAssetPersistence(
431 TagsAssetPersistence tagsAssetPersistence) {
432 this.tagsAssetPersistence = tagsAssetPersistence;
433 }
434
435 public TagsAssetFinder getTagsAssetFinder() {
436 return tagsAssetFinder;
437 }
438
439 public void setTagsAssetFinder(TagsAssetFinder tagsAssetFinder) {
440 this.tagsAssetFinder = tagsAssetFinder;
441 }
442
443 public TagsEntryLocalService getTagsEntryLocalService() {
444 return tagsEntryLocalService;
445 }
446
447 public void setTagsEntryLocalService(
448 TagsEntryLocalService tagsEntryLocalService) {
449 this.tagsEntryLocalService = tagsEntryLocalService;
450 }
451
452 public TagsEntryService getTagsEntryService() {
453 return tagsEntryService;
454 }
455
456 public void setTagsEntryService(TagsEntryService tagsEntryService) {
457 this.tagsEntryService = tagsEntryService;
458 }
459
460 public TagsEntryPersistence getTagsEntryPersistence() {
461 return tagsEntryPersistence;
462 }
463
464 public void setTagsEntryPersistence(
465 TagsEntryPersistence tagsEntryPersistence) {
466 this.tagsEntryPersistence = tagsEntryPersistence;
467 }
468
469 public TagsEntryFinder getTagsEntryFinder() {
470 return tagsEntryFinder;
471 }
472
473 public void setTagsEntryFinder(TagsEntryFinder tagsEntryFinder) {
474 this.tagsEntryFinder = tagsEntryFinder;
475 }
476
477 protected void runSQL(String sql) throws SystemException {
478 try {
479 DB db = DBFactoryUtil.getDB();
480
481 db.runSQL(sql);
482 }
483 catch (Exception e) {
484 throw new SystemException(e);
485 }
486 }
487
488 @BeanReference(name = "com.liferay.portlet.calendar.service.CalEventLocalService")
489 protected CalEventLocalService calEventLocalService;
490 @BeanReference(name = "com.liferay.portlet.calendar.service.CalEventService")
491 protected CalEventService calEventService;
492 @BeanReference(name = "com.liferay.portlet.calendar.service.persistence.CalEventPersistence")
493 protected CalEventPersistence calEventPersistence;
494 @BeanReference(name = "com.liferay.portlet.calendar.service.persistence.CalEventFinder")
495 protected CalEventFinder calEventFinder;
496 @BeanReference(name = "com.liferay.counter.service.CounterLocalService")
497 protected CounterLocalService counterLocalService;
498 @BeanReference(name = "com.liferay.counter.service.CounterService")
499 protected CounterService counterService;
500 @BeanReference(name = "com.liferay.mail.service.MailService")
501 protected MailService mailService;
502 @BeanReference(name = "com.liferay.portal.service.CompanyLocalService")
503 protected CompanyLocalService companyLocalService;
504 @BeanReference(name = "com.liferay.portal.service.CompanyService")
505 protected CompanyService companyService;
506 @BeanReference(name = "com.liferay.portal.service.persistence.CompanyPersistence")
507 protected CompanyPersistence companyPersistence;
508 @BeanReference(name = "com.liferay.portal.service.GroupLocalService")
509 protected GroupLocalService groupLocalService;
510 @BeanReference(name = "com.liferay.portal.service.GroupService")
511 protected GroupService groupService;
512 @BeanReference(name = "com.liferay.portal.service.persistence.GroupPersistence")
513 protected GroupPersistence groupPersistence;
514 @BeanReference(name = "com.liferay.portal.service.persistence.GroupFinder")
515 protected GroupFinder groupFinder;
516 @BeanReference(name = "com.liferay.portal.service.PortletPreferencesLocalService")
517 protected PortletPreferencesLocalService portletPreferencesLocalService;
518 @BeanReference(name = "com.liferay.portal.service.PortletPreferencesService")
519 protected PortletPreferencesService portletPreferencesService;
520 @BeanReference(name = "com.liferay.portal.service.persistence.PortletPreferencesPersistence")
521 protected PortletPreferencesPersistence portletPreferencesPersistence;
522 @BeanReference(name = "com.liferay.portal.service.persistence.PortletPreferencesFinder")
523 protected PortletPreferencesFinder portletPreferencesFinder;
524 @BeanReference(name = "com.liferay.portal.service.ResourceLocalService")
525 protected ResourceLocalService resourceLocalService;
526 @BeanReference(name = "com.liferay.portal.service.ResourceService")
527 protected ResourceService resourceService;
528 @BeanReference(name = "com.liferay.portal.service.persistence.ResourcePersistence")
529 protected ResourcePersistence resourcePersistence;
530 @BeanReference(name = "com.liferay.portal.service.persistence.ResourceFinder")
531 protected ResourceFinder resourceFinder;
532 @BeanReference(name = "com.liferay.portal.service.UserLocalService")
533 protected UserLocalService userLocalService;
534 @BeanReference(name = "com.liferay.portal.service.UserService")
535 protected UserService userService;
536 @BeanReference(name = "com.liferay.portal.service.persistence.UserPersistence")
537 protected UserPersistence userPersistence;
538 @BeanReference(name = "com.liferay.portal.service.persistence.UserFinder")
539 protected UserFinder userFinder;
540 @BeanReference(name = "com.liferay.portlet.expando.service.ExpandoValueLocalService")
541 protected ExpandoValueLocalService expandoValueLocalService;
542 @BeanReference(name = "com.liferay.portlet.expando.service.ExpandoValueService")
543 protected ExpandoValueService expandoValueService;
544 @BeanReference(name = "com.liferay.portlet.expando.service.persistence.ExpandoValuePersistence")
545 protected ExpandoValuePersistence expandoValuePersistence;
546 @BeanReference(name = "com.liferay.portlet.social.service.SocialActivityLocalService")
547 protected SocialActivityLocalService socialActivityLocalService;
548 @BeanReference(name = "com.liferay.portlet.social.service.persistence.SocialActivityPersistence")
549 protected SocialActivityPersistence socialActivityPersistence;
550 @BeanReference(name = "com.liferay.portlet.social.service.persistence.SocialActivityFinder")
551 protected SocialActivityFinder socialActivityFinder;
552 @BeanReference(name = "com.liferay.portlet.tags.service.TagsAssetLocalService")
553 protected TagsAssetLocalService tagsAssetLocalService;
554 @BeanReference(name = "com.liferay.portlet.tags.service.TagsAssetService")
555 protected TagsAssetService tagsAssetService;
556 @BeanReference(name = "com.liferay.portlet.tags.service.persistence.TagsAssetPersistence")
557 protected TagsAssetPersistence tagsAssetPersistence;
558 @BeanReference(name = "com.liferay.portlet.tags.service.persistence.TagsAssetFinder")
559 protected TagsAssetFinder tagsAssetFinder;
560 @BeanReference(name = "com.liferay.portlet.tags.service.TagsEntryLocalService")
561 protected TagsEntryLocalService tagsEntryLocalService;
562 @BeanReference(name = "com.liferay.portlet.tags.service.TagsEntryService")
563 protected TagsEntryService tagsEntryService;
564 @BeanReference(name = "com.liferay.portlet.tags.service.persistence.TagsEntryPersistence")
565 protected TagsEntryPersistence tagsEntryPersistence;
566 @BeanReference(name = "com.liferay.portlet.tags.service.persistence.TagsEntryFinder")
567 protected TagsEntryFinder tagsEntryFinder;
568 }