001    /**
002     * Copyright (c) 2000-2013 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.asset.service.http;
016    
017    import com.liferay.portal.kernel.log.Log;
018    import com.liferay.portal.kernel.log.LogFactoryUtil;
019    
020    import com.liferay.portlet.asset.service.AssetEntryServiceUtil;
021    
022    import java.rmi.RemoteException;
023    
024    /**
025     * Provides the SOAP utility for the
026     * {@link com.liferay.portlet.asset.service.AssetEntryServiceUtil} service utility. The
027     * static methods of this class calls the same methods of the service utility.
028     * However, the signatures are different because it is difficult for SOAP to
029     * support certain types.
030     *
031     * <p>
032     * ServiceBuilder follows certain rules in translating the methods. For example,
033     * if the method in the service utility returns a {@link java.util.List}, that
034     * is translated to an array of {@link com.liferay.portlet.asset.model.AssetEntrySoap}.
035     * If the method in the service utility returns a
036     * {@link com.liferay.portlet.asset.model.AssetEntry}, that is translated to a
037     * {@link com.liferay.portlet.asset.model.AssetEntrySoap}. Methods that SOAP cannot
038     * safely wire are skipped.
039     * </p>
040     *
041     * <p>
042     * The benefits of using the SOAP utility is that it is cross platform
043     * compatible. SOAP allows different languages like Java, .NET, C++, PHP, and
044     * even Perl, to call the generated services. One drawback of SOAP is that it is
045     * slow because it needs to serialize all calls into a text format (XML).
046     * </p>
047     *
048     * <p>
049     * You can see a list of services at http://localhost:8080/api/axis. Set the
050     * property <b>axis.servlet.hosts.allowed</b> in portal.properties to configure
051     * security.
052     * </p>
053     *
054     * <p>
055     * The SOAP utility is only generated for remote services.
056     * </p>
057     *
058     * @author Brian Wing Shun Chan
059     * @see AssetEntryServiceHttp
060     * @see com.liferay.portlet.asset.model.AssetEntrySoap
061     * @see com.liferay.portlet.asset.service.AssetEntryServiceUtil
062     * @generated
063     */
064    public class AssetEntryServiceSoap {
065            public static com.liferay.portlet.asset.model.AssetEntrySoap[] getCompanyEntries(
066                    long companyId, int start, int end) throws RemoteException {
067                    try {
068                            java.util.List<com.liferay.portlet.asset.model.AssetEntry> returnValue =
069                                    AssetEntryServiceUtil.getCompanyEntries(companyId, start, end);
070    
071                            return com.liferay.portlet.asset.model.AssetEntrySoap.toSoapModels(returnValue);
072                    }
073                    catch (Exception e) {
074                            _log.error(e, e);
075    
076                            throw new RemoteException(e.getMessage());
077                    }
078            }
079    
080            public static int getCompanyEntriesCount(long companyId)
081                    throws RemoteException {
082                    try {
083                            int returnValue = AssetEntryServiceUtil.getCompanyEntriesCount(companyId);
084    
085                            return returnValue;
086                    }
087                    catch (Exception e) {
088                            _log.error(e, e);
089    
090                            throw new RemoteException(e.getMessage());
091                    }
092            }
093    
094            public static com.liferay.portlet.asset.model.AssetEntrySoap[] getEntries(
095                    com.liferay.portlet.asset.service.persistence.AssetEntryQuery entryQuery)
096                    throws RemoteException {
097                    try {
098                            java.util.List<com.liferay.portlet.asset.model.AssetEntry> returnValue =
099                                    AssetEntryServiceUtil.getEntries(entryQuery);
100    
101                            return com.liferay.portlet.asset.model.AssetEntrySoap.toSoapModels(returnValue);
102                    }
103                    catch (Exception e) {
104                            _log.error(e, e);
105    
106                            throw new RemoteException(e.getMessage());
107                    }
108            }
109    
110            public static int getEntriesCount(
111                    com.liferay.portlet.asset.service.persistence.AssetEntryQuery entryQuery)
112                    throws RemoteException {
113                    try {
114                            int returnValue = AssetEntryServiceUtil.getEntriesCount(entryQuery);
115    
116                            return returnValue;
117                    }
118                    catch (Exception e) {
119                            _log.error(e, e);
120    
121                            throw new RemoteException(e.getMessage());
122                    }
123            }
124    
125            public static com.liferay.portlet.asset.model.AssetEntrySoap getEntry(
126                    long entryId) throws RemoteException {
127                    try {
128                            com.liferay.portlet.asset.model.AssetEntry returnValue = AssetEntryServiceUtil.getEntry(entryId);
129    
130                            return com.liferay.portlet.asset.model.AssetEntrySoap.toSoapModel(returnValue);
131                    }
132                    catch (Exception e) {
133                            _log.error(e, e);
134    
135                            throw new RemoteException(e.getMessage());
136                    }
137            }
138    
139            public static com.liferay.portlet.asset.model.AssetEntrySoap incrementViewCounter(
140                    java.lang.String className, long classPK) throws RemoteException {
141                    try {
142                            com.liferay.portlet.asset.model.AssetEntry returnValue = AssetEntryServiceUtil.incrementViewCounter(className,
143                                            classPK);
144    
145                            return com.liferay.portlet.asset.model.AssetEntrySoap.toSoapModel(returnValue);
146                    }
147                    catch (Exception e) {
148                            _log.error(e, e);
149    
150                            throw new RemoteException(e.getMessage());
151                    }
152            }
153    
154            public static com.liferay.portlet.asset.model.AssetEntrySoap updateEntry(
155                    long groupId, java.util.Date createDate, java.util.Date modifiedDate,
156                    java.lang.String className, long classPK, java.lang.String classUuid,
157                    long classTypeId, long[] categoryIds, java.lang.String[] tagNames,
158                    boolean visible, java.util.Date startDate, java.util.Date endDate,
159                    java.util.Date expirationDate, java.lang.String mimeType,
160                    java.lang.String title, java.lang.String description,
161                    java.lang.String summary, java.lang.String url,
162                    java.lang.String layoutUuid, int height, int width,
163                    java.lang.Integer priority, boolean sync) throws RemoteException {
164                    try {
165                            com.liferay.portlet.asset.model.AssetEntry returnValue = AssetEntryServiceUtil.updateEntry(groupId,
166                                            createDate, modifiedDate, className, classPK, classUuid,
167                                            classTypeId, categoryIds, tagNames, visible, startDate,
168                                            endDate, expirationDate, mimeType, title, description,
169                                            summary, url, layoutUuid, height, width, priority, sync);
170    
171                            return com.liferay.portlet.asset.model.AssetEntrySoap.toSoapModel(returnValue);
172                    }
173                    catch (Exception e) {
174                            _log.error(e, e);
175    
176                            throw new RemoteException(e.getMessage());
177                    }
178            }
179    
180            /**
181            * @deprecated As of 6.2.0, replaced by {@link #updateEntry(long, String,
182            long, String, long, long[], String[], boolean, Date, Date,
183            Date, String, String, String, String, String, String, int,
184            int, Integer, boolean)}
185            */
186            public static com.liferay.portlet.asset.model.AssetEntrySoap updateEntry(
187                    long groupId, java.lang.String className, long classPK,
188                    java.lang.String classUuid, long classTypeId, long[] categoryIds,
189                    java.lang.String[] tagNames, boolean visible, java.util.Date startDate,
190                    java.util.Date endDate, java.util.Date publishDate,
191                    java.util.Date expirationDate, java.lang.String mimeType,
192                    java.lang.String title, java.lang.String description,
193                    java.lang.String summary, java.lang.String url,
194                    java.lang.String layoutUuid, int height, int width,
195                    java.lang.Integer priority, boolean sync) throws RemoteException {
196                    try {
197                            com.liferay.portlet.asset.model.AssetEntry returnValue = AssetEntryServiceUtil.updateEntry(groupId,
198                                            className, classPK, classUuid, classTypeId, categoryIds,
199                                            tagNames, visible, startDate, endDate, publishDate,
200                                            expirationDate, mimeType, title, description, summary, url,
201                                            layoutUuid, height, width, priority, sync);
202    
203                            return com.liferay.portlet.asset.model.AssetEntrySoap.toSoapModel(returnValue);
204                    }
205                    catch (Exception e) {
206                            _log.error(e, e);
207    
208                            throw new RemoteException(e.getMessage());
209                    }
210            }
211    
212            /**
213            * @deprecated As of 6.2.0, replaced by {@link #updateEntry(long, Date,
214            Date, String, long, String, long, long[], String[], boolean,
215            Date, Date, Date, String, String, String, String, String,
216            String, int, int, Integer, boolean)}
217            */
218            public static com.liferay.portlet.asset.model.AssetEntrySoap updateEntry(
219                    long groupId, java.lang.String className, long classPK,
220                    java.lang.String classUuid, long classTypeId, long[] categoryIds,
221                    java.lang.String[] tagNames, boolean visible, java.util.Date startDate,
222                    java.util.Date endDate, java.util.Date expirationDate,
223                    java.lang.String mimeType, java.lang.String title,
224                    java.lang.String description, java.lang.String summary,
225                    java.lang.String url, java.lang.String layoutUuid, int height,
226                    int width, java.lang.Integer priority, boolean sync)
227                    throws RemoteException {
228                    try {
229                            com.liferay.portlet.asset.model.AssetEntry returnValue = AssetEntryServiceUtil.updateEntry(groupId,
230                                            className, classPK, classUuid, classTypeId, categoryIds,
231                                            tagNames, visible, startDate, endDate, expirationDate,
232                                            mimeType, title, description, summary, url, layoutUuid,
233                                            height, width, priority, sync);
234    
235                            return com.liferay.portlet.asset.model.AssetEntrySoap.toSoapModel(returnValue);
236                    }
237                    catch (Exception e) {
238                            _log.error(e, e);
239    
240                            throw new RemoteException(e.getMessage());
241                    }
242            }
243    
244            private static Log _log = LogFactoryUtil.getLog(AssetEntryServiceSoap.class);
245    }