001    /**
002     * Copyright (c) 2000-2011 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.blogs.service;
016    
017    import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
018    import com.liferay.portal.kernel.util.MethodCache;
019    import com.liferay.portal.kernel.util.ReferenceRegistry;
020    
021    /**
022     * The utility for the blogs entry remote service. This utility wraps {@link com.liferay.portlet.blogs.service.impl.BlogsEntryServiceImpl} and is the primary access point for service operations in application layer code running on a remote server.
023     *
024     * <p>
025     * 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.
026     * </p>
027     *
028     * @author Brian Wing Shun Chan
029     * @see BlogsEntryService
030     * @see com.liferay.portlet.blogs.service.base.BlogsEntryServiceBaseImpl
031     * @see com.liferay.portlet.blogs.service.impl.BlogsEntryServiceImpl
032     * @generated
033     */
034    public class BlogsEntryServiceUtil {
035            /*
036             * NOTE FOR DEVELOPERS:
037             *
038             * Never modify this class directly. Add custom service methods to {@link com.liferay.portlet.blogs.service.impl.BlogsEntryServiceImpl} and rerun ServiceBuilder to regenerate this class.
039             */
040            public static com.liferay.portlet.blogs.model.BlogsEntry addEntry(
041                    java.lang.String title, java.lang.String description,
042                    java.lang.String content, int displayDateMonth, int displayDateDay,
043                    int displayDateYear, int displayDateHour, int displayDateMinute,
044                    boolean allowPingbacks, boolean allowTrackbacks,
045                    java.lang.String[] trackbacks, boolean smallImage,
046                    java.lang.String smallImageURL, java.lang.String smallImageFileName,
047                    java.io.InputStream smallImageInputStream,
048                    com.liferay.portal.service.ServiceContext serviceContext)
049                    throws com.liferay.portal.kernel.exception.PortalException,
050                            com.liferay.portal.kernel.exception.SystemException {
051                    return getService()
052                                       .addEntry(title, description, content, displayDateMonth,
053                            displayDateDay, displayDateYear, displayDateHour,
054                            displayDateMinute, allowPingbacks, allowTrackbacks, trackbacks,
055                            smallImage, smallImageURL, smallImageFileName,
056                            smallImageInputStream, serviceContext);
057            }
058    
059            public static void deleteEntry(long entryId)
060                    throws com.liferay.portal.kernel.exception.PortalException,
061                            com.liferay.portal.kernel.exception.SystemException {
062                    getService().deleteEntry(entryId);
063            }
064    
065            public static java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> getCompanyEntries(
066                    long companyId, int status, int max)
067                    throws com.liferay.portal.kernel.exception.PortalException,
068                            com.liferay.portal.kernel.exception.SystemException {
069                    return getService().getCompanyEntries(companyId, status, max);
070            }
071    
072            public static java.lang.String getCompanyEntriesRSS(long companyId,
073                    int status, int max, java.lang.String type, double version,
074                    java.lang.String displayStyle, java.lang.String feedURL,
075                    java.lang.String entryURL,
076                    com.liferay.portal.theme.ThemeDisplay themeDisplay)
077                    throws com.liferay.portal.kernel.exception.PortalException,
078                            com.liferay.portal.kernel.exception.SystemException {
079                    return getService()
080                                       .getCompanyEntriesRSS(companyId, status, max, type, version,
081                            displayStyle, feedURL, entryURL, themeDisplay);
082            }
083    
084            public static com.liferay.portlet.blogs.model.BlogsEntry getEntry(
085                    long entryId)
086                    throws com.liferay.portal.kernel.exception.PortalException,
087                            com.liferay.portal.kernel.exception.SystemException {
088                    return getService().getEntry(entryId);
089            }
090    
091            public static com.liferay.portlet.blogs.model.BlogsEntry getEntry(
092                    long groupId, java.lang.String urlTitle)
093                    throws com.liferay.portal.kernel.exception.PortalException,
094                            com.liferay.portal.kernel.exception.SystemException {
095                    return getService().getEntry(groupId, urlTitle);
096            }
097    
098            public static java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> getGroupEntries(
099                    long groupId, int status, int max)
100                    throws com.liferay.portal.kernel.exception.SystemException {
101                    return getService().getGroupEntries(groupId, status, max);
102            }
103    
104            public static java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> getGroupEntries(
105                    long groupId, int status, int start, int end)
106                    throws com.liferay.portal.kernel.exception.SystemException {
107                    return getService().getGroupEntries(groupId, status, start, end);
108            }
109    
110            public static int getGroupEntriesCount(long groupId, int status)
111                    throws com.liferay.portal.kernel.exception.SystemException {
112                    return getService().getGroupEntriesCount(groupId, status);
113            }
114    
115            public static java.lang.String getGroupEntriesRSS(long groupId, int status,
116                    int max, java.lang.String type, double version,
117                    java.lang.String displayStyle, java.lang.String feedURL,
118                    java.lang.String entryURL,
119                    com.liferay.portal.theme.ThemeDisplay themeDisplay)
120                    throws com.liferay.portal.kernel.exception.PortalException,
121                            com.liferay.portal.kernel.exception.SystemException {
122                    return getService()
123                                       .getGroupEntriesRSS(groupId, status, max, type, version,
124                            displayStyle, feedURL, entryURL, themeDisplay);
125            }
126    
127            public static java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> getGroupsEntries(
128                    long companyId, long groupId, int status, int max)
129                    throws com.liferay.portal.kernel.exception.PortalException,
130                            com.liferay.portal.kernel.exception.SystemException {
131                    return getService().getGroupsEntries(companyId, groupId, status, max);
132            }
133    
134            public static java.util.List<com.liferay.portlet.blogs.model.BlogsEntry> getOrganizationEntries(
135                    long organizationId, int status, int max)
136                    throws com.liferay.portal.kernel.exception.PortalException,
137                            com.liferay.portal.kernel.exception.SystemException {
138                    return getService().getOrganizationEntries(organizationId, status, max);
139            }
140    
141            public static java.lang.String getOrganizationEntriesRSS(
142                    long organizationId, int status, int max, java.lang.String type,
143                    double version, java.lang.String displayStyle,
144                    java.lang.String feedURL, java.lang.String entryURL,
145                    com.liferay.portal.theme.ThemeDisplay themeDisplay)
146                    throws com.liferay.portal.kernel.exception.PortalException,
147                            com.liferay.portal.kernel.exception.SystemException {
148                    return getService()
149                                       .getOrganizationEntriesRSS(organizationId, status, max,
150                            type, version, displayStyle, feedURL, entryURL, themeDisplay);
151            }
152    
153            public static void subscribe(long groupId)
154                    throws com.liferay.portal.kernel.exception.PortalException,
155                            com.liferay.portal.kernel.exception.SystemException {
156                    getService().subscribe(groupId);
157            }
158    
159            public static void unsubscribe(long groupId)
160                    throws com.liferay.portal.kernel.exception.PortalException,
161                            com.liferay.portal.kernel.exception.SystemException {
162                    getService().unsubscribe(groupId);
163            }
164    
165            public static com.liferay.portlet.blogs.model.BlogsEntry updateEntry(
166                    long entryId, java.lang.String title, java.lang.String description,
167                    java.lang.String content, int displayDateMonth, int displayDateDay,
168                    int displayDateYear, int displayDateHour, int displayDateMinute,
169                    boolean allowPingbacks, boolean allowTrackbacks,
170                    java.lang.String[] trackbacks, boolean smallImage,
171                    java.lang.String smallImageURL, java.lang.String smallImageFileName,
172                    java.io.InputStream smallImageInputStream,
173                    com.liferay.portal.service.ServiceContext serviceContext)
174                    throws com.liferay.portal.kernel.exception.PortalException,
175                            com.liferay.portal.kernel.exception.SystemException {
176                    return getService()
177                                       .updateEntry(entryId, title, description, content,
178                            displayDateMonth, displayDateDay, displayDateYear, displayDateHour,
179                            displayDateMinute, allowPingbacks, allowTrackbacks, trackbacks,
180                            smallImage, smallImageURL, smallImageFileName,
181                            smallImageInputStream, serviceContext);
182            }
183    
184            public static BlogsEntryService getService() {
185                    if (_service == null) {
186                            _service = (BlogsEntryService)PortalBeanLocatorUtil.locate(BlogsEntryService.class.getName());
187    
188                            ReferenceRegistry.registerReference(BlogsEntryServiceUtil.class,
189                                    "_service");
190                            MethodCache.remove(BlogsEntryService.class);
191                    }
192    
193                    return _service;
194            }
195    
196            public void setService(BlogsEntryService service) {
197                    MethodCache.remove(BlogsEntryService.class);
198    
199                    _service = service;
200    
201                    ReferenceRegistry.registerReference(BlogsEntryServiceUtil.class,
202                            "_service");
203                    MethodCache.remove(BlogsEntryService.class);
204            }
205    
206            private static BlogsEntryService _service;
207    }