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 folder remote service. This utility wraps {@link com.liferay.portlet.journal.service.impl.JournalFolderServiceImpl} 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 JournalFolderService
029     * @see com.liferay.portlet.journal.service.base.JournalFolderServiceBaseImpl
030     * @see com.liferay.portlet.journal.service.impl.JournalFolderServiceImpl
031     * @generated
032     */
033    public class JournalFolderServiceUtil {
034            /*
035             * NOTE FOR DEVELOPERS:
036             *
037             * Never modify this class directly. Add custom service methods to {@link com.liferay.portlet.journal.service.impl.JournalFolderServiceImpl} 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.JournalFolder addFolder(
059                    long groupId, long parentFolderId, java.lang.String name,
060                    java.lang.String description,
061                    com.liferay.portal.service.ServiceContext serviceContext)
062                    throws com.liferay.portal.kernel.exception.PortalException,
063                            com.liferay.portal.kernel.exception.SystemException {
064                    return getService()
065                                       .addFolder(groupId, parentFolderId, name, description,
066                            serviceContext);
067            }
068    
069            public static void deleteFolder(long folderId)
070                    throws com.liferay.portal.kernel.exception.PortalException,
071                            com.liferay.portal.kernel.exception.SystemException {
072                    getService().deleteFolder(folderId);
073            }
074    
075            public static com.liferay.portlet.journal.model.JournalFolder getFolder(
076                    long folderId)
077                    throws com.liferay.portal.kernel.exception.PortalException,
078                            com.liferay.portal.kernel.exception.SystemException {
079                    return getService().getFolder(folderId);
080            }
081    
082            public static java.util.List<com.liferay.portlet.journal.model.JournalFolder> getFolders(
083                    long groupId)
084                    throws com.liferay.portal.kernel.exception.SystemException {
085                    return getService().getFolders(groupId);
086            }
087    
088            public static java.util.List<com.liferay.portlet.journal.model.JournalFolder> getFolders(
089                    long groupId, long parentFolderId)
090                    throws com.liferay.portal.kernel.exception.SystemException {
091                    return getService().getFolders(groupId, parentFolderId);
092            }
093    
094            public static java.util.List<com.liferay.portlet.journal.model.JournalFolder> getFolders(
095                    long groupId, long parentFolderId, int start, int end)
096                    throws com.liferay.portal.kernel.exception.SystemException {
097                    return getService().getFolders(groupId, parentFolderId, start, end);
098            }
099    
100            public static java.util.List<java.lang.Object> getFoldersAndArticles(
101                    long groupId, long folderId, int start, int end,
102                    com.liferay.portal.kernel.util.OrderByComparator obc)
103                    throws com.liferay.portal.kernel.exception.SystemException {
104                    return getService()
105                                       .getFoldersAndArticles(groupId, folderId, start, end, obc);
106            }
107    
108            public static int getFoldersAndArticlesCount(long groupId,
109                    java.util.List<java.lang.Long> folderIds, int status)
110                    throws com.liferay.portal.kernel.exception.SystemException {
111                    return getService()
112                                       .getFoldersAndArticlesCount(groupId, folderIds, status);
113            }
114    
115            public static int getFoldersAndArticlesCount(long groupId, long folderId)
116                    throws com.liferay.portal.kernel.exception.SystemException {
117                    return getService().getFoldersAndArticlesCount(groupId, folderId);
118            }
119    
120            public static int getFoldersAndArticlesCount(long groupId, long folderId,
121                    int status) throws com.liferay.portal.kernel.exception.SystemException {
122                    return getService().getFoldersAndArticlesCount(groupId, folderId, status);
123            }
124    
125            public static int getFoldersCount(long groupId, long parentFolderId)
126                    throws com.liferay.portal.kernel.exception.SystemException {
127                    return getService().getFoldersCount(groupId, parentFolderId);
128            }
129    
130            public static void getSubfolderIds(
131                    java.util.List<java.lang.Long> folderIds, long groupId, long folderId)
132                    throws com.liferay.portal.kernel.exception.SystemException {
133                    getService().getSubfolderIds(folderIds, groupId, folderId);
134            }
135    
136            public static java.util.List<java.lang.Long> getSubfolderIds(long groupId,
137                    long folderId, boolean recurse)
138                    throws com.liferay.portal.kernel.exception.SystemException {
139                    return getService().getSubfolderIds(groupId, folderId, recurse);
140            }
141    
142            public static com.liferay.portlet.journal.model.JournalFolder moveFolder(
143                    long folderId, long parentFolderId,
144                    com.liferay.portal.service.ServiceContext serviceContext)
145                    throws com.liferay.portal.kernel.exception.PortalException,
146                            com.liferay.portal.kernel.exception.SystemException {
147                    return getService().moveFolder(folderId, parentFolderId, serviceContext);
148            }
149    
150            public static com.liferay.portlet.journal.model.JournalFolder updateFolder(
151                    long folderId, long parentFolderId, java.lang.String name,
152                    java.lang.String description, boolean mergeWithParentFolder,
153                    com.liferay.portal.service.ServiceContext serviceContext)
154                    throws com.liferay.portal.kernel.exception.PortalException,
155                            com.liferay.portal.kernel.exception.SystemException {
156                    return getService()
157                                       .updateFolder(folderId, parentFolderId, name, description,
158                            mergeWithParentFolder, serviceContext);
159            }
160    
161            public static JournalFolderService getService() {
162                    if (_service == null) {
163                            _service = (JournalFolderService)PortalBeanLocatorUtil.locate(JournalFolderService.class.getName());
164    
165                            ReferenceRegistry.registerReference(JournalFolderServiceUtil.class,
166                                    "_service");
167                    }
168    
169                    return _service;
170            }
171    
172            /**
173             * @deprecated
174             */
175            public void setService(JournalFolderService service) {
176            }
177    
178            private static JournalFolderService _service;
179    }