001
014
015 package com.liferay.portlet.expando.service.base;
016
017 import com.liferay.counter.service.CounterLocalService;
018
019 import com.liferay.portal.kernel.bean.BeanReference;
020 import com.liferay.portal.kernel.bean.IdentifiableBean;
021 import com.liferay.portal.kernel.dao.jdbc.SqlUpdate;
022 import com.liferay.portal.kernel.dao.jdbc.SqlUpdateFactoryUtil;
023 import com.liferay.portal.kernel.exception.SystemException;
024 import com.liferay.portal.service.BaseServiceImpl;
025 import com.liferay.portal.service.ResourceLocalService;
026 import com.liferay.portal.service.UserLocalService;
027 import com.liferay.portal.service.UserService;
028 import com.liferay.portal.service.persistence.UserFinder;
029 import com.liferay.portal.service.persistence.UserPersistence;
030
031 import com.liferay.portlet.expando.model.ExpandoValue;
032 import com.liferay.portlet.expando.service.ExpandoColumnLocalService;
033 import com.liferay.portlet.expando.service.ExpandoColumnService;
034 import com.liferay.portlet.expando.service.ExpandoRowLocalService;
035 import com.liferay.portlet.expando.service.ExpandoTableLocalService;
036 import com.liferay.portlet.expando.service.ExpandoValueLocalService;
037 import com.liferay.portlet.expando.service.ExpandoValueService;
038 import com.liferay.portlet.expando.service.persistence.ExpandoColumnPersistence;
039 import com.liferay.portlet.expando.service.persistence.ExpandoRowPersistence;
040 import com.liferay.portlet.expando.service.persistence.ExpandoTablePersistence;
041 import com.liferay.portlet.expando.service.persistence.ExpandoValuePersistence;
042
043 import javax.sql.DataSource;
044
045
057 public abstract class ExpandoValueServiceBaseImpl extends BaseServiceImpl
058 implements ExpandoValueService, IdentifiableBean {
059
064
065
070 public ExpandoColumnLocalService getExpandoColumnLocalService() {
071 return expandoColumnLocalService;
072 }
073
074
079 public void setExpandoColumnLocalService(
080 ExpandoColumnLocalService expandoColumnLocalService) {
081 this.expandoColumnLocalService = expandoColumnLocalService;
082 }
083
084
089 public ExpandoColumnService getExpandoColumnService() {
090 return expandoColumnService;
091 }
092
093
098 public void setExpandoColumnService(
099 ExpandoColumnService expandoColumnService) {
100 this.expandoColumnService = expandoColumnService;
101 }
102
103
108 public ExpandoColumnPersistence getExpandoColumnPersistence() {
109 return expandoColumnPersistence;
110 }
111
112
117 public void setExpandoColumnPersistence(
118 ExpandoColumnPersistence expandoColumnPersistence) {
119 this.expandoColumnPersistence = expandoColumnPersistence;
120 }
121
122
127 public ExpandoRowLocalService getExpandoRowLocalService() {
128 return expandoRowLocalService;
129 }
130
131
136 public void setExpandoRowLocalService(
137 ExpandoRowLocalService expandoRowLocalService) {
138 this.expandoRowLocalService = expandoRowLocalService;
139 }
140
141
146 public ExpandoRowPersistence getExpandoRowPersistence() {
147 return expandoRowPersistence;
148 }
149
150
155 public void setExpandoRowPersistence(
156 ExpandoRowPersistence expandoRowPersistence) {
157 this.expandoRowPersistence = expandoRowPersistence;
158 }
159
160
165 public ExpandoTableLocalService getExpandoTableLocalService() {
166 return expandoTableLocalService;
167 }
168
169
174 public void setExpandoTableLocalService(
175 ExpandoTableLocalService expandoTableLocalService) {
176 this.expandoTableLocalService = expandoTableLocalService;
177 }
178
179
184 public ExpandoTablePersistence getExpandoTablePersistence() {
185 return expandoTablePersistence;
186 }
187
188
193 public void setExpandoTablePersistence(
194 ExpandoTablePersistence expandoTablePersistence) {
195 this.expandoTablePersistence = expandoTablePersistence;
196 }
197
198
203 public ExpandoValueLocalService getExpandoValueLocalService() {
204 return expandoValueLocalService;
205 }
206
207
212 public void setExpandoValueLocalService(
213 ExpandoValueLocalService expandoValueLocalService) {
214 this.expandoValueLocalService = expandoValueLocalService;
215 }
216
217
222 public ExpandoValueService getExpandoValueService() {
223 return expandoValueService;
224 }
225
226
231 public void setExpandoValueService(ExpandoValueService expandoValueService) {
232 this.expandoValueService = expandoValueService;
233 }
234
235
240 public ExpandoValuePersistence getExpandoValuePersistence() {
241 return expandoValuePersistence;
242 }
243
244
249 public void setExpandoValuePersistence(
250 ExpandoValuePersistence expandoValuePersistence) {
251 this.expandoValuePersistence = expandoValuePersistence;
252 }
253
254
259 public CounterLocalService getCounterLocalService() {
260 return counterLocalService;
261 }
262
263
268 public void setCounterLocalService(CounterLocalService counterLocalService) {
269 this.counterLocalService = counterLocalService;
270 }
271
272
277 public ResourceLocalService getResourceLocalService() {
278 return resourceLocalService;
279 }
280
281
286 public void setResourceLocalService(
287 ResourceLocalService resourceLocalService) {
288 this.resourceLocalService = resourceLocalService;
289 }
290
291
296 public UserLocalService getUserLocalService() {
297 return userLocalService;
298 }
299
300
305 public void setUserLocalService(UserLocalService userLocalService) {
306 this.userLocalService = userLocalService;
307 }
308
309
314 public UserService getUserService() {
315 return userService;
316 }
317
318
323 public void setUserService(UserService userService) {
324 this.userService = userService;
325 }
326
327
332 public UserPersistence getUserPersistence() {
333 return userPersistence;
334 }
335
336
341 public void setUserPersistence(UserPersistence userPersistence) {
342 this.userPersistence = userPersistence;
343 }
344
345
350 public UserFinder getUserFinder() {
351 return userFinder;
352 }
353
354
359 public void setUserFinder(UserFinder userFinder) {
360 this.userFinder = userFinder;
361 }
362
363 public void afterPropertiesSet() {
364 }
365
366 public void destroy() {
367 }
368
369
374 public String getBeanIdentifier() {
375 return _beanIdentifier;
376 }
377
378
383 public void setBeanIdentifier(String beanIdentifier) {
384 _beanIdentifier = beanIdentifier;
385 }
386
387 protected Class<?> getModelClass() {
388 return ExpandoValue.class;
389 }
390
391 protected String getModelClassName() {
392 return ExpandoValue.class.getName();
393 }
394
395
400 protected void runSQL(String sql) throws SystemException {
401 try {
402 DataSource dataSource = expandoValuePersistence.getDataSource();
403
404 SqlUpdate sqlUpdate = SqlUpdateFactoryUtil.getSqlUpdate(dataSource,
405 sql, new int[0]);
406
407 sqlUpdate.update();
408 }
409 catch (Exception e) {
410 throw new SystemException(e);
411 }
412 }
413
414 @BeanReference(type = ExpandoColumnLocalService.class)
415 protected ExpandoColumnLocalService expandoColumnLocalService;
416 @BeanReference(type = ExpandoColumnService.class)
417 protected ExpandoColumnService expandoColumnService;
418 @BeanReference(type = ExpandoColumnPersistence.class)
419 protected ExpandoColumnPersistence expandoColumnPersistence;
420 @BeanReference(type = ExpandoRowLocalService.class)
421 protected ExpandoRowLocalService expandoRowLocalService;
422 @BeanReference(type = ExpandoRowPersistence.class)
423 protected ExpandoRowPersistence expandoRowPersistence;
424 @BeanReference(type = ExpandoTableLocalService.class)
425 protected ExpandoTableLocalService expandoTableLocalService;
426 @BeanReference(type = ExpandoTablePersistence.class)
427 protected ExpandoTablePersistence expandoTablePersistence;
428 @BeanReference(type = ExpandoValueLocalService.class)
429 protected ExpandoValueLocalService expandoValueLocalService;
430 @BeanReference(type = ExpandoValueService.class)
431 protected ExpandoValueService expandoValueService;
432 @BeanReference(type = ExpandoValuePersistence.class)
433 protected ExpandoValuePersistence expandoValuePersistence;
434 @BeanReference(type = CounterLocalService.class)
435 protected CounterLocalService counterLocalService;
436 @BeanReference(type = ResourceLocalService.class)
437 protected ResourceLocalService resourceLocalService;
438 @BeanReference(type = UserLocalService.class)
439 protected UserLocalService userLocalService;
440 @BeanReference(type = UserService.class)
441 protected UserService userService;
442 @BeanReference(type = UserPersistence.class)
443 protected UserPersistence userPersistence;
444 @BeanReference(type = UserFinder.class)
445 protected UserFinder userFinder;
446 private String _beanIdentifier;
447 }