001    /**
002     * Copyright (c) 2000-present Liferay, Inc. All rights reserved.
003     *
004     * This library is free software; you can redistribute it and/or modify it under
005     * the terms of the GNU Lesser General Public License as published by the Free
006     * Software Foundation; either version 2.1 of the License, or (at your option)
007     * any later version.
008     *
009     * This library is distributed in the hope that it will be useful, but WITHOUT
010     * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
011     * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
012     * details.
013     */
014    
015    package com.liferay.portal.service.base;
016    
017    import com.liferay.portal.kernel.bean.BeanReference;
018    import com.liferay.portal.kernel.dao.db.DB;
019    import com.liferay.portal.kernel.dao.db.DBFactoryUtil;
020    import com.liferay.portal.kernel.dao.jdbc.SqlUpdate;
021    import com.liferay.portal.kernel.dao.jdbc.SqlUpdateFactoryUtil;
022    import com.liferay.portal.kernel.exception.SystemException;
023    import com.liferay.portal.kernel.module.framework.service.IdentifiableOSGiService;
024    import com.liferay.portal.model.LayoutSetBranch;
025    import com.liferay.portal.service.BaseServiceImpl;
026    import com.liferay.portal.service.LayoutSetBranchService;
027    import com.liferay.portal.service.persistence.ImagePersistence;
028    import com.liferay.portal.service.persistence.LayoutBranchPersistence;
029    import com.liferay.portal.service.persistence.LayoutFinder;
030    import com.liferay.portal.service.persistence.LayoutPersistence;
031    import com.liferay.portal.service.persistence.LayoutRevisionPersistence;
032    import com.liferay.portal.service.persistence.LayoutSetBranchPersistence;
033    import com.liferay.portal.service.persistence.LayoutSetPersistence;
034    import com.liferay.portal.service.persistence.UserFinder;
035    import com.liferay.portal.service.persistence.UserPersistence;
036    import com.liferay.portal.util.PortalUtil;
037    
038    import javax.sql.DataSource;
039    
040    /**
041     * Provides the base implementation for the layout set branch remote service.
042     *
043     * <p>
044     * This implementation exists only as a container for the default service methods generated by ServiceBuilder. All custom service methods should be put in {@link com.liferay.portal.service.impl.LayoutSetBranchServiceImpl}.
045     * </p>
046     *
047     * @author Brian Wing Shun Chan
048     * @see com.liferay.portal.service.impl.LayoutSetBranchServiceImpl
049     * @see com.liferay.portal.service.LayoutSetBranchServiceUtil
050     * @generated
051     */
052    public abstract class LayoutSetBranchServiceBaseImpl extends BaseServiceImpl
053            implements LayoutSetBranchService, IdentifiableOSGiService {
054            /*
055             * NOTE FOR DEVELOPERS:
056             *
057             * Never modify or reference this class directly. Always use {@link com.liferay.portal.service.LayoutSetBranchServiceUtil} to access the layout set branch remote service.
058             */
059    
060            /**
061             * Returns the layout set branch local service.
062             *
063             * @return the layout set branch local service
064             */
065            public com.liferay.portal.service.LayoutSetBranchLocalService getLayoutSetBranchLocalService() {
066                    return layoutSetBranchLocalService;
067            }
068    
069            /**
070             * Sets the layout set branch local service.
071             *
072             * @param layoutSetBranchLocalService the layout set branch local service
073             */
074            public void setLayoutSetBranchLocalService(
075                    com.liferay.portal.service.LayoutSetBranchLocalService layoutSetBranchLocalService) {
076                    this.layoutSetBranchLocalService = layoutSetBranchLocalService;
077            }
078    
079            /**
080             * Returns the layout set branch remote service.
081             *
082             * @return the layout set branch remote service
083             */
084            public LayoutSetBranchService getLayoutSetBranchService() {
085                    return layoutSetBranchService;
086            }
087    
088            /**
089             * Sets the layout set branch remote service.
090             *
091             * @param layoutSetBranchService the layout set branch remote service
092             */
093            public void setLayoutSetBranchService(
094                    LayoutSetBranchService layoutSetBranchService) {
095                    this.layoutSetBranchService = layoutSetBranchService;
096            }
097    
098            /**
099             * Returns the layout set branch persistence.
100             *
101             * @return the layout set branch persistence
102             */
103            public LayoutSetBranchPersistence getLayoutSetBranchPersistence() {
104                    return layoutSetBranchPersistence;
105            }
106    
107            /**
108             * Sets the layout set branch persistence.
109             *
110             * @param layoutSetBranchPersistence the layout set branch persistence
111             */
112            public void setLayoutSetBranchPersistence(
113                    LayoutSetBranchPersistence layoutSetBranchPersistence) {
114                    this.layoutSetBranchPersistence = layoutSetBranchPersistence;
115            }
116    
117            /**
118             * Returns the counter local service.
119             *
120             * @return the counter local service
121             */
122            public com.liferay.counter.service.CounterLocalService getCounterLocalService() {
123                    return counterLocalService;
124            }
125    
126            /**
127             * Sets the counter local service.
128             *
129             * @param counterLocalService the counter local service
130             */
131            public void setCounterLocalService(
132                    com.liferay.counter.service.CounterLocalService counterLocalService) {
133                    this.counterLocalService = counterLocalService;
134            }
135    
136            /**
137             * Returns the image local service.
138             *
139             * @return the image local service
140             */
141            public com.liferay.portal.service.ImageLocalService getImageLocalService() {
142                    return imageLocalService;
143            }
144    
145            /**
146             * Sets the image local service.
147             *
148             * @param imageLocalService the image local service
149             */
150            public void setImageLocalService(
151                    com.liferay.portal.service.ImageLocalService imageLocalService) {
152                    this.imageLocalService = imageLocalService;
153            }
154    
155            /**
156             * Returns the image remote service.
157             *
158             * @return the image remote service
159             */
160            public com.liferay.portal.service.ImageService getImageService() {
161                    return imageService;
162            }
163    
164            /**
165             * Sets the image remote service.
166             *
167             * @param imageService the image remote service
168             */
169            public void setImageService(
170                    com.liferay.portal.service.ImageService imageService) {
171                    this.imageService = imageService;
172            }
173    
174            /**
175             * Returns the image persistence.
176             *
177             * @return the image persistence
178             */
179            public ImagePersistence getImagePersistence() {
180                    return imagePersistence;
181            }
182    
183            /**
184             * Sets the image persistence.
185             *
186             * @param imagePersistence the image persistence
187             */
188            public void setImagePersistence(ImagePersistence imagePersistence) {
189                    this.imagePersistence = imagePersistence;
190            }
191    
192            /**
193             * Returns the layout local service.
194             *
195             * @return the layout local service
196             */
197            public com.liferay.portal.service.LayoutLocalService getLayoutLocalService() {
198                    return layoutLocalService;
199            }
200    
201            /**
202             * Sets the layout local service.
203             *
204             * @param layoutLocalService the layout local service
205             */
206            public void setLayoutLocalService(
207                    com.liferay.portal.service.LayoutLocalService layoutLocalService) {
208                    this.layoutLocalService = layoutLocalService;
209            }
210    
211            /**
212             * Returns the layout remote service.
213             *
214             * @return the layout remote service
215             */
216            public com.liferay.portal.service.LayoutService getLayoutService() {
217                    return layoutService;
218            }
219    
220            /**
221             * Sets the layout remote service.
222             *
223             * @param layoutService the layout remote service
224             */
225            public void setLayoutService(
226                    com.liferay.portal.service.LayoutService layoutService) {
227                    this.layoutService = layoutService;
228            }
229    
230            /**
231             * Returns the layout persistence.
232             *
233             * @return the layout persistence
234             */
235            public LayoutPersistence getLayoutPersistence() {
236                    return layoutPersistence;
237            }
238    
239            /**
240             * Sets the layout persistence.
241             *
242             * @param layoutPersistence the layout persistence
243             */
244            public void setLayoutPersistence(LayoutPersistence layoutPersistence) {
245                    this.layoutPersistence = layoutPersistence;
246            }
247    
248            /**
249             * Returns the layout finder.
250             *
251             * @return the layout finder
252             */
253            public LayoutFinder getLayoutFinder() {
254                    return layoutFinder;
255            }
256    
257            /**
258             * Sets the layout finder.
259             *
260             * @param layoutFinder the layout finder
261             */
262            public void setLayoutFinder(LayoutFinder layoutFinder) {
263                    this.layoutFinder = layoutFinder;
264            }
265    
266            /**
267             * Returns the layout branch local service.
268             *
269             * @return the layout branch local service
270             */
271            public com.liferay.portal.service.LayoutBranchLocalService getLayoutBranchLocalService() {
272                    return layoutBranchLocalService;
273            }
274    
275            /**
276             * Sets the layout branch local service.
277             *
278             * @param layoutBranchLocalService the layout branch local service
279             */
280            public void setLayoutBranchLocalService(
281                    com.liferay.portal.service.LayoutBranchLocalService layoutBranchLocalService) {
282                    this.layoutBranchLocalService = layoutBranchLocalService;
283            }
284    
285            /**
286             * Returns the layout branch remote service.
287             *
288             * @return the layout branch remote service
289             */
290            public com.liferay.portal.service.LayoutBranchService getLayoutBranchService() {
291                    return layoutBranchService;
292            }
293    
294            /**
295             * Sets the layout branch remote service.
296             *
297             * @param layoutBranchService the layout branch remote service
298             */
299            public void setLayoutBranchService(
300                    com.liferay.portal.service.LayoutBranchService layoutBranchService) {
301                    this.layoutBranchService = layoutBranchService;
302            }
303    
304            /**
305             * Returns the layout branch persistence.
306             *
307             * @return the layout branch persistence
308             */
309            public LayoutBranchPersistence getLayoutBranchPersistence() {
310                    return layoutBranchPersistence;
311            }
312    
313            /**
314             * Sets the layout branch persistence.
315             *
316             * @param layoutBranchPersistence the layout branch persistence
317             */
318            public void setLayoutBranchPersistence(
319                    LayoutBranchPersistence layoutBranchPersistence) {
320                    this.layoutBranchPersistence = layoutBranchPersistence;
321            }
322    
323            /**
324             * Returns the layout revision local service.
325             *
326             * @return the layout revision local service
327             */
328            public com.liferay.portal.service.LayoutRevisionLocalService getLayoutRevisionLocalService() {
329                    return layoutRevisionLocalService;
330            }
331    
332            /**
333             * Sets the layout revision local service.
334             *
335             * @param layoutRevisionLocalService the layout revision local service
336             */
337            public void setLayoutRevisionLocalService(
338                    com.liferay.portal.service.LayoutRevisionLocalService layoutRevisionLocalService) {
339                    this.layoutRevisionLocalService = layoutRevisionLocalService;
340            }
341    
342            /**
343             * Returns the layout revision remote service.
344             *
345             * @return the layout revision remote service
346             */
347            public com.liferay.portal.service.LayoutRevisionService getLayoutRevisionService() {
348                    return layoutRevisionService;
349            }
350    
351            /**
352             * Sets the layout revision remote service.
353             *
354             * @param layoutRevisionService the layout revision remote service
355             */
356            public void setLayoutRevisionService(
357                    com.liferay.portal.service.LayoutRevisionService layoutRevisionService) {
358                    this.layoutRevisionService = layoutRevisionService;
359            }
360    
361            /**
362             * Returns the layout revision persistence.
363             *
364             * @return the layout revision persistence
365             */
366            public LayoutRevisionPersistence getLayoutRevisionPersistence() {
367                    return layoutRevisionPersistence;
368            }
369    
370            /**
371             * Sets the layout revision persistence.
372             *
373             * @param layoutRevisionPersistence the layout revision persistence
374             */
375            public void setLayoutRevisionPersistence(
376                    LayoutRevisionPersistence layoutRevisionPersistence) {
377                    this.layoutRevisionPersistence = layoutRevisionPersistence;
378            }
379    
380            /**
381             * Returns the layout set local service.
382             *
383             * @return the layout set local service
384             */
385            public com.liferay.portal.service.LayoutSetLocalService getLayoutSetLocalService() {
386                    return layoutSetLocalService;
387            }
388    
389            /**
390             * Sets the layout set local service.
391             *
392             * @param layoutSetLocalService the layout set local service
393             */
394            public void setLayoutSetLocalService(
395                    com.liferay.portal.service.LayoutSetLocalService layoutSetLocalService) {
396                    this.layoutSetLocalService = layoutSetLocalService;
397            }
398    
399            /**
400             * Returns the layout set remote service.
401             *
402             * @return the layout set remote service
403             */
404            public com.liferay.portal.service.LayoutSetService getLayoutSetService() {
405                    return layoutSetService;
406            }
407    
408            /**
409             * Sets the layout set remote service.
410             *
411             * @param layoutSetService the layout set remote service
412             */
413            public void setLayoutSetService(
414                    com.liferay.portal.service.LayoutSetService layoutSetService) {
415                    this.layoutSetService = layoutSetService;
416            }
417    
418            /**
419             * Returns the layout set persistence.
420             *
421             * @return the layout set persistence
422             */
423            public LayoutSetPersistence getLayoutSetPersistence() {
424                    return layoutSetPersistence;
425            }
426    
427            /**
428             * Sets the layout set persistence.
429             *
430             * @param layoutSetPersistence the layout set persistence
431             */
432            public void setLayoutSetPersistence(
433                    LayoutSetPersistence layoutSetPersistence) {
434                    this.layoutSetPersistence = layoutSetPersistence;
435            }
436    
437            /**
438             * Returns the resource local service.
439             *
440             * @return the resource local service
441             */
442            public com.liferay.portal.service.ResourceLocalService getResourceLocalService() {
443                    return resourceLocalService;
444            }
445    
446            /**
447             * Sets the resource local service.
448             *
449             * @param resourceLocalService the resource local service
450             */
451            public void setResourceLocalService(
452                    com.liferay.portal.service.ResourceLocalService resourceLocalService) {
453                    this.resourceLocalService = resourceLocalService;
454            }
455    
456            /**
457             * Returns the user local service.
458             *
459             * @return the user local service
460             */
461            public com.liferay.portal.service.UserLocalService getUserLocalService() {
462                    return userLocalService;
463            }
464    
465            /**
466             * Sets the user local service.
467             *
468             * @param userLocalService the user local service
469             */
470            public void setUserLocalService(
471                    com.liferay.portal.service.UserLocalService userLocalService) {
472                    this.userLocalService = userLocalService;
473            }
474    
475            /**
476             * Returns the user remote service.
477             *
478             * @return the user remote service
479             */
480            public com.liferay.portal.service.UserService getUserService() {
481                    return userService;
482            }
483    
484            /**
485             * Sets the user remote service.
486             *
487             * @param userService the user remote service
488             */
489            public void setUserService(
490                    com.liferay.portal.service.UserService userService) {
491                    this.userService = userService;
492            }
493    
494            /**
495             * Returns the user persistence.
496             *
497             * @return the user persistence
498             */
499            public UserPersistence getUserPersistence() {
500                    return userPersistence;
501            }
502    
503            /**
504             * Sets the user persistence.
505             *
506             * @param userPersistence the user persistence
507             */
508            public void setUserPersistence(UserPersistence userPersistence) {
509                    this.userPersistence = userPersistence;
510            }
511    
512            /**
513             * Returns the user finder.
514             *
515             * @return the user finder
516             */
517            public UserFinder getUserFinder() {
518                    return userFinder;
519            }
520    
521            /**
522             * Sets the user finder.
523             *
524             * @param userFinder the user finder
525             */
526            public void setUserFinder(UserFinder userFinder) {
527                    this.userFinder = userFinder;
528            }
529    
530            public void afterPropertiesSet() {
531            }
532    
533            public void destroy() {
534            }
535    
536            /**
537             * Returns the OSGi service identifier.
538             *
539             * @return the OSGi service identifier
540             */
541            @Override
542            public String getOSGiServiceIdentifier() {
543                    return LayoutSetBranchService.class.getName();
544            }
545    
546            protected Class<?> getModelClass() {
547                    return LayoutSetBranch.class;
548            }
549    
550            protected String getModelClassName() {
551                    return LayoutSetBranch.class.getName();
552            }
553    
554            /**
555             * Performs a SQL query.
556             *
557             * @param sql the sql query
558             */
559            protected void runSQL(String sql) {
560                    try {
561                            DataSource dataSource = layoutSetBranchPersistence.getDataSource();
562    
563                            DB db = DBFactoryUtil.getDB();
564    
565                            sql = db.buildSQL(sql);
566                            sql = PortalUtil.transformSQL(sql);
567    
568                            SqlUpdate sqlUpdate = SqlUpdateFactoryUtil.getSqlUpdate(dataSource,
569                                            sql, new int[0]);
570    
571                            sqlUpdate.update();
572                    }
573                    catch (Exception e) {
574                            throw new SystemException(e);
575                    }
576            }
577    
578            @BeanReference(type = com.liferay.portal.service.LayoutSetBranchLocalService.class)
579            protected com.liferay.portal.service.LayoutSetBranchLocalService layoutSetBranchLocalService;
580            @BeanReference(type = com.liferay.portal.service.LayoutSetBranchService.class)
581            protected LayoutSetBranchService layoutSetBranchService;
582            @BeanReference(type = LayoutSetBranchPersistence.class)
583            protected LayoutSetBranchPersistence layoutSetBranchPersistence;
584            @BeanReference(type = com.liferay.counter.service.CounterLocalService.class)
585            protected com.liferay.counter.service.CounterLocalService counterLocalService;
586            @BeanReference(type = com.liferay.portal.service.ImageLocalService.class)
587            protected com.liferay.portal.service.ImageLocalService imageLocalService;
588            @BeanReference(type = com.liferay.portal.service.ImageService.class)
589            protected com.liferay.portal.service.ImageService imageService;
590            @BeanReference(type = ImagePersistence.class)
591            protected ImagePersistence imagePersistence;
592            @BeanReference(type = com.liferay.portal.service.LayoutLocalService.class)
593            protected com.liferay.portal.service.LayoutLocalService layoutLocalService;
594            @BeanReference(type = com.liferay.portal.service.LayoutService.class)
595            protected com.liferay.portal.service.LayoutService layoutService;
596            @BeanReference(type = LayoutPersistence.class)
597            protected LayoutPersistence layoutPersistence;
598            @BeanReference(type = LayoutFinder.class)
599            protected LayoutFinder layoutFinder;
600            @BeanReference(type = com.liferay.portal.service.LayoutBranchLocalService.class)
601            protected com.liferay.portal.service.LayoutBranchLocalService layoutBranchLocalService;
602            @BeanReference(type = com.liferay.portal.service.LayoutBranchService.class)
603            protected com.liferay.portal.service.LayoutBranchService layoutBranchService;
604            @BeanReference(type = LayoutBranchPersistence.class)
605            protected LayoutBranchPersistence layoutBranchPersistence;
606            @BeanReference(type = com.liferay.portal.service.LayoutRevisionLocalService.class)
607            protected com.liferay.portal.service.LayoutRevisionLocalService layoutRevisionLocalService;
608            @BeanReference(type = com.liferay.portal.service.LayoutRevisionService.class)
609            protected com.liferay.portal.service.LayoutRevisionService layoutRevisionService;
610            @BeanReference(type = LayoutRevisionPersistence.class)
611            protected LayoutRevisionPersistence layoutRevisionPersistence;
612            @BeanReference(type = com.liferay.portal.service.LayoutSetLocalService.class)
613            protected com.liferay.portal.service.LayoutSetLocalService layoutSetLocalService;
614            @BeanReference(type = com.liferay.portal.service.LayoutSetService.class)
615            protected com.liferay.portal.service.LayoutSetService layoutSetService;
616            @BeanReference(type = LayoutSetPersistence.class)
617            protected LayoutSetPersistence layoutSetPersistence;
618            @BeanReference(type = com.liferay.portal.service.ResourceLocalService.class)
619            protected com.liferay.portal.service.ResourceLocalService resourceLocalService;
620            @BeanReference(type = com.liferay.portal.service.UserLocalService.class)
621            protected com.liferay.portal.service.UserLocalService userLocalService;
622            @BeanReference(type = com.liferay.portal.service.UserService.class)
623            protected com.liferay.portal.service.UserService userService;
624            @BeanReference(type = UserPersistence.class)
625            protected UserPersistence userPersistence;
626            @BeanReference(type = UserFinder.class)
627            protected UserFinder userFinder;
628    }