001    /**
002     * Copyright (c) 2000-2012 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.portlet.journal.service;
016    
017    import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
018    import com.liferay.portal.kernel.util.ReferenceRegistry;
019    
020    /**
021     * The utility for the journal template remote service. This utility wraps {@link com.liferay.portlet.journal.service.impl.JournalTemplateServiceImpl} and is the primary access point for service operations in application layer code running on a remote server.
022     *
023     * <p>
024     * This is a remote service. Methods of this service are expected to have security checks based on the propagated JAAS credentials because this service can be accessed remotely.
025     * </p>
026     *
027     * @author Brian Wing Shun Chan
028     * @see JournalTemplateService
029     * @see com.liferay.portlet.journal.service.base.JournalTemplateServiceBaseImpl
030     * @see com.liferay.portlet.journal.service.impl.JournalTemplateServiceImpl
031     * @generated
032     */
033    public class JournalTemplateServiceUtil {
034            /*
035             * NOTE FOR DEVELOPERS:
036             *
037             * Never modify this class directly. Add custom service methods to {@link com.liferay.portlet.journal.service.impl.JournalTemplateServiceImpl} and rerun ServiceBuilder to regenerate this class.
038             */
039    
040            /**
041            * Returns the Spring bean ID for this bean.
042            *
043            * @return the Spring bean ID for this bean
044            */
045            public static java.lang.String getBeanIdentifier() {
046                    return getService().getBeanIdentifier();
047            }
048    
049            /**
050            * Sets the Spring bean ID for this bean.
051            *
052            * @param beanIdentifier the Spring bean ID for this bean
053            */
054            public static void setBeanIdentifier(java.lang.String beanIdentifier) {
055                    getService().setBeanIdentifier(beanIdentifier);
056            }
057    
058            public static com.liferay.portlet.journal.model.JournalTemplate addTemplate(
059                    long groupId, java.lang.String templateId, boolean autoTemplateId,
060                    java.lang.String structureId,
061                    java.util.Map<java.util.Locale, java.lang.String> nameMap,
062                    java.util.Map<java.util.Locale, java.lang.String> descriptionMap,
063                    java.lang.String xsl, boolean formatXsl, java.lang.String langType,
064                    boolean cacheable, boolean smallImage, java.lang.String smallImageURL,
065                    java.io.File smallFile,
066                    com.liferay.portal.service.ServiceContext serviceContext)
067                    throws com.liferay.portal.kernel.exception.PortalException,
068                            com.liferay.portal.kernel.exception.SystemException {
069                    return getService()
070                                       .addTemplate(groupId, templateId, autoTemplateId,
071                            structureId, nameMap, descriptionMap, xsl, formatXsl, langType,
072                            cacheable, smallImage, smallImageURL, smallFile, serviceContext);
073            }
074    
075            public static com.liferay.portlet.journal.model.JournalTemplate addTemplate(
076                    long groupId, java.lang.String templateId, boolean autoTemplateId,
077                    java.lang.String structureId,
078                    java.util.Map<java.util.Locale, java.lang.String> nameMap,
079                    java.util.Map<java.util.Locale, java.lang.String> descriptionMap,
080                    java.lang.String xsl, boolean formatXsl, java.lang.String langType,
081                    boolean cacheable,
082                    com.liferay.portal.service.ServiceContext serviceContext)
083                    throws com.liferay.portal.kernel.exception.PortalException,
084                            com.liferay.portal.kernel.exception.SystemException {
085                    return getService()
086                                       .addTemplate(groupId, templateId, autoTemplateId,
087                            structureId, nameMap, descriptionMap, xsl, formatXsl, langType,
088                            cacheable, serviceContext);
089            }
090    
091            public static com.liferay.portlet.journal.model.JournalTemplate copyTemplate(
092                    long groupId, java.lang.String oldTemplateId,
093                    java.lang.String newTemplateId, boolean autoTemplateId)
094                    throws com.liferay.portal.kernel.exception.PortalException,
095                            com.liferay.portal.kernel.exception.SystemException {
096                    return getService()
097                                       .copyTemplate(groupId, oldTemplateId, newTemplateId,
098                            autoTemplateId);
099            }
100    
101            public static void deleteTemplate(long groupId, java.lang.String templateId)
102                    throws com.liferay.portal.kernel.exception.PortalException,
103                            com.liferay.portal.kernel.exception.SystemException {
104                    getService().deleteTemplate(groupId, templateId);
105            }
106    
107            public static java.util.List<com.liferay.portlet.journal.model.JournalTemplate> getStructureTemplates(
108                    long groupId, java.lang.String structureId)
109                    throws com.liferay.portal.kernel.exception.SystemException {
110                    return getService().getStructureTemplates(groupId, structureId);
111            }
112    
113            public static com.liferay.portlet.journal.model.JournalTemplate getTemplate(
114                    long groupId, java.lang.String templateId)
115                    throws com.liferay.portal.kernel.exception.PortalException,
116                            com.liferay.portal.kernel.exception.SystemException {
117                    return getService().getTemplate(groupId, templateId);
118            }
119    
120            public static java.util.List<com.liferay.portlet.journal.model.JournalTemplate> search(
121                    long companyId, long[] groupIds, java.lang.String keywords,
122                    java.lang.String structureId, java.lang.String structureIdComparator,
123                    int start, int end, com.liferay.portal.kernel.util.OrderByComparator obc)
124                    throws com.liferay.portal.kernel.exception.SystemException {
125                    return getService()
126                                       .search(companyId, groupIds, keywords, structureId,
127                            structureIdComparator, start, end, obc);
128            }
129    
130            public static java.util.List<com.liferay.portlet.journal.model.JournalTemplate> search(
131                    long companyId, long[] groupIds, java.lang.String templateId,
132                    java.lang.String structureId, java.lang.String structureIdComparator,
133                    java.lang.String name, java.lang.String description,
134                    boolean andOperator, int start, int end,
135                    com.liferay.portal.kernel.util.OrderByComparator obc)
136                    throws com.liferay.portal.kernel.exception.SystemException {
137                    return getService()
138                                       .search(companyId, groupIds, templateId, structureId,
139                            structureIdComparator, name, description, andOperator, start, end,
140                            obc);
141            }
142    
143            public static int searchCount(long companyId, long[] groupIds,
144                    java.lang.String keywords, java.lang.String structureId,
145                    java.lang.String structureIdComparator)
146                    throws com.liferay.portal.kernel.exception.SystemException {
147                    return getService()
148                                       .searchCount(companyId, groupIds, keywords, structureId,
149                            structureIdComparator);
150            }
151    
152            public static int searchCount(long companyId, long[] groupIds,
153                    java.lang.String templateId, java.lang.String structureId,
154                    java.lang.String structureIdComparator, java.lang.String name,
155                    java.lang.String description, boolean andOperator)
156                    throws com.liferay.portal.kernel.exception.SystemException {
157                    return getService()
158                                       .searchCount(companyId, groupIds, templateId, structureId,
159                            structureIdComparator, name, description, andOperator);
160            }
161    
162            public static com.liferay.portlet.journal.model.JournalTemplate updateTemplate(
163                    long groupId, java.lang.String templateId,
164                    java.lang.String structureId,
165                    java.util.Map<java.util.Locale, java.lang.String> nameMap,
166                    java.util.Map<java.util.Locale, java.lang.String> descriptionMap,
167                    java.lang.String xsl, boolean formatXsl, java.lang.String langType,
168                    boolean cacheable, boolean smallImage, java.lang.String smallImageURL,
169                    java.io.File smallFile,
170                    com.liferay.portal.service.ServiceContext serviceContext)
171                    throws com.liferay.portal.kernel.exception.PortalException,
172                            com.liferay.portal.kernel.exception.SystemException {
173                    return getService()
174                                       .updateTemplate(groupId, templateId, structureId, nameMap,
175                            descriptionMap, xsl, formatXsl, langType, cacheable, smallImage,
176                            smallImageURL, smallFile, serviceContext);
177            }
178    
179            public static com.liferay.portlet.journal.model.JournalTemplate updateTemplate(
180                    long groupId, java.lang.String templateId,
181                    java.lang.String structureId,
182                    java.util.Map<java.util.Locale, java.lang.String> nameMap,
183                    java.util.Map<java.util.Locale, java.lang.String> descriptionMap,
184                    java.lang.String xsl, boolean formatXsl, java.lang.String langType,
185                    boolean cacheable,
186                    com.liferay.portal.service.ServiceContext serviceContext)
187                    throws com.liferay.portal.kernel.exception.PortalException,
188                            com.liferay.portal.kernel.exception.SystemException {
189                    return getService()
190                                       .updateTemplate(groupId, templateId, structureId, nameMap,
191                            descriptionMap, xsl, formatXsl, langType, cacheable, serviceContext);
192            }
193    
194            public static JournalTemplateService getService() {
195                    if (_service == null) {
196                            _service = (JournalTemplateService)PortalBeanLocatorUtil.locate(JournalTemplateService.class.getName());
197    
198                            ReferenceRegistry.registerReference(JournalTemplateServiceUtil.class,
199                                    "_service");
200                    }
201    
202                    return _service;
203            }
204    
205            /**
206             * @deprecated
207             */
208            public void setService(JournalTemplateService service) {
209            }
210    
211            private static JournalTemplateService _service;
212    }