1   /**
2    * Copyright (c) 2000-2010 Liferay, Inc. All rights reserved.
3    *
4    * This library is free software; you can redistribute it and/or modify it under
5    * the terms of the GNU Lesser General Public License as published by the Free
6    * Software Foundation; either version 2.1 of the License, or (at your option)
7    * any later version.
8    *
9    * This library is distributed in the hope that it will be useful, but WITHOUT
10   * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
11   * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
12   * details.
13   */
14  
15  package com.liferay.portlet.journal.service.http;
16  
17  import com.liferay.portal.kernel.log.Log;
18  import com.liferay.portal.kernel.log.LogFactoryUtil;
19  import com.liferay.portal.kernel.util.BooleanWrapper;
20  import com.liferay.portal.kernel.util.DoubleWrapper;
21  import com.liferay.portal.kernel.util.IntegerWrapper;
22  import com.liferay.portal.kernel.util.LongWrapper;
23  import com.liferay.portal.kernel.util.MethodWrapper;
24  import com.liferay.portal.kernel.util.NullWrapper;
25  import com.liferay.portal.security.auth.HttpPrincipal;
26  import com.liferay.portal.service.http.TunnelUtil;
27  
28  import com.liferay.portlet.journal.service.JournalArticleServiceUtil;
29  
30  /**
31   * <a href="JournalArticleServiceHttp.java.html"><b><i>View Source</i></b></a>
32   *
33   * <p>
34   * ServiceBuilder generated this class. Modifications in this class will be
35   * overwritten the next time is generated.
36   * </p>
37   *
38   * <p>
39   * This class provides a HTTP utility for the
40   * {@link com.liferay.portlet.journal.service.JournalArticleServiceUtil} service utility. The
41   * static methods of this class calls the same methods of the service utility.
42   * However, the signatures are different because it requires an additional
43   * {@link com.liferay.portal.security.auth.HttpPrincipal} parameter.
44   * </p>
45   *
46   * <p>
47   * The benefits of using the HTTP utility is that it is fast and allows for
48   * tunneling without the cost of serializing to text. The drawback is that it
49   * only works with Java.
50   * </p>
51   *
52   * <p>
53   * Set the property <b>tunnel.servlet.hosts.allowed</b> in portal.properties to
54   * configure security.
55   * </p>
56   *
57   * <p>
58   * The HTTP utility is only generated for remote services.
59   * </p>
60   *
61   * @author    Brian Wing Shun Chan
62   * @see       JournalArticleServiceSoap
63   * @see       com.liferay.portal.security.auth.HttpPrincipal
64   * @see       com.liferay.portlet.journal.service.JournalArticleServiceUtil
65   * @generated
66   */
67  public class JournalArticleServiceHttp {
68      public static com.liferay.portlet.journal.model.JournalArticle addArticle(
69          HttpPrincipal httpPrincipal, long groupId, java.lang.String articleId,
70          boolean autoArticleId, java.lang.String title,
71          java.lang.String description, java.lang.String content,
72          java.lang.String type, java.lang.String structureId,
73          java.lang.String templateId, int displayDateMonth, int displayDateDay,
74          int displayDateYear, int displayDateHour, int displayDateMinute,
75          int expirationDateMonth, int expirationDateDay, int expirationDateYear,
76          int expirationDateHour, int expirationDateMinute, boolean neverExpire,
77          int reviewDateMonth, int reviewDateDay, int reviewDateYear,
78          int reviewDateHour, int reviewDateMinute, boolean neverReview,
79          boolean indexable, boolean smallImage, java.lang.String smallImageURL,
80          java.io.File smallFile, java.util.Map<String, byte[]> images,
81          java.lang.String articleURL,
82          com.liferay.portal.service.ServiceContext serviceContext)
83          throws com.liferay.portal.kernel.exception.PortalException,
84              com.liferay.portal.kernel.exception.SystemException {
85          try {
86              Object paramObj0 = new LongWrapper(groupId);
87  
88              Object paramObj1 = articleId;
89  
90              if (articleId == null) {
91                  paramObj1 = new NullWrapper("java.lang.String");
92              }
93  
94              Object paramObj2 = new BooleanWrapper(autoArticleId);
95  
96              Object paramObj3 = title;
97  
98              if (title == null) {
99                  paramObj3 = new NullWrapper("java.lang.String");
100             }
101 
102             Object paramObj4 = description;
103 
104             if (description == null) {
105                 paramObj4 = new NullWrapper("java.lang.String");
106             }
107 
108             Object paramObj5 = content;
109 
110             if (content == null) {
111                 paramObj5 = new NullWrapper("java.lang.String");
112             }
113 
114             Object paramObj6 = type;
115 
116             if (type == null) {
117                 paramObj6 = new NullWrapper("java.lang.String");
118             }
119 
120             Object paramObj7 = structureId;
121 
122             if (structureId == null) {
123                 paramObj7 = new NullWrapper("java.lang.String");
124             }
125 
126             Object paramObj8 = templateId;
127 
128             if (templateId == null) {
129                 paramObj8 = new NullWrapper("java.lang.String");
130             }
131 
132             Object paramObj9 = new IntegerWrapper(displayDateMonth);
133 
134             Object paramObj10 = new IntegerWrapper(displayDateDay);
135 
136             Object paramObj11 = new IntegerWrapper(displayDateYear);
137 
138             Object paramObj12 = new IntegerWrapper(displayDateHour);
139 
140             Object paramObj13 = new IntegerWrapper(displayDateMinute);
141 
142             Object paramObj14 = new IntegerWrapper(expirationDateMonth);
143 
144             Object paramObj15 = new IntegerWrapper(expirationDateDay);
145 
146             Object paramObj16 = new IntegerWrapper(expirationDateYear);
147 
148             Object paramObj17 = new IntegerWrapper(expirationDateHour);
149 
150             Object paramObj18 = new IntegerWrapper(expirationDateMinute);
151 
152             Object paramObj19 = new BooleanWrapper(neverExpire);
153 
154             Object paramObj20 = new IntegerWrapper(reviewDateMonth);
155 
156             Object paramObj21 = new IntegerWrapper(reviewDateDay);
157 
158             Object paramObj22 = new IntegerWrapper(reviewDateYear);
159 
160             Object paramObj23 = new IntegerWrapper(reviewDateHour);
161 
162             Object paramObj24 = new IntegerWrapper(reviewDateMinute);
163 
164             Object paramObj25 = new BooleanWrapper(neverReview);
165 
166             Object paramObj26 = new BooleanWrapper(indexable);
167 
168             Object paramObj27 = new BooleanWrapper(smallImage);
169 
170             Object paramObj28 = smallImageURL;
171 
172             if (smallImageURL == null) {
173                 paramObj28 = new NullWrapper("java.lang.String");
174             }
175 
176             Object paramObj29 = smallFile;
177 
178             if (smallFile == null) {
179                 paramObj29 = new NullWrapper("java.io.File");
180             }
181 
182             Object paramObj30 = images;
183 
184             if (images == null) {
185                 paramObj30 = new NullWrapper("java.util.Map");
186             }
187 
188             Object paramObj31 = articleURL;
189 
190             if (articleURL == null) {
191                 paramObj31 = new NullWrapper("java.lang.String");
192             }
193 
194             Object paramObj32 = serviceContext;
195 
196             if (serviceContext == null) {
197                 paramObj32 = new NullWrapper(
198                         "com.liferay.portal.service.ServiceContext");
199             }
200 
201             MethodWrapper methodWrapper = new MethodWrapper(JournalArticleServiceUtil.class.getName(),
202                     "addArticle",
203                     new Object[] {
204                         paramObj0, paramObj1, paramObj2, paramObj3, paramObj4,
205                         paramObj5, paramObj6, paramObj7, paramObj8, paramObj9,
206                         paramObj10, paramObj11, paramObj12, paramObj13,
207                         paramObj14, paramObj15, paramObj16, paramObj17,
208                         paramObj18, paramObj19, paramObj20, paramObj21,
209                         paramObj22, paramObj23, paramObj24, paramObj25,
210                         paramObj26, paramObj27, paramObj28, paramObj29,
211                         paramObj30, paramObj31, paramObj32
212                     });
213 
214             Object returnObj = null;
215 
216             try {
217                 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
218             }
219             catch (Exception e) {
220                 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
221                     throw (com.liferay.portal.kernel.exception.PortalException)e;
222                 }
223 
224                 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
225                     throw (com.liferay.portal.kernel.exception.SystemException)e;
226                 }
227 
228                 throw new com.liferay.portal.kernel.exception.SystemException(e);
229             }
230 
231             return (com.liferay.portlet.journal.model.JournalArticle)returnObj;
232         }
233         catch (com.liferay.portal.kernel.exception.SystemException se) {
234             _log.error(se, se);
235 
236             throw se;
237         }
238     }
239 
240     public static com.liferay.portlet.journal.model.JournalArticle addArticle(
241         HttpPrincipal httpPrincipal, long groupId, java.lang.String articleId,
242         boolean autoArticleId, java.lang.String title,
243         java.lang.String description, java.lang.String content,
244         java.lang.String type, java.lang.String structureId,
245         java.lang.String templateId, int displayDateMonth, int displayDateDay,
246         int displayDateYear, int displayDateHour, int displayDateMinute,
247         int expirationDateMonth, int expirationDateDay, int expirationDateYear,
248         int expirationDateHour, int expirationDateMinute, boolean neverExpire,
249         int reviewDateMonth, int reviewDateDay, int reviewDateYear,
250         int reviewDateHour, int reviewDateMinute, boolean neverReview,
251         boolean indexable, java.lang.String articleURL,
252         com.liferay.portal.service.ServiceContext serviceContext)
253         throws com.liferay.portal.kernel.exception.PortalException,
254             com.liferay.portal.kernel.exception.SystemException {
255         try {
256             Object paramObj0 = new LongWrapper(groupId);
257 
258             Object paramObj1 = articleId;
259 
260             if (articleId == null) {
261                 paramObj1 = new NullWrapper("java.lang.String");
262             }
263 
264             Object paramObj2 = new BooleanWrapper(autoArticleId);
265 
266             Object paramObj3 = title;
267 
268             if (title == null) {
269                 paramObj3 = new NullWrapper("java.lang.String");
270             }
271 
272             Object paramObj4 = description;
273 
274             if (description == null) {
275                 paramObj4 = new NullWrapper("java.lang.String");
276             }
277 
278             Object paramObj5 = content;
279 
280             if (content == null) {
281                 paramObj5 = new NullWrapper("java.lang.String");
282             }
283 
284             Object paramObj6 = type;
285 
286             if (type == null) {
287                 paramObj6 = new NullWrapper("java.lang.String");
288             }
289 
290             Object paramObj7 = structureId;
291 
292             if (structureId == null) {
293                 paramObj7 = new NullWrapper("java.lang.String");
294             }
295 
296             Object paramObj8 = templateId;
297 
298             if (templateId == null) {
299                 paramObj8 = new NullWrapper("java.lang.String");
300             }
301 
302             Object paramObj9 = new IntegerWrapper(displayDateMonth);
303 
304             Object paramObj10 = new IntegerWrapper(displayDateDay);
305 
306             Object paramObj11 = new IntegerWrapper(displayDateYear);
307 
308             Object paramObj12 = new IntegerWrapper(displayDateHour);
309 
310             Object paramObj13 = new IntegerWrapper(displayDateMinute);
311 
312             Object paramObj14 = new IntegerWrapper(expirationDateMonth);
313 
314             Object paramObj15 = new IntegerWrapper(expirationDateDay);
315 
316             Object paramObj16 = new IntegerWrapper(expirationDateYear);
317 
318             Object paramObj17 = new IntegerWrapper(expirationDateHour);
319 
320             Object paramObj18 = new IntegerWrapper(expirationDateMinute);
321 
322             Object paramObj19 = new BooleanWrapper(neverExpire);
323 
324             Object paramObj20 = new IntegerWrapper(reviewDateMonth);
325 
326             Object paramObj21 = new IntegerWrapper(reviewDateDay);
327 
328             Object paramObj22 = new IntegerWrapper(reviewDateYear);
329 
330             Object paramObj23 = new IntegerWrapper(reviewDateHour);
331 
332             Object paramObj24 = new IntegerWrapper(reviewDateMinute);
333 
334             Object paramObj25 = new BooleanWrapper(neverReview);
335 
336             Object paramObj26 = new BooleanWrapper(indexable);
337 
338             Object paramObj27 = articleURL;
339 
340             if (articleURL == null) {
341                 paramObj27 = new NullWrapper("java.lang.String");
342             }
343 
344             Object paramObj28 = serviceContext;
345 
346             if (serviceContext == null) {
347                 paramObj28 = new NullWrapper(
348                         "com.liferay.portal.service.ServiceContext");
349             }
350 
351             MethodWrapper methodWrapper = new MethodWrapper(JournalArticleServiceUtil.class.getName(),
352                     "addArticle",
353                     new Object[] {
354                         paramObj0, paramObj1, paramObj2, paramObj3, paramObj4,
355                         paramObj5, paramObj6, paramObj7, paramObj8, paramObj9,
356                         paramObj10, paramObj11, paramObj12, paramObj13,
357                         paramObj14, paramObj15, paramObj16, paramObj17,
358                         paramObj18, paramObj19, paramObj20, paramObj21,
359                         paramObj22, paramObj23, paramObj24, paramObj25,
360                         paramObj26, paramObj27, paramObj28
361                     });
362 
363             Object returnObj = null;
364 
365             try {
366                 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
367             }
368             catch (Exception e) {
369                 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
370                     throw (com.liferay.portal.kernel.exception.PortalException)e;
371                 }
372 
373                 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
374                     throw (com.liferay.portal.kernel.exception.SystemException)e;
375                 }
376 
377                 throw new com.liferay.portal.kernel.exception.SystemException(e);
378             }
379 
380             return (com.liferay.portlet.journal.model.JournalArticle)returnObj;
381         }
382         catch (com.liferay.portal.kernel.exception.SystemException se) {
383             _log.error(se, se);
384 
385             throw se;
386         }
387     }
388 
389     public static com.liferay.portlet.journal.model.JournalArticle copyArticle(
390         HttpPrincipal httpPrincipal, long groupId,
391         java.lang.String oldArticleId, java.lang.String newArticleId,
392         boolean autoArticleId, double version)
393         throws com.liferay.portal.kernel.exception.PortalException,
394             com.liferay.portal.kernel.exception.SystemException {
395         try {
396             Object paramObj0 = new LongWrapper(groupId);
397 
398             Object paramObj1 = oldArticleId;
399 
400             if (oldArticleId == null) {
401                 paramObj1 = new NullWrapper("java.lang.String");
402             }
403 
404             Object paramObj2 = newArticleId;
405 
406             if (newArticleId == null) {
407                 paramObj2 = new NullWrapper("java.lang.String");
408             }
409 
410             Object paramObj3 = new BooleanWrapper(autoArticleId);
411 
412             Object paramObj4 = new DoubleWrapper(version);
413 
414             MethodWrapper methodWrapper = new MethodWrapper(JournalArticleServiceUtil.class.getName(),
415                     "copyArticle",
416                     new Object[] {
417                         paramObj0, paramObj1, paramObj2, paramObj3, paramObj4
418                     });
419 
420             Object returnObj = null;
421 
422             try {
423                 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
424             }
425             catch (Exception e) {
426                 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
427                     throw (com.liferay.portal.kernel.exception.PortalException)e;
428                 }
429 
430                 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
431                     throw (com.liferay.portal.kernel.exception.SystemException)e;
432                 }
433 
434                 throw new com.liferay.portal.kernel.exception.SystemException(e);
435             }
436 
437             return (com.liferay.portlet.journal.model.JournalArticle)returnObj;
438         }
439         catch (com.liferay.portal.kernel.exception.SystemException se) {
440             _log.error(se, se);
441 
442             throw se;
443         }
444     }
445 
446     public static void deleteArticle(HttpPrincipal httpPrincipal, long groupId,
447         java.lang.String articleId, double version,
448         java.lang.String articleURL,
449         com.liferay.portal.service.ServiceContext serviceContext)
450         throws com.liferay.portal.kernel.exception.PortalException,
451             com.liferay.portal.kernel.exception.SystemException {
452         try {
453             Object paramObj0 = new LongWrapper(groupId);
454 
455             Object paramObj1 = articleId;
456 
457             if (articleId == null) {
458                 paramObj1 = new NullWrapper("java.lang.String");
459             }
460 
461             Object paramObj2 = new DoubleWrapper(version);
462 
463             Object paramObj3 = articleURL;
464 
465             if (articleURL == null) {
466                 paramObj3 = new NullWrapper("java.lang.String");
467             }
468 
469             Object paramObj4 = serviceContext;
470 
471             if (serviceContext == null) {
472                 paramObj4 = new NullWrapper(
473                         "com.liferay.portal.service.ServiceContext");
474             }
475 
476             MethodWrapper methodWrapper = new MethodWrapper(JournalArticleServiceUtil.class.getName(),
477                     "deleteArticle",
478                     new Object[] {
479                         paramObj0, paramObj1, paramObj2, paramObj3, paramObj4
480                     });
481 
482             try {
483                 TunnelUtil.invoke(httpPrincipal, methodWrapper);
484             }
485             catch (Exception e) {
486                 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
487                     throw (com.liferay.portal.kernel.exception.PortalException)e;
488                 }
489 
490                 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
491                     throw (com.liferay.portal.kernel.exception.SystemException)e;
492                 }
493 
494                 throw new com.liferay.portal.kernel.exception.SystemException(e);
495             }
496         }
497         catch (com.liferay.portal.kernel.exception.SystemException se) {
498             _log.error(se, se);
499 
500             throw se;
501         }
502     }
503 
504     public static com.liferay.portlet.journal.model.JournalArticle getArticle(
505         HttpPrincipal httpPrincipal, long groupId, java.lang.String articleId)
506         throws com.liferay.portal.kernel.exception.PortalException,
507             com.liferay.portal.kernel.exception.SystemException {
508         try {
509             Object paramObj0 = new LongWrapper(groupId);
510 
511             Object paramObj1 = articleId;
512 
513             if (articleId == null) {
514                 paramObj1 = new NullWrapper("java.lang.String");
515             }
516 
517             MethodWrapper methodWrapper = new MethodWrapper(JournalArticleServiceUtil.class.getName(),
518                     "getArticle", new Object[] { paramObj0, paramObj1 });
519 
520             Object returnObj = null;
521 
522             try {
523                 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
524             }
525             catch (Exception e) {
526                 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
527                     throw (com.liferay.portal.kernel.exception.PortalException)e;
528                 }
529 
530                 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
531                     throw (com.liferay.portal.kernel.exception.SystemException)e;
532                 }
533 
534                 throw new com.liferay.portal.kernel.exception.SystemException(e);
535             }
536 
537             return (com.liferay.portlet.journal.model.JournalArticle)returnObj;
538         }
539         catch (com.liferay.portal.kernel.exception.SystemException se) {
540             _log.error(se, se);
541 
542             throw se;
543         }
544     }
545 
546     public static com.liferay.portlet.journal.model.JournalArticle getArticle(
547         HttpPrincipal httpPrincipal, long groupId, java.lang.String articleId,
548         double version)
549         throws com.liferay.portal.kernel.exception.PortalException,
550             com.liferay.portal.kernel.exception.SystemException {
551         try {
552             Object paramObj0 = new LongWrapper(groupId);
553 
554             Object paramObj1 = articleId;
555 
556             if (articleId == null) {
557                 paramObj1 = new NullWrapper("java.lang.String");
558             }
559 
560             Object paramObj2 = new DoubleWrapper(version);
561 
562             MethodWrapper methodWrapper = new MethodWrapper(JournalArticleServiceUtil.class.getName(),
563                     "getArticle",
564                     new Object[] { paramObj0, paramObj1, paramObj2 });
565 
566             Object returnObj = null;
567 
568             try {
569                 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
570             }
571             catch (Exception e) {
572                 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
573                     throw (com.liferay.portal.kernel.exception.PortalException)e;
574                 }
575 
576                 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
577                     throw (com.liferay.portal.kernel.exception.SystemException)e;
578                 }
579 
580                 throw new com.liferay.portal.kernel.exception.SystemException(e);
581             }
582 
583             return (com.liferay.portlet.journal.model.JournalArticle)returnObj;
584         }
585         catch (com.liferay.portal.kernel.exception.SystemException se) {
586             _log.error(se, se);
587 
588             throw se;
589         }
590     }
591 
592     public static com.liferay.portlet.journal.model.JournalArticle getArticleByUrlTitle(
593         HttpPrincipal httpPrincipal, long groupId, java.lang.String urlTitle)
594         throws com.liferay.portal.kernel.exception.PortalException,
595             com.liferay.portal.kernel.exception.SystemException {
596         try {
597             Object paramObj0 = new LongWrapper(groupId);
598 
599             Object paramObj1 = urlTitle;
600 
601             if (urlTitle == null) {
602                 paramObj1 = new NullWrapper("java.lang.String");
603             }
604 
605             MethodWrapper methodWrapper = new MethodWrapper(JournalArticleServiceUtil.class.getName(),
606                     "getArticleByUrlTitle",
607                     new Object[] { paramObj0, paramObj1 });
608 
609             Object returnObj = null;
610 
611             try {
612                 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
613             }
614             catch (Exception e) {
615                 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
616                     throw (com.liferay.portal.kernel.exception.PortalException)e;
617                 }
618 
619                 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
620                     throw (com.liferay.portal.kernel.exception.SystemException)e;
621                 }
622 
623                 throw new com.liferay.portal.kernel.exception.SystemException(e);
624             }
625 
626             return (com.liferay.portlet.journal.model.JournalArticle)returnObj;
627         }
628         catch (com.liferay.portal.kernel.exception.SystemException se) {
629             _log.error(se, se);
630 
631             throw se;
632         }
633     }
634 
635     public static java.lang.String getArticleContent(
636         HttpPrincipal httpPrincipal, long groupId, java.lang.String articleId,
637         double version, java.lang.String languageId,
638         com.liferay.portal.theme.ThemeDisplay themeDisplay)
639         throws com.liferay.portal.kernel.exception.PortalException,
640             com.liferay.portal.kernel.exception.SystemException {
641         try {
642             Object paramObj0 = new LongWrapper(groupId);
643 
644             Object paramObj1 = articleId;
645 
646             if (articleId == null) {
647                 paramObj1 = new NullWrapper("java.lang.String");
648             }
649 
650             Object paramObj2 = new DoubleWrapper(version);
651 
652             Object paramObj3 = languageId;
653 
654             if (languageId == null) {
655                 paramObj3 = new NullWrapper("java.lang.String");
656             }
657 
658             Object paramObj4 = themeDisplay;
659 
660             if (themeDisplay == null) {
661                 paramObj4 = new NullWrapper(
662                         "com.liferay.portal.theme.ThemeDisplay");
663             }
664 
665             MethodWrapper methodWrapper = new MethodWrapper(JournalArticleServiceUtil.class.getName(),
666                     "getArticleContent",
667                     new Object[] {
668                         paramObj0, paramObj1, paramObj2, paramObj3, paramObj4
669                     });
670 
671             Object returnObj = null;
672 
673             try {
674                 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
675             }
676             catch (Exception e) {
677                 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
678                     throw (com.liferay.portal.kernel.exception.PortalException)e;
679                 }
680 
681                 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
682                     throw (com.liferay.portal.kernel.exception.SystemException)e;
683                 }
684 
685                 throw new com.liferay.portal.kernel.exception.SystemException(e);
686             }
687 
688             return (java.lang.String)returnObj;
689         }
690         catch (com.liferay.portal.kernel.exception.SystemException se) {
691             _log.error(se, se);
692 
693             throw se;
694         }
695     }
696 
697     public static java.lang.String getArticleContent(
698         HttpPrincipal httpPrincipal, long groupId, java.lang.String articleId,
699         java.lang.String languageId,
700         com.liferay.portal.theme.ThemeDisplay themeDisplay)
701         throws com.liferay.portal.kernel.exception.PortalException,
702             com.liferay.portal.kernel.exception.SystemException {
703         try {
704             Object paramObj0 = new LongWrapper(groupId);
705 
706             Object paramObj1 = articleId;
707 
708             if (articleId == null) {
709                 paramObj1 = new NullWrapper("java.lang.String");
710             }
711 
712             Object paramObj2 = languageId;
713 
714             if (languageId == null) {
715                 paramObj2 = new NullWrapper("java.lang.String");
716             }
717 
718             Object paramObj3 = themeDisplay;
719 
720             if (themeDisplay == null) {
721                 paramObj3 = new NullWrapper(
722                         "com.liferay.portal.theme.ThemeDisplay");
723             }
724 
725             MethodWrapper methodWrapper = new MethodWrapper(JournalArticleServiceUtil.class.getName(),
726                     "getArticleContent",
727                     new Object[] { paramObj0, paramObj1, paramObj2, paramObj3 });
728 
729             Object returnObj = null;
730 
731             try {
732                 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
733             }
734             catch (Exception e) {
735                 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
736                     throw (com.liferay.portal.kernel.exception.PortalException)e;
737                 }
738 
739                 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
740                     throw (com.liferay.portal.kernel.exception.SystemException)e;
741                 }
742 
743                 throw new com.liferay.portal.kernel.exception.SystemException(e);
744             }
745 
746             return (java.lang.String)returnObj;
747         }
748         catch (com.liferay.portal.kernel.exception.SystemException se) {
749             _log.error(se, se);
750 
751             throw se;
752         }
753     }
754 
755     public static void removeArticleLocale(HttpPrincipal httpPrincipal,
756         long companyId, java.lang.String languageId)
757         throws com.liferay.portal.kernel.exception.PortalException,
758             com.liferay.portal.kernel.exception.SystemException {
759         try {
760             Object paramObj0 = new LongWrapper(companyId);
761 
762             Object paramObj1 = languageId;
763 
764             if (languageId == null) {
765                 paramObj1 = new NullWrapper("java.lang.String");
766             }
767 
768             MethodWrapper methodWrapper = new MethodWrapper(JournalArticleServiceUtil.class.getName(),
769                     "removeArticleLocale", new Object[] { paramObj0, paramObj1 });
770 
771             try {
772                 TunnelUtil.invoke(httpPrincipal, methodWrapper);
773             }
774             catch (Exception e) {
775                 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
776                     throw (com.liferay.portal.kernel.exception.PortalException)e;
777                 }
778 
779                 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
780                     throw (com.liferay.portal.kernel.exception.SystemException)e;
781                 }
782 
783                 throw new com.liferay.portal.kernel.exception.SystemException(e);
784             }
785         }
786         catch (com.liferay.portal.kernel.exception.SystemException se) {
787             _log.error(se, se);
788 
789             throw se;
790         }
791     }
792 
793     public static com.liferay.portlet.journal.model.JournalArticle removeArticleLocale(
794         HttpPrincipal httpPrincipal, long groupId, java.lang.String articleId,
795         double version, java.lang.String languageId)
796         throws com.liferay.portal.kernel.exception.PortalException,
797             com.liferay.portal.kernel.exception.SystemException {
798         try {
799             Object paramObj0 = new LongWrapper(groupId);
800 
801             Object paramObj1 = articleId;
802 
803             if (articleId == null) {
804                 paramObj1 = new NullWrapper("java.lang.String");
805             }
806 
807             Object paramObj2 = new DoubleWrapper(version);
808 
809             Object paramObj3 = languageId;
810 
811             if (languageId == null) {
812                 paramObj3 = new NullWrapper("java.lang.String");
813             }
814 
815             MethodWrapper methodWrapper = new MethodWrapper(JournalArticleServiceUtil.class.getName(),
816                     "removeArticleLocale",
817                     new Object[] { paramObj0, paramObj1, paramObj2, paramObj3 });
818 
819             Object returnObj = null;
820 
821             try {
822                 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
823             }
824             catch (Exception e) {
825                 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
826                     throw (com.liferay.portal.kernel.exception.PortalException)e;
827                 }
828 
829                 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
830                     throw (com.liferay.portal.kernel.exception.SystemException)e;
831                 }
832 
833                 throw new com.liferay.portal.kernel.exception.SystemException(e);
834             }
835 
836             return (com.liferay.portlet.journal.model.JournalArticle)returnObj;
837         }
838         catch (com.liferay.portal.kernel.exception.SystemException se) {
839             _log.error(se, se);
840 
841             throw se;
842         }
843     }
844 
845     public static com.liferay.portlet.journal.model.JournalArticle updateArticle(
846         HttpPrincipal httpPrincipal, long groupId, java.lang.String articleId,
847         double version, boolean incrementVersion, java.lang.String content)
848         throws com.liferay.portal.kernel.exception.PortalException,
849             com.liferay.portal.kernel.exception.SystemException {
850         try {
851             Object paramObj0 = new LongWrapper(groupId);
852 
853             Object paramObj1 = articleId;
854 
855             if (articleId == null) {
856                 paramObj1 = new NullWrapper("java.lang.String");
857             }
858 
859             Object paramObj2 = new DoubleWrapper(version);
860 
861             Object paramObj3 = new BooleanWrapper(incrementVersion);
862 
863             Object paramObj4 = content;
864 
865             if (content == null) {
866                 paramObj4 = new NullWrapper("java.lang.String");
867             }
868 
869             MethodWrapper methodWrapper = new MethodWrapper(JournalArticleServiceUtil.class.getName(),
870                     "updateArticle",
871                     new Object[] {
872                         paramObj0, paramObj1, paramObj2, paramObj3, paramObj4
873                     });
874 
875             Object returnObj = null;
876 
877             try {
878                 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
879             }
880             catch (Exception e) {
881                 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
882                     throw (com.liferay.portal.kernel.exception.PortalException)e;
883                 }
884 
885                 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
886                     throw (com.liferay.portal.kernel.exception.SystemException)e;
887                 }
888 
889                 throw new com.liferay.portal.kernel.exception.SystemException(e);
890             }
891 
892             return (com.liferay.portlet.journal.model.JournalArticle)returnObj;
893         }
894         catch (com.liferay.portal.kernel.exception.SystemException se) {
895             _log.error(se, se);
896 
897             throw se;
898         }
899     }
900 
901     public static com.liferay.portlet.journal.model.JournalArticle updateArticle(
902         HttpPrincipal httpPrincipal, long groupId, java.lang.String articleId,
903         double version, boolean incrementVersion, java.lang.String title,
904         java.lang.String description, java.lang.String content,
905         java.lang.String type, java.lang.String structureId,
906         java.lang.String templateId, int displayDateMonth, int displayDateDay,
907         int displayDateYear, int displayDateHour, int displayDateMinute,
908         int expirationDateMonth, int expirationDateDay, int expirationDateYear,
909         int expirationDateHour, int expirationDateMinute, boolean neverExpire,
910         int reviewDateMonth, int reviewDateDay, int reviewDateYear,
911         int reviewDateHour, int reviewDateMinute, boolean neverReview,
912         boolean indexable, boolean smallImage, java.lang.String smallImageURL,
913         java.io.File smallFile, java.util.Map<String, byte[]> images,
914         java.lang.String articleURL,
915         com.liferay.portal.service.ServiceContext serviceContext)
916         throws com.liferay.portal.kernel.exception.PortalException,
917             com.liferay.portal.kernel.exception.SystemException {
918         try {
919             Object paramObj0 = new LongWrapper(groupId);
920 
921             Object paramObj1 = articleId;
922 
923             if (articleId == null) {
924                 paramObj1 = new NullWrapper("java.lang.String");
925             }
926 
927             Object paramObj2 = new DoubleWrapper(version);
928 
929             Object paramObj3 = new BooleanWrapper(incrementVersion);
930 
931             Object paramObj4 = title;
932 
933             if (title == null) {
934                 paramObj4 = new NullWrapper("java.lang.String");
935             }
936 
937             Object paramObj5 = description;
938 
939             if (description == null) {
940                 paramObj5 = new NullWrapper("java.lang.String");
941             }
942 
943             Object paramObj6 = content;
944 
945             if (content == null) {
946                 paramObj6 = new NullWrapper("java.lang.String");
947             }
948 
949             Object paramObj7 = type;
950 
951             if (type == null) {
952                 paramObj7 = new NullWrapper("java.lang.String");
953             }
954 
955             Object paramObj8 = structureId;
956 
957             if (structureId == null) {
958                 paramObj8 = new NullWrapper("java.lang.String");
959             }
960 
961             Object paramObj9 = templateId;
962 
963             if (templateId == null) {
964                 paramObj9 = new NullWrapper("java.lang.String");
965             }
966 
967             Object paramObj10 = new IntegerWrapper(displayDateMonth);
968 
969             Object paramObj11 = new IntegerWrapper(displayDateDay);
970 
971             Object paramObj12 = new IntegerWrapper(displayDateYear);
972 
973             Object paramObj13 = new IntegerWrapper(displayDateHour);
974 
975             Object paramObj14 = new IntegerWrapper(displayDateMinute);
976 
977             Object paramObj15 = new IntegerWrapper(expirationDateMonth);
978 
979             Object paramObj16 = new IntegerWrapper(expirationDateDay);
980 
981             Object paramObj17 = new IntegerWrapper(expirationDateYear);
982 
983             Object paramObj18 = new IntegerWrapper(expirationDateHour);
984 
985             Object paramObj19 = new IntegerWrapper(expirationDateMinute);
986 
987             Object paramObj20 = new BooleanWrapper(neverExpire);
988 
989             Object paramObj21 = new IntegerWrapper(reviewDateMonth);
990 
991             Object paramObj22 = new IntegerWrapper(reviewDateDay);
992 
993             Object paramObj23 = new IntegerWrapper(reviewDateYear);
994 
995             Object paramObj24 = new IntegerWrapper(reviewDateHour);
996 
997             Object paramObj25 = new IntegerWrapper(reviewDateMinute);
998 
999             Object paramObj26 = new BooleanWrapper(neverReview);
1000
1001            Object paramObj27 = new BooleanWrapper(indexable);
1002
1003            Object paramObj28 = new BooleanWrapper(smallImage);
1004
1005            Object paramObj29 = smallImageURL;
1006
1007            if (smallImageURL == null) {
1008                paramObj29 = new NullWrapper("java.lang.String");
1009            }
1010
1011            Object paramObj30 = smallFile;
1012
1013            if (smallFile == null) {
1014                paramObj30 = new NullWrapper("java.io.File");
1015            }
1016
1017            Object paramObj31 = images;
1018
1019            if (images == null) {
1020                paramObj31 = new NullWrapper("java.util.Map");
1021            }
1022
1023            Object paramObj32 = articleURL;
1024
1025            if (articleURL == null) {
1026                paramObj32 = new NullWrapper("java.lang.String");
1027            }
1028
1029            Object paramObj33 = serviceContext;
1030
1031            if (serviceContext == null) {
1032                paramObj33 = new NullWrapper(
1033                        "com.liferay.portal.service.ServiceContext");
1034            }
1035
1036            MethodWrapper methodWrapper = new MethodWrapper(JournalArticleServiceUtil.class.getName(),
1037                    "updateArticle",
1038                    new Object[] {
1039                        paramObj0, paramObj1, paramObj2, paramObj3, paramObj4,
1040                        paramObj5, paramObj6, paramObj7, paramObj8, paramObj9,
1041                        paramObj10, paramObj11, paramObj12, paramObj13,
1042                        paramObj14, paramObj15, paramObj16, paramObj17,
1043                        paramObj18, paramObj19, paramObj20, paramObj21,
1044                        paramObj22, paramObj23, paramObj24, paramObj25,
1045                        paramObj26, paramObj27, paramObj28, paramObj29,
1046                        paramObj30, paramObj31, paramObj32, paramObj33
1047                    });
1048
1049            Object returnObj = null;
1050
1051            try {
1052                returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
1053            }
1054            catch (Exception e) {
1055                if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1056                    throw (com.liferay.portal.kernel.exception.PortalException)e;
1057                }
1058
1059                if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1060                    throw (com.liferay.portal.kernel.exception.SystemException)e;
1061                }
1062
1063                throw new com.liferay.portal.kernel.exception.SystemException(e);
1064            }
1065
1066            return (com.liferay.portlet.journal.model.JournalArticle)returnObj;
1067        }
1068        catch (com.liferay.portal.kernel.exception.SystemException se) {
1069            _log.error(se, se);
1070
1071            throw se;
1072        }
1073    }
1074
1075    public static com.liferay.portlet.journal.model.JournalArticle updateContent(
1076        HttpPrincipal httpPrincipal, long groupId, java.lang.String articleId,
1077        double version, java.lang.String content)
1078        throws com.liferay.portal.kernel.exception.PortalException,
1079            com.liferay.portal.kernel.exception.SystemException {
1080        try {
1081            Object paramObj0 = new LongWrapper(groupId);
1082
1083            Object paramObj1 = articleId;
1084
1085            if (articleId == null) {
1086                paramObj1 = new NullWrapper("java.lang.String");
1087            }
1088
1089            Object paramObj2 = new DoubleWrapper(version);
1090
1091            Object paramObj3 = content;
1092
1093            if (content == null) {
1094                paramObj3 = new NullWrapper("java.lang.String");
1095            }
1096
1097            MethodWrapper methodWrapper = new MethodWrapper(JournalArticleServiceUtil.class.getName(),
1098                    "updateContent",
1099                    new Object[] { paramObj0, paramObj1, paramObj2, paramObj3 });
1100
1101            Object returnObj = null;
1102
1103            try {
1104                returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
1105            }
1106            catch (Exception e) {
1107                if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1108                    throw (com.liferay.portal.kernel.exception.PortalException)e;
1109                }
1110
1111                if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1112                    throw (com.liferay.portal.kernel.exception.SystemException)e;
1113                }
1114
1115                throw new com.liferay.portal.kernel.exception.SystemException(e);
1116            }
1117
1118            return (com.liferay.portlet.journal.model.JournalArticle)returnObj;
1119        }
1120        catch (com.liferay.portal.kernel.exception.SystemException se) {
1121            _log.error(se, se);
1122
1123            throw se;
1124        }
1125    }
1126
1127    public static com.liferay.portlet.journal.model.JournalArticle updateStatus(
1128        HttpPrincipal httpPrincipal, long groupId, java.lang.String articleId,
1129        double version, int status, java.lang.String articleURL,
1130        com.liferay.portal.service.ServiceContext serviceContext)
1131        throws com.liferay.portal.kernel.exception.PortalException,
1132            com.liferay.portal.kernel.exception.SystemException {
1133        try {
1134            Object paramObj0 = new LongWrapper(groupId);
1135
1136            Object paramObj1 = articleId;
1137
1138            if (articleId == null) {
1139                paramObj1 = new NullWrapper("java.lang.String");
1140            }
1141
1142            Object paramObj2 = new DoubleWrapper(version);
1143
1144            Object paramObj3 = new IntegerWrapper(status);
1145
1146            Object paramObj4 = articleURL;
1147
1148            if (articleURL == null) {
1149                paramObj4 = new NullWrapper("java.lang.String");
1150            }
1151
1152            Object paramObj5 = serviceContext;
1153
1154            if (serviceContext == null) {
1155                paramObj5 = new NullWrapper(
1156                        "com.liferay.portal.service.ServiceContext");
1157            }
1158
1159            MethodWrapper methodWrapper = new MethodWrapper(JournalArticleServiceUtil.class.getName(),
1160                    "updateStatus",
1161                    new Object[] {
1162                        paramObj0, paramObj1, paramObj2, paramObj3, paramObj4,
1163                        paramObj5
1164                    });
1165
1166            Object returnObj = null;
1167
1168            try {
1169                returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
1170            }
1171            catch (Exception e) {
1172                if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1173                    throw (com.liferay.portal.kernel.exception.PortalException)e;
1174                }
1175
1176                if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1177                    throw (com.liferay.portal.kernel.exception.SystemException)e;
1178                }
1179
1180                throw new com.liferay.portal.kernel.exception.SystemException(e);
1181            }
1182
1183            return (com.liferay.portlet.journal.model.JournalArticle)returnObj;
1184        }
1185        catch (com.liferay.portal.kernel.exception.SystemException se) {
1186            _log.error(se, se);
1187
1188            throw se;
1189        }
1190    }
1191
1192    private static Log _log = LogFactoryUtil.getLog(JournalArticleServiceHttp.class);
1193}