001
014
015 package com.liferay.portal.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.GroupServiceUtil;
023
024
054 public class GroupServiceHttp {
055 public static com.liferay.portal.model.Group addGroup(
056 HttpPrincipal httpPrincipal, long parentGroupId, long liveGroupId,
057 java.lang.String name, java.lang.String description, int type,
058 java.lang.String friendlyURL, boolean site, boolean active,
059 com.liferay.portal.service.ServiceContext serviceContext)
060 throws com.liferay.portal.kernel.exception.PortalException,
061 com.liferay.portal.kernel.exception.SystemException {
062 try {
063 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
064 "addGroup", _addGroupParameterTypes0);
065
066 MethodHandler methodHandler = new MethodHandler(methodKey,
067 parentGroupId, liveGroupId, name, description, type,
068 friendlyURL, site, active, serviceContext);
069
070 Object returnObj = null;
071
072 try {
073 returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
074 }
075 catch (Exception e) {
076 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
077 throw (com.liferay.portal.kernel.exception.PortalException)e;
078 }
079
080 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
081 throw (com.liferay.portal.kernel.exception.SystemException)e;
082 }
083
084 throw new com.liferay.portal.kernel.exception.SystemException(e);
085 }
086
087 return (com.liferay.portal.model.Group)returnObj;
088 }
089 catch (com.liferay.portal.kernel.exception.SystemException se) {
090 _log.error(se, se);
091
092 throw se;
093 }
094 }
095
096 public static com.liferay.portal.model.Group addGroup(
097 HttpPrincipal httpPrincipal, long parentGroupId, java.lang.String name,
098 java.lang.String description, int type, java.lang.String friendlyURL,
099 boolean site, boolean active,
100 com.liferay.portal.service.ServiceContext serviceContext)
101 throws com.liferay.portal.kernel.exception.PortalException,
102 com.liferay.portal.kernel.exception.SystemException {
103 try {
104 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
105 "addGroup", _addGroupParameterTypes1);
106
107 MethodHandler methodHandler = new MethodHandler(methodKey,
108 parentGroupId, name, description, type, friendlyURL, site,
109 active, serviceContext);
110
111 Object returnObj = null;
112
113 try {
114 returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
115 }
116 catch (Exception e) {
117 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
118 throw (com.liferay.portal.kernel.exception.PortalException)e;
119 }
120
121 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
122 throw (com.liferay.portal.kernel.exception.SystemException)e;
123 }
124
125 throw new com.liferay.portal.kernel.exception.SystemException(e);
126 }
127
128 return (com.liferay.portal.model.Group)returnObj;
129 }
130 catch (com.liferay.portal.kernel.exception.SystemException se) {
131 _log.error(se, se);
132
133 throw se;
134 }
135 }
136
137 public static com.liferay.portal.model.Group addGroup(
138 HttpPrincipal httpPrincipal, java.lang.String name,
139 java.lang.String description, int type, java.lang.String friendlyURL,
140 boolean site, boolean active,
141 com.liferay.portal.service.ServiceContext serviceContext)
142 throws com.liferay.portal.kernel.exception.PortalException,
143 com.liferay.portal.kernel.exception.SystemException {
144 try {
145 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
146 "addGroup", _addGroupParameterTypes2);
147
148 MethodHandler methodHandler = new MethodHandler(methodKey, name,
149 description, type, friendlyURL, site, active, serviceContext);
150
151 Object returnObj = null;
152
153 try {
154 returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
155 }
156 catch (Exception e) {
157 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
158 throw (com.liferay.portal.kernel.exception.PortalException)e;
159 }
160
161 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
162 throw (com.liferay.portal.kernel.exception.SystemException)e;
163 }
164
165 throw new com.liferay.portal.kernel.exception.SystemException(e);
166 }
167
168 return (com.liferay.portal.model.Group)returnObj;
169 }
170 catch (com.liferay.portal.kernel.exception.SystemException se) {
171 _log.error(se, se);
172
173 throw se;
174 }
175 }
176
177 public static void addRoleGroups(HttpPrincipal httpPrincipal, long roleId,
178 long[] groupIds)
179 throws com.liferay.portal.kernel.exception.PortalException,
180 com.liferay.portal.kernel.exception.SystemException {
181 try {
182 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
183 "addRoleGroups", _addRoleGroupsParameterTypes3);
184
185 MethodHandler methodHandler = new MethodHandler(methodKey, roleId,
186 groupIds);
187
188 try {
189 TunnelUtil.invoke(httpPrincipal, methodHandler);
190 }
191 catch (Exception e) {
192 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
193 throw (com.liferay.portal.kernel.exception.PortalException)e;
194 }
195
196 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
197 throw (com.liferay.portal.kernel.exception.SystemException)e;
198 }
199
200 throw new com.liferay.portal.kernel.exception.SystemException(e);
201 }
202 }
203 catch (com.liferay.portal.kernel.exception.SystemException se) {
204 _log.error(se, se);
205
206 throw se;
207 }
208 }
209
210 public static void deleteGroup(HttpPrincipal httpPrincipal, long groupId)
211 throws com.liferay.portal.kernel.exception.PortalException,
212 com.liferay.portal.kernel.exception.SystemException {
213 try {
214 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
215 "deleteGroup", _deleteGroupParameterTypes4);
216
217 MethodHandler methodHandler = new MethodHandler(methodKey, groupId);
218
219 try {
220 TunnelUtil.invoke(httpPrincipal, methodHandler);
221 }
222 catch (Exception e) {
223 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
224 throw (com.liferay.portal.kernel.exception.PortalException)e;
225 }
226
227 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
228 throw (com.liferay.portal.kernel.exception.SystemException)e;
229 }
230
231 throw new com.liferay.portal.kernel.exception.SystemException(e);
232 }
233 }
234 catch (com.liferay.portal.kernel.exception.SystemException se) {
235 _log.error(se, se);
236
237 throw se;
238 }
239 }
240
241 public static com.liferay.portal.model.Group getGroup(
242 HttpPrincipal httpPrincipal, long groupId)
243 throws com.liferay.portal.kernel.exception.PortalException,
244 com.liferay.portal.kernel.exception.SystemException {
245 try {
246 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
247 "getGroup", _getGroupParameterTypes5);
248
249 MethodHandler methodHandler = new MethodHandler(methodKey, groupId);
250
251 Object returnObj = null;
252
253 try {
254 returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
255 }
256 catch (Exception e) {
257 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
258 throw (com.liferay.portal.kernel.exception.PortalException)e;
259 }
260
261 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
262 throw (com.liferay.portal.kernel.exception.SystemException)e;
263 }
264
265 throw new com.liferay.portal.kernel.exception.SystemException(e);
266 }
267
268 return (com.liferay.portal.model.Group)returnObj;
269 }
270 catch (com.liferay.portal.kernel.exception.SystemException se) {
271 _log.error(se, se);
272
273 throw se;
274 }
275 }
276
277 public static com.liferay.portal.model.Group getGroup(
278 HttpPrincipal httpPrincipal, long companyId, java.lang.String name)
279 throws com.liferay.portal.kernel.exception.PortalException,
280 com.liferay.portal.kernel.exception.SystemException {
281 try {
282 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
283 "getGroup", _getGroupParameterTypes6);
284
285 MethodHandler methodHandler = new MethodHandler(methodKey,
286 companyId, name);
287
288 Object returnObj = null;
289
290 try {
291 returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
292 }
293 catch (Exception e) {
294 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
295 throw (com.liferay.portal.kernel.exception.PortalException)e;
296 }
297
298 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
299 throw (com.liferay.portal.kernel.exception.SystemException)e;
300 }
301
302 throw new com.liferay.portal.kernel.exception.SystemException(e);
303 }
304
305 return (com.liferay.portal.model.Group)returnObj;
306 }
307 catch (com.liferay.portal.kernel.exception.SystemException se) {
308 _log.error(se, se);
309
310 throw se;
311 }
312 }
313
314 public static java.util.List<com.liferay.portal.model.Group> getManageableSites(
315 HttpPrincipal httpPrincipal,
316 java.util.Collection<com.liferay.portal.model.Portlet> portlets, int max)
317 throws com.liferay.portal.kernel.exception.PortalException,
318 com.liferay.portal.kernel.exception.SystemException {
319 try {
320 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
321 "getManageableSites", _getManageableSitesParameterTypes7);
322
323 MethodHandler methodHandler = new MethodHandler(methodKey,
324 portlets, max);
325
326 Object returnObj = null;
327
328 try {
329 returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
330 }
331 catch (Exception e) {
332 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
333 throw (com.liferay.portal.kernel.exception.PortalException)e;
334 }
335
336 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
337 throw (com.liferay.portal.kernel.exception.SystemException)e;
338 }
339
340 throw new com.liferay.portal.kernel.exception.SystemException(e);
341 }
342
343 return (java.util.List<com.liferay.portal.model.Group>)returnObj;
344 }
345 catch (com.liferay.portal.kernel.exception.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> getOrganizationsGroups(
353 HttpPrincipal httpPrincipal,
354 java.util.List<com.liferay.portal.model.Organization> organizations)
355 throws com.liferay.portal.kernel.exception.PortalException,
356 com.liferay.portal.kernel.exception.SystemException {
357 try {
358 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
359 "getOrganizationsGroups",
360 _getOrganizationsGroupsParameterTypes8);
361
362 MethodHandler methodHandler = new MethodHandler(methodKey,
363 organizations);
364
365 Object returnObj = null;
366
367 try {
368 returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
369 }
370 catch (Exception e) {
371 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
372 throw (com.liferay.portal.kernel.exception.PortalException)e;
373 }
374
375 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
376 throw (com.liferay.portal.kernel.exception.SystemException)e;
377 }
378
379 throw new com.liferay.portal.kernel.exception.SystemException(e);
380 }
381
382 return (java.util.List<com.liferay.portal.model.Group>)returnObj;
383 }
384 catch (com.liferay.portal.kernel.exception.SystemException se) {
385 _log.error(se, se);
386
387 throw se;
388 }
389 }
390
391 public static com.liferay.portal.model.Group getUserGroup(
392 HttpPrincipal httpPrincipal, long companyId, long userId)
393 throws com.liferay.portal.kernel.exception.PortalException,
394 com.liferay.portal.kernel.exception.SystemException {
395 try {
396 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
397 "getUserGroup", _getUserGroupParameterTypes9);
398
399 MethodHandler methodHandler = new MethodHandler(methodKey,
400 companyId, userId);
401
402 Object returnObj = null;
403
404 try {
405 returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
406 }
407 catch (Exception e) {
408 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
409 throw (com.liferay.portal.kernel.exception.PortalException)e;
410 }
411
412 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
413 throw (com.liferay.portal.kernel.exception.SystemException)e;
414 }
415
416 throw new com.liferay.portal.kernel.exception.SystemException(e);
417 }
418
419 return (com.liferay.portal.model.Group)returnObj;
420 }
421 catch (com.liferay.portal.kernel.exception.SystemException se) {
422 _log.error(se, se);
423
424 throw se;
425 }
426 }
427
428 public static java.util.List<com.liferay.portal.model.Group> getUserGroupsGroups(
429 HttpPrincipal httpPrincipal,
430 java.util.List<com.liferay.portal.model.UserGroup> userGroups)
431 throws com.liferay.portal.kernel.exception.PortalException,
432 com.liferay.portal.kernel.exception.SystemException {
433 try {
434 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
435 "getUserGroupsGroups", _getUserGroupsGroupsParameterTypes10);
436
437 MethodHandler methodHandler = new MethodHandler(methodKey,
438 userGroups);
439
440 Object returnObj = null;
441
442 try {
443 returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
444 }
445 catch (Exception e) {
446 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
447 throw (com.liferay.portal.kernel.exception.PortalException)e;
448 }
449
450 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
451 throw (com.liferay.portal.kernel.exception.SystemException)e;
452 }
453
454 throw new com.liferay.portal.kernel.exception.SystemException(e);
455 }
456
457 return (java.util.List<com.liferay.portal.model.Group>)returnObj;
458 }
459 catch (com.liferay.portal.kernel.exception.SystemException se) {
460 _log.error(se, se);
461
462 throw se;
463 }
464 }
465
466 public static java.util.List<com.liferay.portal.model.Group> getUserOrganizationsGroups(
467 HttpPrincipal httpPrincipal, long userId, int start, int end)
468 throws com.liferay.portal.kernel.exception.PortalException,
469 com.liferay.portal.kernel.exception.SystemException {
470 try {
471 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
472 "getUserOrganizationsGroups",
473 _getUserOrganizationsGroupsParameterTypes11);
474
475 MethodHandler methodHandler = new MethodHandler(methodKey, userId,
476 start, end);
477
478 Object returnObj = null;
479
480 try {
481 returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
482 }
483 catch (Exception e) {
484 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
485 throw (com.liferay.portal.kernel.exception.PortalException)e;
486 }
487
488 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
489 throw (com.liferay.portal.kernel.exception.SystemException)e;
490 }
491
492 throw new com.liferay.portal.kernel.exception.SystemException(e);
493 }
494
495 return (java.util.List<com.liferay.portal.model.Group>)returnObj;
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 java.util.List<com.liferay.portal.model.Group> getUserPlaces(
505 HttpPrincipal httpPrincipal, long userId,
506 java.lang.String[] classNames, boolean includeControlPanel, int max)
507 throws com.liferay.portal.kernel.exception.PortalException,
508 com.liferay.portal.kernel.exception.SystemException {
509 try {
510 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
511 "getUserPlaces", _getUserPlacesParameterTypes12);
512
513 MethodHandler methodHandler = new MethodHandler(methodKey, userId,
514 classNames, includeControlPanel, max);
515
516 Object returnObj = null;
517
518 try {
519 returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
520 }
521 catch (Exception e) {
522 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
523 throw (com.liferay.portal.kernel.exception.PortalException)e;
524 }
525
526 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
527 throw (com.liferay.portal.kernel.exception.SystemException)e;
528 }
529
530 throw new com.liferay.portal.kernel.exception.SystemException(e);
531 }
532
533 return (java.util.List<com.liferay.portal.model.Group>)returnObj;
534 }
535 catch (com.liferay.portal.kernel.exception.SystemException se) {
536 _log.error(se, se);
537
538 throw se;
539 }
540 }
541
542 public static java.util.List<com.liferay.portal.model.Group> getUserPlaces(
543 HttpPrincipal httpPrincipal, long userId,
544 java.lang.String[] classNames, int max)
545 throws com.liferay.portal.kernel.exception.PortalException,
546 com.liferay.portal.kernel.exception.SystemException {
547 try {
548 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
549 "getUserPlaces", _getUserPlacesParameterTypes13);
550
551 MethodHandler methodHandler = new MethodHandler(methodKey, userId,
552 classNames, max);
553
554 Object returnObj = null;
555
556 try {
557 returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
558 }
559 catch (Exception e) {
560 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
561 throw (com.liferay.portal.kernel.exception.PortalException)e;
562 }
563
564 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
565 throw (com.liferay.portal.kernel.exception.SystemException)e;
566 }
567
568 throw new com.liferay.portal.kernel.exception.SystemException(e);
569 }
570
571 return (java.util.List<com.liferay.portal.model.Group>)returnObj;
572 }
573 catch (com.liferay.portal.kernel.exception.SystemException se) {
574 _log.error(se, se);
575
576 throw se;
577 }
578 }
579
580 public static java.util.List<com.liferay.portal.model.Group> getUserPlaces(
581 HttpPrincipal httpPrincipal, long userId,
582 java.lang.String[] classNames, java.lang.String name, boolean active,
583 boolean includeControlPanel, int start, int end)
584 throws com.liferay.portal.kernel.exception.PortalException,
585 com.liferay.portal.kernel.exception.SystemException {
586 try {
587 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
588 "getUserPlaces", _getUserPlacesParameterTypes14);
589
590 MethodHandler methodHandler = new MethodHandler(methodKey, userId,
591 classNames, name, active, includeControlPanel, start, end);
592
593 Object returnObj = null;
594
595 try {
596 returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
597 }
598 catch (Exception e) {
599 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
600 throw (com.liferay.portal.kernel.exception.PortalException)e;
601 }
602
603 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
604 throw (com.liferay.portal.kernel.exception.SystemException)e;
605 }
606
607 throw new com.liferay.portal.kernel.exception.SystemException(e);
608 }
609
610 return (java.util.List<com.liferay.portal.model.Group>)returnObj;
611 }
612 catch (com.liferay.portal.kernel.exception.SystemException se) {
613 _log.error(se, se);
614
615 throw se;
616 }
617 }
618
619 public static java.util.List<com.liferay.portal.model.Group> getUserPlaces(
620 HttpPrincipal httpPrincipal, java.lang.String[] classNames, int max)
621 throws com.liferay.portal.kernel.exception.PortalException,
622 com.liferay.portal.kernel.exception.SystemException {
623 try {
624 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
625 "getUserPlaces", _getUserPlacesParameterTypes15);
626
627 MethodHandler methodHandler = new MethodHandler(methodKey,
628 classNames, max);
629
630 Object returnObj = null;
631
632 try {
633 returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
634 }
635 catch (Exception e) {
636 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
637 throw (com.liferay.portal.kernel.exception.PortalException)e;
638 }
639
640 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
641 throw (com.liferay.portal.kernel.exception.SystemException)e;
642 }
643
644 throw new com.liferay.portal.kernel.exception.SystemException(e);
645 }
646
647 return (java.util.List<com.liferay.portal.model.Group>)returnObj;
648 }
649 catch (com.liferay.portal.kernel.exception.SystemException se) {
650 _log.error(se, se);
651
652 throw se;
653 }
654 }
655
656 public static int getUserPlacesCount(HttpPrincipal httpPrincipal)
657 throws com.liferay.portal.kernel.exception.PortalException,
658 com.liferay.portal.kernel.exception.SystemException {
659 try {
660 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
661 "getUserPlacesCount", _getUserPlacesCountParameterTypes16);
662
663 MethodHandler methodHandler = new MethodHandler(methodKey);
664
665 Object returnObj = null;
666
667 try {
668 returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
669 }
670 catch (Exception e) {
671 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
672 throw (com.liferay.portal.kernel.exception.PortalException)e;
673 }
674
675 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
676 throw (com.liferay.portal.kernel.exception.SystemException)e;
677 }
678
679 throw new com.liferay.portal.kernel.exception.SystemException(e);
680 }
681
682 return ((Integer)returnObj).intValue();
683 }
684 catch (com.liferay.portal.kernel.exception.SystemException se) {
685 _log.error(se, se);
686
687 throw se;
688 }
689 }
690
691 public static java.util.List<com.liferay.portal.model.Group> getUserSites(
692 HttpPrincipal httpPrincipal)
693 throws com.liferay.portal.kernel.exception.PortalException,
694 com.liferay.portal.kernel.exception.SystemException {
695 try {
696 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
697 "getUserSites", _getUserSitesParameterTypes17);
698
699 MethodHandler methodHandler = new MethodHandler(methodKey);
700
701 Object returnObj = null;
702
703 try {
704 returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
705 }
706 catch (Exception e) {
707 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
708 throw (com.liferay.portal.kernel.exception.PortalException)e;
709 }
710
711 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
712 throw (com.liferay.portal.kernel.exception.SystemException)e;
713 }
714
715 throw new com.liferay.portal.kernel.exception.SystemException(e);
716 }
717
718 return (java.util.List<com.liferay.portal.model.Group>)returnObj;
719 }
720 catch (com.liferay.portal.kernel.exception.SystemException se) {
721 _log.error(se, se);
722
723 throw se;
724 }
725 }
726
727 public static boolean hasUserGroup(HttpPrincipal httpPrincipal,
728 long userId, long groupId)
729 throws com.liferay.portal.kernel.exception.PortalException,
730 com.liferay.portal.kernel.exception.SystemException {
731 try {
732 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
733 "hasUserGroup", _hasUserGroupParameterTypes18);
734
735 MethodHandler methodHandler = new MethodHandler(methodKey, userId,
736 groupId);
737
738 Object returnObj = null;
739
740 try {
741 returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
742 }
743 catch (Exception e) {
744 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
745 throw (com.liferay.portal.kernel.exception.PortalException)e;
746 }
747
748 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
749 throw (com.liferay.portal.kernel.exception.SystemException)e;
750 }
751
752 throw new com.liferay.portal.kernel.exception.SystemException(e);
753 }
754
755 return ((Boolean)returnObj).booleanValue();
756 }
757 catch (com.liferay.portal.kernel.exception.SystemException se) {
758 _log.error(se, se);
759
760 throw se;
761 }
762 }
763
764 public static java.util.List<com.liferay.portal.model.Group> search(
765 HttpPrincipal httpPrincipal, long companyId, java.lang.String name,
766 java.lang.String description, java.lang.String[] params, int start,
767 int end)
768 throws com.liferay.portal.kernel.exception.PortalException,
769 com.liferay.portal.kernel.exception.SystemException {
770 try {
771 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
772 "search", _searchParameterTypes19);
773
774 MethodHandler methodHandler = new MethodHandler(methodKey,
775 companyId, name, description, params, start, end);
776
777 Object returnObj = null;
778
779 try {
780 returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
781 }
782 catch (Exception e) {
783 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
784 throw (com.liferay.portal.kernel.exception.PortalException)e;
785 }
786
787 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
788 throw (com.liferay.portal.kernel.exception.SystemException)e;
789 }
790
791 throw new com.liferay.portal.kernel.exception.SystemException(e);
792 }
793
794 return (java.util.List<com.liferay.portal.model.Group>)returnObj;
795 }
796 catch (com.liferay.portal.kernel.exception.SystemException se) {
797 _log.error(se, se);
798
799 throw se;
800 }
801 }
802
803 public static int searchCount(HttpPrincipal httpPrincipal, long companyId,
804 java.lang.String name, java.lang.String description,
805 java.lang.String[] params)
806 throws com.liferay.portal.kernel.exception.SystemException {
807 try {
808 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
809 "searchCount", _searchCountParameterTypes20);
810
811 MethodHandler methodHandler = new MethodHandler(methodKey,
812 companyId, name, description, params);
813
814 Object returnObj = null;
815
816 try {
817 returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
818 }
819 catch (Exception e) {
820 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
821 throw (com.liferay.portal.kernel.exception.SystemException)e;
822 }
823
824 throw new com.liferay.portal.kernel.exception.SystemException(e);
825 }
826
827 return ((Integer)returnObj).intValue();
828 }
829 catch (com.liferay.portal.kernel.exception.SystemException se) {
830 _log.error(se, se);
831
832 throw se;
833 }
834 }
835
836 public static void setRoleGroups(HttpPrincipal httpPrincipal, long roleId,
837 long[] groupIds)
838 throws com.liferay.portal.kernel.exception.PortalException,
839 com.liferay.portal.kernel.exception.SystemException {
840 try {
841 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
842 "setRoleGroups", _setRoleGroupsParameterTypes21);
843
844 MethodHandler methodHandler = new MethodHandler(methodKey, roleId,
845 groupIds);
846
847 try {
848 TunnelUtil.invoke(httpPrincipal, methodHandler);
849 }
850 catch (Exception e) {
851 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
852 throw (com.liferay.portal.kernel.exception.PortalException)e;
853 }
854
855 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
856 throw (com.liferay.portal.kernel.exception.SystemException)e;
857 }
858
859 throw new com.liferay.portal.kernel.exception.SystemException(e);
860 }
861 }
862 catch (com.liferay.portal.kernel.exception.SystemException se) {
863 _log.error(se, se);
864
865 throw se;
866 }
867 }
868
869 public static void unsetRoleGroups(HttpPrincipal httpPrincipal,
870 long roleId, long[] groupIds)
871 throws com.liferay.portal.kernel.exception.PortalException,
872 com.liferay.portal.kernel.exception.SystemException {
873 try {
874 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
875 "unsetRoleGroups", _unsetRoleGroupsParameterTypes22);
876
877 MethodHandler methodHandler = new MethodHandler(methodKey, roleId,
878 groupIds);
879
880 try {
881 TunnelUtil.invoke(httpPrincipal, methodHandler);
882 }
883 catch (Exception e) {
884 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
885 throw (com.liferay.portal.kernel.exception.PortalException)e;
886 }
887
888 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
889 throw (com.liferay.portal.kernel.exception.SystemException)e;
890 }
891
892 throw new com.liferay.portal.kernel.exception.SystemException(e);
893 }
894 }
895 catch (com.liferay.portal.kernel.exception.SystemException se) {
896 _log.error(se, se);
897
898 throw se;
899 }
900 }
901
902 public static com.liferay.portal.model.Group updateFriendlyURL(
903 HttpPrincipal httpPrincipal, long groupId, java.lang.String friendlyURL)
904 throws com.liferay.portal.kernel.exception.PortalException,
905 com.liferay.portal.kernel.exception.SystemException {
906 try {
907 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
908 "updateFriendlyURL", _updateFriendlyURLParameterTypes23);
909
910 MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
911 friendlyURL);
912
913 Object returnObj = null;
914
915 try {
916 returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
917 }
918 catch (Exception e) {
919 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
920 throw (com.liferay.portal.kernel.exception.PortalException)e;
921 }
922
923 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
924 throw (com.liferay.portal.kernel.exception.SystemException)e;
925 }
926
927 throw new com.liferay.portal.kernel.exception.SystemException(e);
928 }
929
930 return (com.liferay.portal.model.Group)returnObj;
931 }
932 catch (com.liferay.portal.kernel.exception.SystemException se) {
933 _log.error(se, se);
934
935 throw se;
936 }
937 }
938
939 public static com.liferay.portal.model.Group updateGroup(
940 HttpPrincipal httpPrincipal, long groupId, long parentGroupId,
941 java.lang.String name, java.lang.String description, int type,
942 java.lang.String friendlyURL, boolean active,
943 com.liferay.portal.service.ServiceContext serviceContext)
944 throws com.liferay.portal.kernel.exception.PortalException,
945 com.liferay.portal.kernel.exception.SystemException {
946 try {
947 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
948 "updateGroup", _updateGroupParameterTypes24);
949
950 MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
951 parentGroupId, name, description, type, friendlyURL,
952 active, serviceContext);
953
954 Object returnObj = null;
955
956 try {
957 returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
958 }
959 catch (Exception e) {
960 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
961 throw (com.liferay.portal.kernel.exception.PortalException)e;
962 }
963
964 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
965 throw (com.liferay.portal.kernel.exception.SystemException)e;
966 }
967
968 throw new com.liferay.portal.kernel.exception.SystemException(e);
969 }
970
971 return (com.liferay.portal.model.Group)returnObj;
972 }
973 catch (com.liferay.portal.kernel.exception.SystemException se) {
974 _log.error(se, se);
975
976 throw se;
977 }
978 }
979
980 public static com.liferay.portal.model.Group updateGroup(
981 HttpPrincipal httpPrincipal, long groupId, java.lang.String typeSettings)
982 throws com.liferay.portal.kernel.exception.PortalException,
983 com.liferay.portal.kernel.exception.SystemException {
984 try {
985 MethodKey methodKey = new MethodKey(GroupServiceUtil.class,
986 "updateGroup", _updateGroupParameterTypes25);
987
988 MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
989 typeSettings);
990
991 Object returnObj = null;
992
993 try {
994 returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
995 }
996 catch (Exception e) {
997 if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
998 throw (com.liferay.portal.kernel.exception.PortalException)e;
999 }
1000
1001 if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1002 throw (com.liferay.portal.kernel.exception.SystemException)e;
1003 }
1004
1005 throw new com.liferay.portal.kernel.exception.SystemException(e);
1006 }
1007
1008 return (com.liferay.portal.model.Group)returnObj;
1009 }
1010 catch (com.liferay.portal.kernel.exception.SystemException se) {
1011 _log.error(se, se);
1012
1013 throw se;
1014 }
1015 }
1016
1017 private static Log _log = LogFactoryUtil.getLog(GroupServiceHttp.class);
1018 private static final Class<?>[] _addGroupParameterTypes0 = new Class[] {
1019 long.class, long.class, java.lang.String.class,
1020 java.lang.String.class, int.class, java.lang.String.class,
1021 boolean.class, boolean.class,
1022 com.liferay.portal.service.ServiceContext.class
1023 };
1024 private static final Class<?>[] _addGroupParameterTypes1 = new Class[] {
1025 long.class, java.lang.String.class, java.lang.String.class,
1026 int.class, java.lang.String.class, boolean.class, boolean.class,
1027 com.liferay.portal.service.ServiceContext.class
1028 };
1029 private static final Class<?>[] _addGroupParameterTypes2 = new Class[] {
1030 java.lang.String.class, java.lang.String.class, int.class,
1031 java.lang.String.class, boolean.class, boolean.class,
1032 com.liferay.portal.service.ServiceContext.class
1033 };
1034 private static final Class<?>[] _addRoleGroupsParameterTypes3 = new Class[] {
1035 long.class, long[].class
1036 };
1037 private static final Class<?>[] _deleteGroupParameterTypes4 = new Class[] {
1038 long.class
1039 };
1040 private static final Class<?>[] _getGroupParameterTypes5 = new Class[] {
1041 long.class
1042 };
1043 private static final Class<?>[] _getGroupParameterTypes6 = new Class[] {
1044 long.class, java.lang.String.class
1045 };
1046 private static final Class<?>[] _getManageableSitesParameterTypes7 = new Class[] {
1047 java.util.Collection.class, int.class
1048 };
1049 private static final Class<?>[] _getOrganizationsGroupsParameterTypes8 = new Class[] {
1050 java.util.List.class
1051 };
1052 private static final Class<?>[] _getUserGroupParameterTypes9 = new Class[] {
1053 long.class, long.class
1054 };
1055 private static final Class<?>[] _getUserGroupsGroupsParameterTypes10 = new Class[] {
1056 java.util.List.class
1057 };
1058 private static final Class<?>[] _getUserOrganizationsGroupsParameterTypes11 = new Class[] {
1059 long.class, int.class, int.class
1060 };
1061 private static final Class<?>[] _getUserPlacesParameterTypes12 = new Class[] {
1062 long.class, java.lang.String[].class, boolean.class, int.class
1063 };
1064 private static final Class<?>[] _getUserPlacesParameterTypes13 = new Class[] {
1065 long.class, java.lang.String[].class, int.class
1066 };
1067 private static final Class<?>[] _getUserPlacesParameterTypes14 = new Class[] {
1068 long.class, java.lang.String[].class, java.lang.String.class,
1069 boolean.class, boolean.class, int.class, int.class
1070 };
1071 private static final Class<?>[] _getUserPlacesParameterTypes15 = new Class[] {
1072 java.lang.String[].class, int.class
1073 };
1074 private static final Class<?>[] _getUserPlacesCountParameterTypes16 = new Class[] {
1075
1076 };
1077 private static final Class<?>[] _getUserSitesParameterTypes17 = new Class[] { };
1078 private static final Class<?>[] _hasUserGroupParameterTypes18 = new Class[] {
1079 long.class, long.class
1080 };
1081 private static final Class<?>[] _searchParameterTypes19 = new Class[] {
1082 long.class, java.lang.String.class, java.lang.String.class,
1083 java.lang.String[].class, int.class, int.class
1084 };
1085 private static final Class<?>[] _searchCountParameterTypes20 = new Class[] {
1086 long.class, java.lang.String.class, java.lang.String.class,
1087 java.lang.String[].class
1088 };
1089 private static final Class<?>[] _setRoleGroupsParameterTypes21 = new Class[] {
1090 long.class, long[].class
1091 };
1092 private static final Class<?>[] _unsetRoleGroupsParameterTypes22 = new Class[] {
1093 long.class, long[].class
1094 };
1095 private static final Class<?>[] _updateFriendlyURLParameterTypes23 = new Class[] {
1096 long.class, java.lang.String.class
1097 };
1098 private static final Class<?>[] _updateGroupParameterTypes24 = new Class[] {
1099 long.class, long.class, java.lang.String.class,
1100 java.lang.String.class, int.class, java.lang.String.class,
1101 boolean.class, com.liferay.portal.service.ServiceContext.class
1102 };
1103 private static final Class<?>[] _updateGroupParameterTypes25 = new Class[] {
1104 long.class, java.lang.String.class
1105 };
1106 }