001    /**
002     * Copyright (c) 2000-2010 Liferay, Inc. All rights reserved.
003     *
004     * The contents of this file are subject to the terms of the Liferay Enterprise
005     * Subscription License ("License"). You may not use this file except in
006     * compliance with the License. You can obtain a copy of the License by
007     * contacting Liferay, Inc. See the License for the specific language governing
008     * permissions and limitations under the License, including but not limited to
009     * distribution rights of the Software.
010     *
011     *
012     *
013     */
014    
015    package com.liferay.portlet.messageboards.service.http;
016    
017    import com.liferay.portal.kernel.log.Log;
018    import com.liferay.portal.kernel.log.LogFactoryUtil;
019    import com.liferay.portal.kernel.util.MethodHandler;
020    import com.liferay.portal.kernel.util.MethodKey;
021    import com.liferay.portal.security.auth.HttpPrincipal;
022    import com.liferay.portal.service.http.TunnelUtil;
023    
024    import com.liferay.portlet.messageboards.service.MBMessageServiceUtil;
025    
026    /**
027     * <p>
028     * This class provides a HTTP utility for the
029     * {@link com.liferay.portlet.messageboards.service.MBMessageServiceUtil} service utility. The
030     * static methods of this class calls the same methods of the service utility.
031     * However, the signatures are different because it requires an additional
032     * {@link com.liferay.portal.security.auth.HttpPrincipal} parameter.
033     * </p>
034     *
035     * <p>
036     * The benefits of using the HTTP utility is that it is fast and allows for
037     * tunneling without the cost of serializing to text. The drawback is that it
038     * only works with Java.
039     * </p>
040     *
041     * <p>
042     * Set the property <b>tunnel.servlet.hosts.allowed</b> in portal.properties to
043     * configure security.
044     * </p>
045     *
046     * <p>
047     * The HTTP utility is only generated for remote services.
048     * </p>
049     *
050     * @author    Brian Wing Shun Chan
051     * @see       MBMessageServiceSoap
052     * @see       com.liferay.portal.security.auth.HttpPrincipal
053     * @see       com.liferay.portlet.messageboards.service.MBMessageServiceUtil
054     * @generated
055     */
056    public class MBMessageServiceHttp {
057            public static com.liferay.portlet.messageboards.model.MBMessage addDiscussionMessage(
058                    HttpPrincipal httpPrincipal, long groupId, java.lang.String className,
059                    long classPK, java.lang.String permissionClassName,
060                    long permissionClassPK, long threadId, long parentMessageId,
061                    java.lang.String subject, java.lang.String body,
062                    com.liferay.portal.service.ServiceContext serviceContext)
063                    throws com.liferay.portal.kernel.exception.PortalException,
064                            com.liferay.portal.kernel.exception.SystemException {
065                    try {
066                            MethodKey methodKey = new MethodKey(MBMessageServiceUtil.class.getName(),
067                                            "addDiscussionMessage", _addDiscussionMessageParameterTypes0);
068    
069                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
070                                            className, classPK, permissionClassName, permissionClassPK,
071                                            threadId, parentMessageId, subject, body, serviceContext);
072    
073                            Object returnObj = null;
074    
075                            try {
076                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
077                            }
078                            catch (Exception e) {
079                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
080                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
081                                    }
082    
083                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
084                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
085                                    }
086    
087                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
088                            }
089    
090                            return (com.liferay.portlet.messageboards.model.MBMessage)returnObj;
091                    }
092                    catch (com.liferay.portal.kernel.exception.SystemException se) {
093                            _log.error(se, se);
094    
095                            throw se;
096                    }
097            }
098    
099            public static com.liferay.portlet.messageboards.model.MBMessage addMessage(
100                    HttpPrincipal httpPrincipal, long groupId, long categoryId,
101                    long threadId, long parentMessageId, java.lang.String subject,
102                    java.lang.String body,
103                    java.util.List<com.liferay.portal.kernel.util.ObjectValuePair<java.lang.String, byte[]>> files,
104                    boolean anonymous, double priority, boolean allowPingbacks,
105                    com.liferay.portal.service.ServiceContext serviceContext)
106                    throws com.liferay.portal.kernel.exception.PortalException,
107                            com.liferay.portal.kernel.exception.SystemException {
108                    try {
109                            MethodKey methodKey = new MethodKey(MBMessageServiceUtil.class.getName(),
110                                            "addMessage", _addMessageParameterTypes1);
111    
112                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
113                                            categoryId, threadId, parentMessageId, subject, body,
114                                            files, anonymous, priority, allowPingbacks, serviceContext);
115    
116                            Object returnObj = null;
117    
118                            try {
119                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
120                            }
121                            catch (Exception e) {
122                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
123                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
124                                    }
125    
126                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
127                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
128                                    }
129    
130                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
131                            }
132    
133                            return (com.liferay.portlet.messageboards.model.MBMessage)returnObj;
134                    }
135                    catch (com.liferay.portal.kernel.exception.SystemException se) {
136                            _log.error(se, se);
137    
138                            throw se;
139                    }
140            }
141    
142            public static com.liferay.portlet.messageboards.model.MBMessage addMessage(
143                    HttpPrincipal httpPrincipal, long groupId, long categoryId,
144                    java.lang.String subject, java.lang.String body,
145                    java.util.List<com.liferay.portal.kernel.util.ObjectValuePair<java.lang.String, byte[]>> files,
146                    boolean anonymous, double priority, boolean allowPingbacks,
147                    com.liferay.portal.service.ServiceContext serviceContext)
148                    throws com.liferay.portal.kernel.exception.PortalException,
149                            com.liferay.portal.kernel.exception.SystemException {
150                    try {
151                            MethodKey methodKey = new MethodKey(MBMessageServiceUtil.class.getName(),
152                                            "addMessage", _addMessageParameterTypes2);
153    
154                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
155                                            categoryId, subject, body, files, anonymous, priority,
156                                            allowPingbacks, serviceContext);
157    
158                            Object returnObj = null;
159    
160                            try {
161                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
162                            }
163                            catch (Exception e) {
164                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
165                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
166                                    }
167    
168                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
169                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
170                                    }
171    
172                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
173                            }
174    
175                            return (com.liferay.portlet.messageboards.model.MBMessage)returnObj;
176                    }
177                    catch (com.liferay.portal.kernel.exception.SystemException se) {
178                            _log.error(se, se);
179    
180                            throw se;
181                    }
182            }
183    
184            public static void deleteDiscussionMessage(HttpPrincipal httpPrincipal,
185                    long groupId, java.lang.String className, long classPK,
186                    java.lang.String permissionClassName, long permissionClassPK,
187                    long messageId)
188                    throws com.liferay.portal.kernel.exception.PortalException,
189                            com.liferay.portal.kernel.exception.SystemException {
190                    try {
191                            MethodKey methodKey = new MethodKey(MBMessageServiceUtil.class.getName(),
192                                            "deleteDiscussionMessage",
193                                            _deleteDiscussionMessageParameterTypes3);
194    
195                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
196                                            className, classPK, permissionClassName, permissionClassPK,
197                                            messageId);
198    
199                            try {
200                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
201                            }
202                            catch (Exception e) {
203                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
204                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
205                                    }
206    
207                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
208                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
209                                    }
210    
211                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
212                            }
213                    }
214                    catch (com.liferay.portal.kernel.exception.SystemException se) {
215                            _log.error(se, se);
216    
217                            throw se;
218                    }
219            }
220    
221            public static void deleteMessage(HttpPrincipal httpPrincipal, long messageId)
222                    throws com.liferay.portal.kernel.exception.PortalException,
223                            com.liferay.portal.kernel.exception.SystemException {
224                    try {
225                            MethodKey methodKey = new MethodKey(MBMessageServiceUtil.class.getName(),
226                                            "deleteMessage", _deleteMessageParameterTypes4);
227    
228                            MethodHandler methodHandler = new MethodHandler(methodKey, messageId);
229    
230                            try {
231                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
232                            }
233                            catch (Exception e) {
234                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
235                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
236                                    }
237    
238                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
239                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
240                                    }
241    
242                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
243                            }
244                    }
245                    catch (com.liferay.portal.kernel.exception.SystemException se) {
246                            _log.error(se, se);
247    
248                            throw se;
249                    }
250            }
251    
252            public static java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getCategoryMessages(
253                    HttpPrincipal httpPrincipal, long groupId, long categoryId, int status,
254                    int start, int end)
255                    throws com.liferay.portal.kernel.exception.PortalException,
256                            com.liferay.portal.kernel.exception.SystemException {
257                    try {
258                            MethodKey methodKey = new MethodKey(MBMessageServiceUtil.class.getName(),
259                                            "getCategoryMessages", _getCategoryMessagesParameterTypes5);
260    
261                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
262                                            categoryId, status, start, end);
263    
264                            Object returnObj = null;
265    
266                            try {
267                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
268                            }
269                            catch (Exception e) {
270                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
271                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
272                                    }
273    
274                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
275                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
276                                    }
277    
278                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
279                            }
280    
281                            return (java.util.List<com.liferay.portlet.messageboards.model.MBMessage>)returnObj;
282                    }
283                    catch (com.liferay.portal.kernel.exception.SystemException se) {
284                            _log.error(se, se);
285    
286                            throw se;
287                    }
288            }
289    
290            public static int getCategoryMessagesCount(HttpPrincipal httpPrincipal,
291                    long groupId, long categoryId, int status)
292                    throws com.liferay.portal.kernel.exception.SystemException {
293                    try {
294                            MethodKey methodKey = new MethodKey(MBMessageServiceUtil.class.getName(),
295                                            "getCategoryMessagesCount",
296                                            _getCategoryMessagesCountParameterTypes6);
297    
298                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
299                                            categoryId, status);
300    
301                            Object returnObj = null;
302    
303                            try {
304                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
305                            }
306                            catch (Exception e) {
307                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
308                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
309                                    }
310    
311                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
312                            }
313    
314                            return ((Integer)returnObj).intValue();
315                    }
316                    catch (com.liferay.portal.kernel.exception.SystemException se) {
317                            _log.error(se, se);
318    
319                            throw se;
320                    }
321            }
322    
323            public static java.lang.String getCategoryMessagesRSS(
324                    HttpPrincipal httpPrincipal, long groupId, long categoryId, int status,
325                    int max, java.lang.String type, double version,
326                    java.lang.String displayStyle, java.lang.String feedURL,
327                    java.lang.String entryURL,
328                    com.liferay.portal.theme.ThemeDisplay themeDisplay)
329                    throws com.liferay.portal.kernel.exception.PortalException,
330                            com.liferay.portal.kernel.exception.SystemException {
331                    try {
332                            MethodKey methodKey = new MethodKey(MBMessageServiceUtil.class.getName(),
333                                            "getCategoryMessagesRSS",
334                                            _getCategoryMessagesRSSParameterTypes7);
335    
336                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
337                                            categoryId, status, max, type, version, displayStyle,
338                                            feedURL, entryURL, themeDisplay);
339    
340                            Object returnObj = null;
341    
342                            try {
343                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
344                            }
345                            catch (Exception e) {
346                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
347                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
348                                    }
349    
350                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
351                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
352                                    }
353    
354                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
355                            }
356    
357                            return (java.lang.String)returnObj;
358                    }
359                    catch (com.liferay.portal.kernel.exception.SystemException se) {
360                            _log.error(se, se);
361    
362                            throw se;
363                    }
364            }
365    
366            public static java.lang.String getCompanyMessagesRSS(
367                    HttpPrincipal httpPrincipal, long companyId, int status, int max,
368                    java.lang.String type, double version, java.lang.String displayStyle,
369                    java.lang.String feedURL, java.lang.String entryURL,
370                    com.liferay.portal.theme.ThemeDisplay themeDisplay)
371                    throws com.liferay.portal.kernel.exception.PortalException,
372                            com.liferay.portal.kernel.exception.SystemException {
373                    try {
374                            MethodKey methodKey = new MethodKey(MBMessageServiceUtil.class.getName(),
375                                            "getCompanyMessagesRSS",
376                                            _getCompanyMessagesRSSParameterTypes8);
377    
378                            MethodHandler methodHandler = new MethodHandler(methodKey,
379                                            companyId, status, max, type, version, displayStyle,
380                                            feedURL, entryURL, themeDisplay);
381    
382                            Object returnObj = null;
383    
384                            try {
385                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
386                            }
387                            catch (Exception e) {
388                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
389                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
390                                    }
391    
392                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
393                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
394                                    }
395    
396                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
397                            }
398    
399                            return (java.lang.String)returnObj;
400                    }
401                    catch (com.liferay.portal.kernel.exception.SystemException se) {
402                            _log.error(se, se);
403    
404                            throw se;
405                    }
406            }
407    
408            public static java.lang.String getGroupMessagesRSS(
409                    HttpPrincipal httpPrincipal, long groupId, int status, int max,
410                    java.lang.String type, double version, java.lang.String displayStyle,
411                    java.lang.String feedURL, java.lang.String entryURL,
412                    com.liferay.portal.theme.ThemeDisplay themeDisplay)
413                    throws com.liferay.portal.kernel.exception.PortalException,
414                            com.liferay.portal.kernel.exception.SystemException {
415                    try {
416                            MethodKey methodKey = new MethodKey(MBMessageServiceUtil.class.getName(),
417                                            "getGroupMessagesRSS", _getGroupMessagesRSSParameterTypes9);
418    
419                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
420                                            status, max, type, version, displayStyle, feedURL,
421                                            entryURL, themeDisplay);
422    
423                            Object returnObj = null;
424    
425                            try {
426                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
427                            }
428                            catch (Exception e) {
429                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
430                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
431                                    }
432    
433                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
434                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
435                                    }
436    
437                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
438                            }
439    
440                            return (java.lang.String)returnObj;
441                    }
442                    catch (com.liferay.portal.kernel.exception.SystemException se) {
443                            _log.error(se, se);
444    
445                            throw se;
446                    }
447            }
448    
449            public static java.lang.String getGroupMessagesRSS(
450                    HttpPrincipal httpPrincipal, long groupId, long userId, int status,
451                    int max, java.lang.String type, double version,
452                    java.lang.String displayStyle, java.lang.String feedURL,
453                    java.lang.String entryURL,
454                    com.liferay.portal.theme.ThemeDisplay themeDisplay)
455                    throws com.liferay.portal.kernel.exception.PortalException,
456                            com.liferay.portal.kernel.exception.SystemException {
457                    try {
458                            MethodKey methodKey = new MethodKey(MBMessageServiceUtil.class.getName(),
459                                            "getGroupMessagesRSS", _getGroupMessagesRSSParameterTypes10);
460    
461                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
462                                            userId, status, max, type, version, displayStyle, feedURL,
463                                            entryURL, themeDisplay);
464    
465                            Object returnObj = null;
466    
467                            try {
468                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
469                            }
470                            catch (Exception e) {
471                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
472                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
473                                    }
474    
475                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
476                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
477                                    }
478    
479                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
480                            }
481    
482                            return (java.lang.String)returnObj;
483                    }
484                    catch (com.liferay.portal.kernel.exception.SystemException se) {
485                            _log.error(se, se);
486    
487                            throw se;
488                    }
489            }
490    
491            public static com.liferay.portlet.messageboards.model.MBMessage getMessage(
492                    HttpPrincipal httpPrincipal, long messageId)
493                    throws com.liferay.portal.kernel.exception.PortalException,
494                            com.liferay.portal.kernel.exception.SystemException {
495                    try {
496                            MethodKey methodKey = new MethodKey(MBMessageServiceUtil.class.getName(),
497                                            "getMessage", _getMessageParameterTypes11);
498    
499                            MethodHandler methodHandler = new MethodHandler(methodKey, messageId);
500    
501                            Object returnObj = null;
502    
503                            try {
504                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
505                            }
506                            catch (Exception e) {
507                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
508                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
509                                    }
510    
511                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
512                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
513                                    }
514    
515                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
516                            }
517    
518                            return (com.liferay.portlet.messageboards.model.MBMessage)returnObj;
519                    }
520                    catch (com.liferay.portal.kernel.exception.SystemException se) {
521                            _log.error(se, se);
522    
523                            throw se;
524                    }
525            }
526    
527            public static com.liferay.portlet.messageboards.model.MBMessageDisplay getMessageDisplay(
528                    HttpPrincipal httpPrincipal, long messageId, int status,
529                    java.lang.String threadView, boolean includePrevAndNext)
530                    throws com.liferay.portal.kernel.exception.PortalException,
531                            com.liferay.portal.kernel.exception.SystemException {
532                    try {
533                            MethodKey methodKey = new MethodKey(MBMessageServiceUtil.class.getName(),
534                                            "getMessageDisplay", _getMessageDisplayParameterTypes12);
535    
536                            MethodHandler methodHandler = new MethodHandler(methodKey,
537                                            messageId, status, threadView, includePrevAndNext);
538    
539                            Object returnObj = null;
540    
541                            try {
542                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
543                            }
544                            catch (Exception e) {
545                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
546                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
547                                    }
548    
549                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
550                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
551                                    }
552    
553                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
554                            }
555    
556                            return (com.liferay.portlet.messageboards.model.MBMessageDisplay)returnObj;
557                    }
558                    catch (com.liferay.portal.kernel.exception.SystemException se) {
559                            _log.error(se, se);
560    
561                            throw se;
562                    }
563            }
564    
565            public static java.util.List<com.liferay.portlet.messageboards.model.MBMessage> getThreadMessages(
566                    HttpPrincipal httpPrincipal, long groupId, long categoryId,
567                    long threadId, int status, int start, int end)
568                    throws com.liferay.portal.kernel.exception.SystemException {
569                    try {
570                            MethodKey methodKey = new MethodKey(MBMessageServiceUtil.class.getName(),
571                                            "getThreadMessages", _getThreadMessagesParameterTypes13);
572    
573                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
574                                            categoryId, threadId, status, start, end);
575    
576                            Object returnObj = null;
577    
578                            try {
579                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
580                            }
581                            catch (Exception e) {
582                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
583                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
584                                    }
585    
586                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
587                            }
588    
589                            return (java.util.List<com.liferay.portlet.messageboards.model.MBMessage>)returnObj;
590                    }
591                    catch (com.liferay.portal.kernel.exception.SystemException se) {
592                            _log.error(se, se);
593    
594                            throw se;
595                    }
596            }
597    
598            public static int getThreadMessagesCount(HttpPrincipal httpPrincipal,
599                    long groupId, long categoryId, long threadId, int status)
600                    throws com.liferay.portal.kernel.exception.SystemException {
601                    try {
602                            MethodKey methodKey = new MethodKey(MBMessageServiceUtil.class.getName(),
603                                            "getThreadMessagesCount",
604                                            _getThreadMessagesCountParameterTypes14);
605    
606                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
607                                            categoryId, threadId, status);
608    
609                            Object returnObj = null;
610    
611                            try {
612                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
613                            }
614                            catch (Exception e) {
615                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
616                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
617                                    }
618    
619                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
620                            }
621    
622                            return ((Integer)returnObj).intValue();
623                    }
624                    catch (com.liferay.portal.kernel.exception.SystemException se) {
625                            _log.error(se, se);
626    
627                            throw se;
628                    }
629            }
630    
631            public static java.lang.String getThreadMessagesRSS(
632                    HttpPrincipal httpPrincipal, long threadId, int status, int max,
633                    java.lang.String type, double version, java.lang.String displayStyle,
634                    java.lang.String feedURL, java.lang.String entryURL,
635                    com.liferay.portal.theme.ThemeDisplay themeDisplay)
636                    throws com.liferay.portal.kernel.exception.PortalException,
637                            com.liferay.portal.kernel.exception.SystemException {
638                    try {
639                            MethodKey methodKey = new MethodKey(MBMessageServiceUtil.class.getName(),
640                                            "getThreadMessagesRSS",
641                                            _getThreadMessagesRSSParameterTypes15);
642    
643                            MethodHandler methodHandler = new MethodHandler(methodKey,
644                                            threadId, status, max, type, version, displayStyle,
645                                            feedURL, entryURL, themeDisplay);
646    
647                            Object returnObj = null;
648    
649                            try {
650                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
651                            }
652                            catch (Exception e) {
653                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
654                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
655                                    }
656    
657                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
658                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
659                                    }
660    
661                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
662                            }
663    
664                            return (java.lang.String)returnObj;
665                    }
666                    catch (com.liferay.portal.kernel.exception.SystemException se) {
667                            _log.error(se, se);
668    
669                            throw se;
670                    }
671            }
672    
673            public static void subscribeMessage(HttpPrincipal httpPrincipal,
674                    long messageId)
675                    throws com.liferay.portal.kernel.exception.PortalException,
676                            com.liferay.portal.kernel.exception.SystemException {
677                    try {
678                            MethodKey methodKey = new MethodKey(MBMessageServiceUtil.class.getName(),
679                                            "subscribeMessage", _subscribeMessageParameterTypes16);
680    
681                            MethodHandler methodHandler = new MethodHandler(methodKey, messageId);
682    
683                            try {
684                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
685                            }
686                            catch (Exception e) {
687                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
688                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
689                                    }
690    
691                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
692                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
693                                    }
694    
695                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
696                            }
697                    }
698                    catch (com.liferay.portal.kernel.exception.SystemException se) {
699                            _log.error(se, se);
700    
701                            throw se;
702                    }
703            }
704    
705            public static void unsubscribeMessage(HttpPrincipal httpPrincipal,
706                    long messageId)
707                    throws com.liferay.portal.kernel.exception.PortalException,
708                            com.liferay.portal.kernel.exception.SystemException {
709                    try {
710                            MethodKey methodKey = new MethodKey(MBMessageServiceUtil.class.getName(),
711                                            "unsubscribeMessage", _unsubscribeMessageParameterTypes17);
712    
713                            MethodHandler methodHandler = new MethodHandler(methodKey, messageId);
714    
715                            try {
716                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
717                            }
718                            catch (Exception e) {
719                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
720                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
721                                    }
722    
723                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
724                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
725                                    }
726    
727                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
728                            }
729                    }
730                    catch (com.liferay.portal.kernel.exception.SystemException se) {
731                            _log.error(se, se);
732    
733                            throw se;
734                    }
735            }
736    
737            public static com.liferay.portlet.messageboards.model.MBMessage updateDiscussionMessage(
738                    HttpPrincipal httpPrincipal, java.lang.String className, long classPK,
739                    java.lang.String permissionClassName, long permissionClassPK,
740                    long messageId, java.lang.String subject, java.lang.String body,
741                    com.liferay.portal.service.ServiceContext serviceContext)
742                    throws com.liferay.portal.kernel.exception.PortalException,
743                            com.liferay.portal.kernel.exception.SystemException {
744                    try {
745                            MethodKey methodKey = new MethodKey(MBMessageServiceUtil.class.getName(),
746                                            "updateDiscussionMessage",
747                                            _updateDiscussionMessageParameterTypes18);
748    
749                            MethodHandler methodHandler = new MethodHandler(methodKey,
750                                            className, classPK, permissionClassName, permissionClassPK,
751                                            messageId, subject, body, serviceContext);
752    
753                            Object returnObj = null;
754    
755                            try {
756                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
757                            }
758                            catch (Exception e) {
759                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
760                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
761                                    }
762    
763                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
764                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
765                                    }
766    
767                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
768                            }
769    
770                            return (com.liferay.portlet.messageboards.model.MBMessage)returnObj;
771                    }
772                    catch (com.liferay.portal.kernel.exception.SystemException se) {
773                            _log.error(se, se);
774    
775                            throw se;
776                    }
777            }
778    
779            public static com.liferay.portlet.messageboards.model.MBMessage updateMessage(
780                    HttpPrincipal httpPrincipal, long messageId, java.lang.String subject,
781                    java.lang.String body,
782                    java.util.List<com.liferay.portal.kernel.util.ObjectValuePair<java.lang.String, byte[]>> files,
783                    java.util.List<java.lang.String> existingFiles, double priority,
784                    boolean allowPingbacks,
785                    com.liferay.portal.service.ServiceContext serviceContext)
786                    throws com.liferay.portal.kernel.exception.PortalException,
787                            com.liferay.portal.kernel.exception.SystemException {
788                    try {
789                            MethodKey methodKey = new MethodKey(MBMessageServiceUtil.class.getName(),
790                                            "updateMessage", _updateMessageParameterTypes19);
791    
792                            MethodHandler methodHandler = new MethodHandler(methodKey,
793                                            messageId, subject, body, files, existingFiles, priority,
794                                            allowPingbacks, serviceContext);
795    
796                            Object returnObj = null;
797    
798                            try {
799                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
800                            }
801                            catch (Exception e) {
802                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
803                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
804                                    }
805    
806                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
807                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
808                                    }
809    
810                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
811                            }
812    
813                            return (com.liferay.portlet.messageboards.model.MBMessage)returnObj;
814                    }
815                    catch (com.liferay.portal.kernel.exception.SystemException se) {
816                            _log.error(se, se);
817    
818                            throw se;
819                    }
820            }
821    
822            private static Log _log = LogFactoryUtil.getLog(MBMessageServiceHttp.class);
823            private static final Class<?>[] _addDiscussionMessageParameterTypes0 = new Class[] {
824                            long.class, java.lang.String.class, long.class,
825                            java.lang.String.class, long.class, long.class, long.class,
826                            java.lang.String.class, java.lang.String.class,
827                            com.liferay.portal.service.ServiceContext.class
828                    };
829            private static final Class<?>[] _addMessageParameterTypes1 = new Class[] {
830                            long.class, long.class, long.class, long.class,
831                            java.lang.String.class, java.lang.String.class, java.util.List.class,
832                            boolean.class, double.class, boolean.class,
833                            com.liferay.portal.service.ServiceContext.class
834                    };
835            private static final Class<?>[] _addMessageParameterTypes2 = new Class[] {
836                            long.class, long.class, java.lang.String.class,
837                            java.lang.String.class, java.util.List.class, boolean.class,
838                            double.class, boolean.class,
839                            com.liferay.portal.service.ServiceContext.class
840                    };
841            private static final Class<?>[] _deleteDiscussionMessageParameterTypes3 = new Class[] {
842                            long.class, java.lang.String.class, long.class,
843                            java.lang.String.class, long.class, long.class
844                    };
845            private static final Class<?>[] _deleteMessageParameterTypes4 = new Class[] {
846                            long.class
847                    };
848            private static final Class<?>[] _getCategoryMessagesParameterTypes5 = new Class[] {
849                            long.class, long.class, int.class, int.class, int.class
850                    };
851            private static final Class<?>[] _getCategoryMessagesCountParameterTypes6 = new Class[] {
852                            long.class, long.class, int.class
853                    };
854            private static final Class<?>[] _getCategoryMessagesRSSParameterTypes7 = new Class[] {
855                            long.class, long.class, int.class, int.class, java.lang.String.class,
856                            double.class, java.lang.String.class, java.lang.String.class,
857                            java.lang.String.class, com.liferay.portal.theme.ThemeDisplay.class
858                    };
859            private static final Class<?>[] _getCompanyMessagesRSSParameterTypes8 = new Class[] {
860                            long.class, int.class, int.class, java.lang.String.class,
861                            double.class, java.lang.String.class, java.lang.String.class,
862                            java.lang.String.class, com.liferay.portal.theme.ThemeDisplay.class
863                    };
864            private static final Class<?>[] _getGroupMessagesRSSParameterTypes9 = new Class[] {
865                            long.class, int.class, int.class, java.lang.String.class,
866                            double.class, java.lang.String.class, java.lang.String.class,
867                            java.lang.String.class, com.liferay.portal.theme.ThemeDisplay.class
868                    };
869            private static final Class<?>[] _getGroupMessagesRSSParameterTypes10 = new Class[] {
870                            long.class, long.class, int.class, int.class, java.lang.String.class,
871                            double.class, java.lang.String.class, java.lang.String.class,
872                            java.lang.String.class, com.liferay.portal.theme.ThemeDisplay.class
873                    };
874            private static final Class<?>[] _getMessageParameterTypes11 = new Class[] {
875                            long.class
876                    };
877            private static final Class<?>[] _getMessageDisplayParameterTypes12 = new Class[] {
878                            long.class, int.class, java.lang.String.class, boolean.class
879                    };
880            private static final Class<?>[] _getThreadMessagesParameterTypes13 = new Class[] {
881                            long.class, long.class, long.class, int.class, int.class, int.class
882                    };
883            private static final Class<?>[] _getThreadMessagesCountParameterTypes14 = new Class[] {
884                            long.class, long.class, long.class, int.class
885                    };
886            private static final Class<?>[] _getThreadMessagesRSSParameterTypes15 = new Class[] {
887                            long.class, int.class, int.class, java.lang.String.class,
888                            double.class, java.lang.String.class, java.lang.String.class,
889                            java.lang.String.class, com.liferay.portal.theme.ThemeDisplay.class
890                    };
891            private static final Class<?>[] _subscribeMessageParameterTypes16 = new Class[] {
892                            long.class
893                    };
894            private static final Class<?>[] _unsubscribeMessageParameterTypes17 = new Class[] {
895                            long.class
896                    };
897            private static final Class<?>[] _updateDiscussionMessageParameterTypes18 = new Class[] {
898                            java.lang.String.class, long.class, java.lang.String.class,
899                            long.class, long.class, java.lang.String.class,
900                            java.lang.String.class,
901                            com.liferay.portal.service.ServiceContext.class
902                    };
903            private static final Class<?>[] _updateMessageParameterTypes19 = new Class[] {
904                            long.class, java.lang.String.class, java.lang.String.class,
905                            java.util.List.class, java.util.List.class, double.class,
906                            boolean.class, com.liferay.portal.service.ServiceContext.class
907                    };
908    }