1
14
15 package com.liferay.portal.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.IntegerWrapper;
21 import com.liferay.portal.kernel.util.LongWrapper;
22 import com.liferay.portal.kernel.util.MethodWrapper;
23 import com.liferay.portal.kernel.util.NullWrapper;
24 import com.liferay.portal.security.auth.HttpPrincipal;
25 import com.liferay.portal.service.GroupServiceUtil;
26
27
64 public class GroupServiceHttp {
65 public static com.liferay.portal.model.Group addGroup(
66 HttpPrincipal httpPrincipal, java.lang.String name,
67 java.lang.String description, int type, java.lang.String friendlyURL,
68 boolean active, com.liferay.portal.service.ServiceContext serviceContext)
69 throws com.liferay.portal.PortalException,
70 com.liferay.portal.SystemException {
71 try {
72 Object paramObj0 = name;
73
74 if (name == null) {
75 paramObj0 = new NullWrapper("java.lang.String");
76 }
77
78 Object paramObj1 = description;
79
80 if (description == null) {
81 paramObj1 = new NullWrapper("java.lang.String");
82 }
83
84 Object paramObj2 = new IntegerWrapper(type);
85
86 Object paramObj3 = friendlyURL;
87
88 if (friendlyURL == null) {
89 paramObj3 = new NullWrapper("java.lang.String");
90 }
91
92 Object paramObj4 = new BooleanWrapper(active);
93
94 Object paramObj5 = serviceContext;
95
96 if (serviceContext == null) {
97 paramObj5 = new NullWrapper(
98 "com.liferay.portal.service.ServiceContext");
99 }
100
101 MethodWrapper methodWrapper = new MethodWrapper(GroupServiceUtil.class.getName(),
102 "addGroup",
103 new Object[] {
104 paramObj0, paramObj1, paramObj2, paramObj3, paramObj4,
105 paramObj5
106 });
107
108 Object returnObj = null;
109
110 try {
111 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
112 }
113 catch (Exception e) {
114 if (e instanceof com.liferay.portal.PortalException) {
115 throw (com.liferay.portal.PortalException)e;
116 }
117
118 if (e instanceof com.liferay.portal.SystemException) {
119 throw (com.liferay.portal.SystemException)e;
120 }
121
122 throw new com.liferay.portal.SystemException(e);
123 }
124
125 return (com.liferay.portal.model.Group)returnObj;
126 }
127 catch (com.liferay.portal.SystemException se) {
128 _log.error(se, se);
129
130 throw se;
131 }
132 }
133
134 public static com.liferay.portal.model.Group addGroup(
135 HttpPrincipal httpPrincipal, long liveGroupId, java.lang.String name,
136 java.lang.String description, int type, java.lang.String friendlyURL,
137 boolean active, com.liferay.portal.service.ServiceContext serviceContext)
138 throws com.liferay.portal.PortalException,
139 com.liferay.portal.SystemException {
140 try {
141 Object paramObj0 = new LongWrapper(liveGroupId);
142
143 Object paramObj1 = name;
144
145 if (name == null) {
146 paramObj1 = new NullWrapper("java.lang.String");
147 }
148
149 Object paramObj2 = description;
150
151 if (description == null) {
152 paramObj2 = new NullWrapper("java.lang.String");
153 }
154
155 Object paramObj3 = new IntegerWrapper(type);
156
157 Object paramObj4 = friendlyURL;
158
159 if (friendlyURL == null) {
160 paramObj4 = new NullWrapper("java.lang.String");
161 }
162
163 Object paramObj5 = new BooleanWrapper(active);
164
165 Object paramObj6 = serviceContext;
166
167 if (serviceContext == null) {
168 paramObj6 = new NullWrapper(
169 "com.liferay.portal.service.ServiceContext");
170 }
171
172 MethodWrapper methodWrapper = new MethodWrapper(GroupServiceUtil.class.getName(),
173 "addGroup",
174 new Object[] {
175 paramObj0, paramObj1, paramObj2, paramObj3, paramObj4,
176 paramObj5, paramObj6
177 });
178
179 Object returnObj = null;
180
181 try {
182 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
183 }
184 catch (Exception e) {
185 if (e instanceof com.liferay.portal.PortalException) {
186 throw (com.liferay.portal.PortalException)e;
187 }
188
189 if (e instanceof com.liferay.portal.SystemException) {
190 throw (com.liferay.portal.SystemException)e;
191 }
192
193 throw new com.liferay.portal.SystemException(e);
194 }
195
196 return (com.liferay.portal.model.Group)returnObj;
197 }
198 catch (com.liferay.portal.SystemException se) {
199 _log.error(se, se);
200
201 throw se;
202 }
203 }
204
205 public static void addRoleGroups(HttpPrincipal httpPrincipal, long roleId,
206 long[] groupIds)
207 throws com.liferay.portal.PortalException,
208 com.liferay.portal.SystemException {
209 try {
210 Object paramObj0 = new LongWrapper(roleId);
211
212 Object paramObj1 = groupIds;
213
214 if (groupIds == null) {
215 paramObj1 = new NullWrapper("[J");
216 }
217
218 MethodWrapper methodWrapper = new MethodWrapper(GroupServiceUtil.class.getName(),
219 "addRoleGroups", new Object[] { paramObj0, paramObj1 });
220
221 try {
222 TunnelUtil.invoke(httpPrincipal, methodWrapper);
223 }
224 catch (Exception e) {
225 if (e instanceof com.liferay.portal.PortalException) {
226 throw (com.liferay.portal.PortalException)e;
227 }
228
229 if (e instanceof com.liferay.portal.SystemException) {
230 throw (com.liferay.portal.SystemException)e;
231 }
232
233 throw new com.liferay.portal.SystemException(e);
234 }
235 }
236 catch (com.liferay.portal.SystemException se) {
237 _log.error(se, se);
238
239 throw se;
240 }
241 }
242
243 public static void deleteGroup(HttpPrincipal httpPrincipal, long groupId)
244 throws com.liferay.portal.PortalException,
245 com.liferay.portal.SystemException {
246 try {
247 Object paramObj0 = new LongWrapper(groupId);
248
249 MethodWrapper methodWrapper = new MethodWrapper(GroupServiceUtil.class.getName(),
250 "deleteGroup", new Object[] { paramObj0 });
251
252 try {
253 TunnelUtil.invoke(httpPrincipal, methodWrapper);
254 }
255 catch (Exception e) {
256 if (e instanceof com.liferay.portal.PortalException) {
257 throw (com.liferay.portal.PortalException)e;
258 }
259
260 if (e instanceof com.liferay.portal.SystemException) {
261 throw (com.liferay.portal.SystemException)e;
262 }
263
264 throw new com.liferay.portal.SystemException(e);
265 }
266 }
267 catch (com.liferay.portal.SystemException se) {
268 _log.error(se, se);
269
270 throw se;
271 }
272 }
273
274 public static com.liferay.portal.model.Group getGroup(
275 HttpPrincipal httpPrincipal, long groupId)
276 throws com.liferay.portal.PortalException,
277 com.liferay.portal.SystemException {
278 try {
279 Object paramObj0 = new LongWrapper(groupId);
280
281 MethodWrapper methodWrapper = new MethodWrapper(GroupServiceUtil.class.getName(),
282 "getGroup", new Object[] { paramObj0 });
283
284 Object returnObj = null;
285
286 try {
287 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
288 }
289 catch (Exception e) {
290 if (e instanceof com.liferay.portal.PortalException) {
291 throw (com.liferay.portal.PortalException)e;
292 }
293
294 if (e instanceof com.liferay.portal.SystemException) {
295 throw (com.liferay.portal.SystemException)e;
296 }
297
298 throw new com.liferay.portal.SystemException(e);
299 }
300
301 return (com.liferay.portal.model.Group)returnObj;
302 }
303 catch (com.liferay.portal.SystemException se) {
304 _log.error(se, se);
305
306 throw se;
307 }
308 }
309
310 public static com.liferay.portal.model.Group getGroup(
311 HttpPrincipal httpPrincipal, long companyId, java.lang.String name)
312 throws com.liferay.portal.PortalException,
313 com.liferay.portal.SystemException {
314 try {
315 Object paramObj0 = new LongWrapper(companyId);
316
317 Object paramObj1 = name;
318
319 if (name == null) {
320 paramObj1 = new NullWrapper("java.lang.String");
321 }
322
323 MethodWrapper methodWrapper = new MethodWrapper(GroupServiceUtil.class.getName(),
324 "getGroup", new Object[] { paramObj0, paramObj1 });
325
326 Object returnObj = null;
327
328 try {
329 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
330 }
331 catch (Exception e) {
332 if (e instanceof com.liferay.portal.PortalException) {
333 throw (com.liferay.portal.PortalException)e;
334 }
335
336 if (e instanceof com.liferay.portal.SystemException) {
337 throw (com.liferay.portal.SystemException)e;
338 }
339
340 throw new com.liferay.portal.SystemException(e);
341 }
342
343 return (com.liferay.portal.model.Group)returnObj;
344 }
345 catch (com.liferay.portal.SystemException se) {
346 _log.error(se, se);
347
348 throw se;
349 }
350 }
351
352 public static java.util.List<com.liferay.portal.model.Group> getManageableGroups(
353 HttpPrincipal httpPrincipal, java.lang.String actionId, int max)
354 throws com.liferay.portal.PortalException,
355 com.liferay.portal.SystemException {
356 try {
357 Object paramObj0 = actionId;
358
359 if (actionId == null) {
360 paramObj0 = new NullWrapper("java.lang.String");
361 }
362
363 Object paramObj1 = new IntegerWrapper(max);
364
365 MethodWrapper methodWrapper = new MethodWrapper(GroupServiceUtil.class.getName(),
366 "getManageableGroups", new Object[] { paramObj0, paramObj1 });
367
368 Object returnObj = null;
369
370 try {
371 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
372 }
373 catch (Exception e) {
374 if (e instanceof com.liferay.portal.PortalException) {
375 throw (com.liferay.portal.PortalException)e;
376 }
377
378 if (e instanceof com.liferay.portal.SystemException) {
379 throw (com.liferay.portal.SystemException)e;
380 }
381
382 throw new com.liferay.portal.SystemException(e);
383 }
384
385 return (java.util.List<com.liferay.portal.model.Group>)returnObj;
386 }
387 catch (com.liferay.portal.SystemException se) {
388 _log.error(se, se);
389
390 throw se;
391 }
392 }
393
394 public static java.util.List<com.liferay.portal.model.Group> getOrganizationsGroups(
395 HttpPrincipal httpPrincipal,
396 java.util.List<com.liferay.portal.model.Organization> organizations)
397 throws com.liferay.portal.SystemException {
398 try {
399 Object paramObj0 = organizations;
400
401 if (organizations == null) {
402 paramObj0 = new NullWrapper("java.util.List");
403 }
404
405 MethodWrapper methodWrapper = new MethodWrapper(GroupServiceUtil.class.getName(),
406 "getOrganizationsGroups", new Object[] { paramObj0 });
407
408 Object returnObj = null;
409
410 try {
411 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
412 }
413 catch (Exception e) {
414 throw new com.liferay.portal.SystemException(e);
415 }
416
417 return (java.util.List<com.liferay.portal.model.Group>)returnObj;
418 }
419 catch (com.liferay.portal.SystemException se) {
420 _log.error(se, se);
421
422 throw se;
423 }
424 }
425
426 public static com.liferay.portal.model.Group getUserGroup(
427 HttpPrincipal httpPrincipal, long companyId, long userId)
428 throws com.liferay.portal.PortalException,
429 com.liferay.portal.SystemException {
430 try {
431 Object paramObj0 = new LongWrapper(companyId);
432
433 Object paramObj1 = new LongWrapper(userId);
434
435 MethodWrapper methodWrapper = new MethodWrapper(GroupServiceUtil.class.getName(),
436 "getUserGroup", new Object[] { paramObj0, paramObj1 });
437
438 Object returnObj = null;
439
440 try {
441 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
442 }
443 catch (Exception e) {
444 if (e instanceof com.liferay.portal.PortalException) {
445 throw (com.liferay.portal.PortalException)e;
446 }
447
448 if (e instanceof com.liferay.portal.SystemException) {
449 throw (com.liferay.portal.SystemException)e;
450 }
451
452 throw new com.liferay.portal.SystemException(e);
453 }
454
455 return (com.liferay.portal.model.Group)returnObj;
456 }
457 catch (com.liferay.portal.SystemException se) {
458 _log.error(se, se);
459
460 throw se;
461 }
462 }
463
464 public static java.util.List<com.liferay.portal.model.Group> getUserGroupsGroups(
465 HttpPrincipal httpPrincipal,
466 java.util.List<com.liferay.portal.model.UserGroup> userGroups)
467 throws com.liferay.portal.SystemException {
468 try {
469 Object paramObj0 = userGroups;
470
471 if (userGroups == null) {
472 paramObj0 = new NullWrapper("java.util.List");
473 }
474
475 MethodWrapper methodWrapper = new MethodWrapper(GroupServiceUtil.class.getName(),
476 "getUserGroupsGroups", new Object[] { paramObj0 });
477
478 Object returnObj = null;
479
480 try {
481 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
482 }
483 catch (Exception e) {
484 throw new com.liferay.portal.SystemException(e);
485 }
486
487 return (java.util.List<com.liferay.portal.model.Group>)returnObj;
488 }
489 catch (com.liferay.portal.SystemException se) {
490 _log.error(se, se);
491
492 throw se;
493 }
494 }
495
496 public static java.util.List<com.liferay.portal.model.Group> getUserOrganizationsGroups(
497 HttpPrincipal httpPrincipal, long userId, int start, int end)
498 throws com.liferay.portal.PortalException,
499 com.liferay.portal.SystemException {
500 try {
501 Object paramObj0 = new LongWrapper(userId);
502
503 Object paramObj1 = new IntegerWrapper(start);
504
505 Object paramObj2 = new IntegerWrapper(end);
506
507 MethodWrapper methodWrapper = new MethodWrapper(GroupServiceUtil.class.getName(),
508 "getUserOrganizationsGroups",
509 new Object[] { paramObj0, paramObj1, paramObj2 });
510
511 Object returnObj = null;
512
513 try {
514 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
515 }
516 catch (Exception e) {
517 if (e instanceof com.liferay.portal.PortalException) {
518 throw (com.liferay.portal.PortalException)e;
519 }
520
521 if (e instanceof com.liferay.portal.SystemException) {
522 throw (com.liferay.portal.SystemException)e;
523 }
524
525 throw new com.liferay.portal.SystemException(e);
526 }
527
528 return (java.util.List<com.liferay.portal.model.Group>)returnObj;
529 }
530 catch (com.liferay.portal.SystemException se) {
531 _log.error(se, se);
532
533 throw se;
534 }
535 }
536
537 public static boolean hasUserGroup(HttpPrincipal httpPrincipal,
538 long userId, long groupId) throws com.liferay.portal.SystemException {
539 try {
540 Object paramObj0 = new LongWrapper(userId);
541
542 Object paramObj1 = new LongWrapper(groupId);
543
544 MethodWrapper methodWrapper = new MethodWrapper(GroupServiceUtil.class.getName(),
545 "hasUserGroup", new Object[] { paramObj0, paramObj1 });
546
547 Object returnObj = null;
548
549 try {
550 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
551 }
552 catch (Exception e) {
553 if (e instanceof com.liferay.portal.SystemException) {
554 throw (com.liferay.portal.SystemException)e;
555 }
556
557 throw new com.liferay.portal.SystemException(e);
558 }
559
560 return ((Boolean)returnObj).booleanValue();
561 }
562 catch (com.liferay.portal.SystemException se) {
563 _log.error(se, se);
564
565 throw se;
566 }
567 }
568
569 public static java.util.List<com.liferay.portal.model.Group> search(
570 HttpPrincipal httpPrincipal, long companyId, java.lang.String name,
571 java.lang.String description, java.lang.String[] params, int start,
572 int end) throws com.liferay.portal.SystemException {
573 try {
574 Object paramObj0 = new LongWrapper(companyId);
575
576 Object paramObj1 = name;
577
578 if (name == null) {
579 paramObj1 = new NullWrapper("java.lang.String");
580 }
581
582 Object paramObj2 = description;
583
584 if (description == null) {
585 paramObj2 = new NullWrapper("java.lang.String");
586 }
587
588 Object paramObj3 = params;
589
590 if (params == null) {
591 paramObj3 = new NullWrapper("[Ljava.lang.String;");
592 }
593
594 Object paramObj4 = new IntegerWrapper(start);
595
596 Object paramObj5 = new IntegerWrapper(end);
597
598 MethodWrapper methodWrapper = new MethodWrapper(GroupServiceUtil.class.getName(),
599 "search",
600 new Object[] {
601 paramObj0, paramObj1, paramObj2, paramObj3, paramObj4,
602 paramObj5
603 });
604
605 Object returnObj = null;
606
607 try {
608 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
609 }
610 catch (Exception e) {
611 if (e instanceof com.liferay.portal.SystemException) {
612 throw (com.liferay.portal.SystemException)e;
613 }
614
615 throw new com.liferay.portal.SystemException(e);
616 }
617
618 return (java.util.List<com.liferay.portal.model.Group>)returnObj;
619 }
620 catch (com.liferay.portal.SystemException se) {
621 _log.error(se, se);
622
623 throw se;
624 }
625 }
626
627 public static int searchCount(HttpPrincipal httpPrincipal, long companyId,
628 java.lang.String name, java.lang.String description,
629 java.lang.String[] params) throws com.liferay.portal.SystemException {
630 try {
631 Object paramObj0 = new LongWrapper(companyId);
632
633 Object paramObj1 = name;
634
635 if (name == null) {
636 paramObj1 = new NullWrapper("java.lang.String");
637 }
638
639 Object paramObj2 = description;
640
641 if (description == null) {
642 paramObj2 = new NullWrapper("java.lang.String");
643 }
644
645 Object paramObj3 = params;
646
647 if (params == null) {
648 paramObj3 = new NullWrapper("[Ljava.lang.String;");
649 }
650
651 MethodWrapper methodWrapper = new MethodWrapper(GroupServiceUtil.class.getName(),
652 "searchCount",
653 new Object[] { paramObj0, paramObj1, paramObj2, paramObj3 });
654
655 Object returnObj = null;
656
657 try {
658 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
659 }
660 catch (Exception e) {
661 if (e instanceof com.liferay.portal.SystemException) {
662 throw (com.liferay.portal.SystemException)e;
663 }
664
665 throw new com.liferay.portal.SystemException(e);
666 }
667
668 return ((Integer)returnObj).intValue();
669 }
670 catch (com.liferay.portal.SystemException se) {
671 _log.error(se, se);
672
673 throw se;
674 }
675 }
676
677 public static void setRoleGroups(HttpPrincipal httpPrincipal, long roleId,
678 long[] groupIds)
679 throws com.liferay.portal.PortalException,
680 com.liferay.portal.SystemException {
681 try {
682 Object paramObj0 = new LongWrapper(roleId);
683
684 Object paramObj1 = groupIds;
685
686 if (groupIds == null) {
687 paramObj1 = new NullWrapper("[J");
688 }
689
690 MethodWrapper methodWrapper = new MethodWrapper(GroupServiceUtil.class.getName(),
691 "setRoleGroups", new Object[] { paramObj0, paramObj1 });
692
693 try {
694 TunnelUtil.invoke(httpPrincipal, methodWrapper);
695 }
696 catch (Exception e) {
697 if (e instanceof com.liferay.portal.PortalException) {
698 throw (com.liferay.portal.PortalException)e;
699 }
700
701 if (e instanceof com.liferay.portal.SystemException) {
702 throw (com.liferay.portal.SystemException)e;
703 }
704
705 throw new com.liferay.portal.SystemException(e);
706 }
707 }
708 catch (com.liferay.portal.SystemException se) {
709 _log.error(se, se);
710
711 throw se;
712 }
713 }
714
715 public static void unsetRoleGroups(HttpPrincipal httpPrincipal,
716 long roleId, long[] groupIds)
717 throws com.liferay.portal.PortalException,
718 com.liferay.portal.SystemException {
719 try {
720 Object paramObj0 = new LongWrapper(roleId);
721
722 Object paramObj1 = groupIds;
723
724 if (groupIds == null) {
725 paramObj1 = new NullWrapper("[J");
726 }
727
728 MethodWrapper methodWrapper = new MethodWrapper(GroupServiceUtil.class.getName(),
729 "unsetRoleGroups", new Object[] { paramObj0, paramObj1 });
730
731 try {
732 TunnelUtil.invoke(httpPrincipal, methodWrapper);
733 }
734 catch (Exception e) {
735 if (e instanceof com.liferay.portal.PortalException) {
736 throw (com.liferay.portal.PortalException)e;
737 }
738
739 if (e instanceof com.liferay.portal.SystemException) {
740 throw (com.liferay.portal.SystemException)e;
741 }
742
743 throw new com.liferay.portal.SystemException(e);
744 }
745 }
746 catch (com.liferay.portal.SystemException se) {
747 _log.error(se, se);
748
749 throw se;
750 }
751 }
752
753 public static com.liferay.portal.model.Group updateFriendlyURL(
754 HttpPrincipal httpPrincipal, long groupId, java.lang.String friendlyURL)
755 throws com.liferay.portal.PortalException,
756 com.liferay.portal.SystemException {
757 try {
758 Object paramObj0 = new LongWrapper(groupId);
759
760 Object paramObj1 = friendlyURL;
761
762 if (friendlyURL == null) {
763 paramObj1 = new NullWrapper("java.lang.String");
764 }
765
766 MethodWrapper methodWrapper = new MethodWrapper(GroupServiceUtil.class.getName(),
767 "updateFriendlyURL", new Object[] { paramObj0, paramObj1 });
768
769 Object returnObj = null;
770
771 try {
772 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
773 }
774 catch (Exception e) {
775 if (e instanceof com.liferay.portal.PortalException) {
776 throw (com.liferay.portal.PortalException)e;
777 }
778
779 if (e instanceof com.liferay.portal.SystemException) {
780 throw (com.liferay.portal.SystemException)e;
781 }
782
783 throw new com.liferay.portal.SystemException(e);
784 }
785
786 return (com.liferay.portal.model.Group)returnObj;
787 }
788 catch (com.liferay.portal.SystemException se) {
789 _log.error(se, se);
790
791 throw se;
792 }
793 }
794
795 public static com.liferay.portal.model.Group updateGroup(
796 HttpPrincipal httpPrincipal, long groupId, java.lang.String name,
797 java.lang.String description, int type, java.lang.String friendlyURL,
798 boolean active, com.liferay.portal.service.ServiceContext serviceContext)
799 throws com.liferay.portal.PortalException,
800 com.liferay.portal.SystemException {
801 try {
802 Object paramObj0 = new LongWrapper(groupId);
803
804 Object paramObj1 = name;
805
806 if (name == null) {
807 paramObj1 = new NullWrapper("java.lang.String");
808 }
809
810 Object paramObj2 = description;
811
812 if (description == null) {
813 paramObj2 = new NullWrapper("java.lang.String");
814 }
815
816 Object paramObj3 = new IntegerWrapper(type);
817
818 Object paramObj4 = friendlyURL;
819
820 if (friendlyURL == null) {
821 paramObj4 = new NullWrapper("java.lang.String");
822 }
823
824 Object paramObj5 = new BooleanWrapper(active);
825
826 Object paramObj6 = serviceContext;
827
828 if (serviceContext == null) {
829 paramObj6 = new NullWrapper(
830 "com.liferay.portal.service.ServiceContext");
831 }
832
833 MethodWrapper methodWrapper = new MethodWrapper(GroupServiceUtil.class.getName(),
834 "updateGroup",
835 new Object[] {
836 paramObj0, paramObj1, paramObj2, paramObj3, paramObj4,
837 paramObj5, paramObj6
838 });
839
840 Object returnObj = null;
841
842 try {
843 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
844 }
845 catch (Exception e) {
846 if (e instanceof com.liferay.portal.PortalException) {
847 throw (com.liferay.portal.PortalException)e;
848 }
849
850 if (e instanceof com.liferay.portal.SystemException) {
851 throw (com.liferay.portal.SystemException)e;
852 }
853
854 throw new com.liferay.portal.SystemException(e);
855 }
856
857 return (com.liferay.portal.model.Group)returnObj;
858 }
859 catch (com.liferay.portal.SystemException se) {
860 _log.error(se, se);
861
862 throw se;
863 }
864 }
865
866 public static com.liferay.portal.model.Group updateGroup(
867 HttpPrincipal httpPrincipal, long groupId, java.lang.String typeSettings)
868 throws com.liferay.portal.PortalException,
869 com.liferay.portal.SystemException {
870 try {
871 Object paramObj0 = new LongWrapper(groupId);
872
873 Object paramObj1 = typeSettings;
874
875 if (typeSettings == null) {
876 paramObj1 = new NullWrapper("java.lang.String");
877 }
878
879 MethodWrapper methodWrapper = new MethodWrapper(GroupServiceUtil.class.getName(),
880 "updateGroup", new Object[] { paramObj0, paramObj1 });
881
882 Object returnObj = null;
883
884 try {
885 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
886 }
887 catch (Exception e) {
888 if (e instanceof com.liferay.portal.PortalException) {
889 throw (com.liferay.portal.PortalException)e;
890 }
891
892 if (e instanceof com.liferay.portal.SystemException) {
893 throw (com.liferay.portal.SystemException)e;
894 }
895
896 throw new com.liferay.portal.SystemException(e);
897 }
898
899 return (com.liferay.portal.model.Group)returnObj;
900 }
901 catch (com.liferay.portal.SystemException se) {
902 _log.error(se, se);
903
904 throw se;
905 }
906 }
907
908 public static com.liferay.portal.model.Group updateWorkflow(
909 HttpPrincipal httpPrincipal, long groupId, boolean workflowEnabled,
910 int workflowStages, java.lang.String workflowRoleNames)
911 throws com.liferay.portal.PortalException,
912 com.liferay.portal.SystemException {
913 try {
914 Object paramObj0 = new LongWrapper(groupId);
915
916 Object paramObj1 = new BooleanWrapper(workflowEnabled);
917
918 Object paramObj2 = new IntegerWrapper(workflowStages);
919
920 Object paramObj3 = workflowRoleNames;
921
922 if (workflowRoleNames == null) {
923 paramObj3 = new NullWrapper("java.lang.String");
924 }
925
926 MethodWrapper methodWrapper = new MethodWrapper(GroupServiceUtil.class.getName(),
927 "updateWorkflow",
928 new Object[] { paramObj0, paramObj1, paramObj2, paramObj3 });
929
930 Object returnObj = null;
931
932 try {
933 returnObj = TunnelUtil.invoke(httpPrincipal, methodWrapper);
934 }
935 catch (Exception e) {
936 if (e instanceof com.liferay.portal.PortalException) {
937 throw (com.liferay.portal.PortalException)e;
938 }
939
940 if (e instanceof com.liferay.portal.SystemException) {
941 throw (com.liferay.portal.SystemException)e;
942 }
943
944 throw new com.liferay.portal.SystemException(e);
945 }
946
947 return (com.liferay.portal.model.Group)returnObj;
948 }
949 catch (com.liferay.portal.SystemException se) {
950 _log.error(se, se);
951
952 throw se;
953 }
954 }
955
956 private static Log _log = LogFactoryUtil.getLog(GroupServiceHttp.class);
957 }