001
014
015 package com.liferay.portal.service.http;
016
017 import aQute.bnd.annotation.ProviderType;
018
019 import com.liferay.portal.kernel.log.Log;
020 import com.liferay.portal.kernel.log.LogFactoryUtil;
021 import com.liferay.portal.kernel.util.LocalizationUtil;
022 import com.liferay.portal.service.GroupServiceUtil;
023
024 import java.rmi.RemoteException;
025
026 import java.util.Locale;
027 import java.util.Map;
028
029
069 @ProviderType
070 public class GroupServiceSoap {
071 public static com.liferay.portal.model.GroupSoap addGroup(
072 long parentGroupId, long liveGroupId,
073 java.lang.String[] nameMapLanguageIds,
074 java.lang.String[] nameMapValues,
075 java.lang.String[] descriptionMapLanguageIds,
076 java.lang.String[] descriptionMapValues, int type,
077 boolean manualMembership, int membershipRestriction,
078 java.lang.String friendlyURL, boolean site, boolean inheritContent,
079 boolean active, com.liferay.portal.service.ServiceContext serviceContext)
080 throws RemoteException {
081 try {
082 Map<Locale, String> nameMap = LocalizationUtil.getLocalizationMap(nameMapLanguageIds,
083 nameMapValues);
084 Map<Locale, String> descriptionMap = LocalizationUtil.getLocalizationMap(descriptionMapLanguageIds,
085 descriptionMapValues);
086
087 com.liferay.portal.model.Group returnValue = GroupServiceUtil.addGroup(parentGroupId,
088 liveGroupId, nameMap, descriptionMap, type,
089 manualMembership, membershipRestriction, friendlyURL, site,
090 inheritContent, active, serviceContext);
091
092 return com.liferay.portal.model.GroupSoap.toSoapModel(returnValue);
093 }
094 catch (Exception e) {
095 _log.error(e, e);
096
097 throw new RemoteException(e.getMessage());
098 }
099 }
100
101 public static com.liferay.portal.model.GroupSoap addGroup(
102 long parentGroupId, long liveGroupId,
103 java.lang.String[] nameMapLanguageIds,
104 java.lang.String[] nameMapValues,
105 java.lang.String[] descriptionMapLanguageIds,
106 java.lang.String[] descriptionMapValues, int type,
107 boolean manualMembership, int membershipRestriction,
108 java.lang.String friendlyURL, boolean site, boolean active,
109 com.liferay.portal.service.ServiceContext serviceContext)
110 throws RemoteException {
111 try {
112 Map<Locale, String> nameMap = LocalizationUtil.getLocalizationMap(nameMapLanguageIds,
113 nameMapValues);
114 Map<Locale, String> descriptionMap = LocalizationUtil.getLocalizationMap(descriptionMapLanguageIds,
115 descriptionMapValues);
116
117 com.liferay.portal.model.Group returnValue = GroupServiceUtil.addGroup(parentGroupId,
118 liveGroupId, nameMap, descriptionMap, type,
119 manualMembership, membershipRestriction, friendlyURL, site,
120 active, serviceContext);
121
122 return com.liferay.portal.model.GroupSoap.toSoapModel(returnValue);
123 }
124 catch (Exception e) {
125 _log.error(e, e);
126
127 throw new RemoteException(e.getMessage());
128 }
129 }
130
131
158 @Deprecated
159 public static com.liferay.portal.model.GroupSoap addGroup(
160 long parentGroupId, long liveGroupId, java.lang.String name,
161 java.lang.String description, int type, boolean manualMembership,
162 int membershipRestriction, java.lang.String friendlyURL, boolean site,
163 boolean active, com.liferay.portal.service.ServiceContext serviceContext)
164 throws RemoteException {
165 try {
166 com.liferay.portal.model.Group returnValue = GroupServiceUtil.addGroup(parentGroupId,
167 liveGroupId, name, description, type, manualMembership,
168 membershipRestriction, friendlyURL, site, active,
169 serviceContext);
170
171 return com.liferay.portal.model.GroupSoap.toSoapModel(returnValue);
172 }
173 catch (Exception e) {
174 _log.error(e, e);
175
176 throw new RemoteException(e.getMessage());
177 }
178 }
179
180
201 @Deprecated
202 public static com.liferay.portal.model.GroupSoap addGroup(
203 long parentGroupId, java.lang.String name,
204 java.lang.String description, int type, java.lang.String friendlyURL,
205 boolean site, boolean active,
206 com.liferay.portal.service.ServiceContext serviceContext)
207 throws RemoteException {
208 try {
209 com.liferay.portal.model.Group returnValue = GroupServiceUtil.addGroup(parentGroupId,
210 name, description, type, friendlyURL, site, active,
211 serviceContext);
212
213 return com.liferay.portal.model.GroupSoap.toSoapModel(returnValue);
214 }
215 catch (Exception e) {
216 _log.error(e, e);
217
218 throw new RemoteException(e.getMessage());
219 }
220 }
221
222
226 @Deprecated
227 public static com.liferay.portal.model.GroupSoap addGroup(
228 java.lang.String name, java.lang.String description, int type,
229 java.lang.String friendlyURL, boolean site, boolean active,
230 com.liferay.portal.service.ServiceContext serviceContext)
231 throws RemoteException {
232 try {
233 com.liferay.portal.model.Group returnValue = GroupServiceUtil.addGroup(name,
234 description, type, friendlyURL, site, active, serviceContext);
235
236 return com.liferay.portal.model.GroupSoap.toSoapModel(returnValue);
237 }
238 catch (Exception e) {
239 _log.error(e, e);
240
241 throw new RemoteException(e.getMessage());
242 }
243 }
244
245
251 public static void addRoleGroups(long roleId, long[] groupIds)
252 throws RemoteException {
253 try {
254 GroupServiceUtil.addRoleGroups(roleId, groupIds);
255 }
256 catch (Exception e) {
257 _log.error(e, e);
258
259 throw new RemoteException(e.getMessage());
260 }
261 }
262
263
269 public static void checkRemoteStagingGroup(long groupId)
270 throws RemoteException {
271 try {
272 GroupServiceUtil.checkRemoteStagingGroup(groupId);
273 }
274 catch (Exception e) {
275 _log.error(e, e);
276
277 throw new RemoteException(e.getMessage());
278 }
279 }
280
281
293 public static void deleteGroup(long groupId) throws RemoteException {
294 try {
295 GroupServiceUtil.deleteGroup(groupId);
296 }
297 catch (Exception e) {
298 _log.error(e, e);
299
300 throw new RemoteException(e.getMessage());
301 }
302 }
303
304 public static void disableStaging(long groupId) throws RemoteException {
305 try {
306 GroupServiceUtil.disableStaging(groupId);
307 }
308 catch (Exception e) {
309 _log.error(e, e);
310
311 throw new RemoteException(e.getMessage());
312 }
313 }
314
315 public static void enableStaging(long groupId) throws RemoteException {
316 try {
317 GroupServiceUtil.enableStaging(groupId);
318 }
319 catch (Exception e) {
320 _log.error(e, e);
321
322 throw new RemoteException(e.getMessage());
323 }
324 }
325
326
332 public static com.liferay.portal.model.GroupSoap getCompanyGroup(
333 long companyId) throws RemoteException {
334 try {
335 com.liferay.portal.model.Group returnValue = GroupServiceUtil.getCompanyGroup(companyId);
336
337 return com.liferay.portal.model.GroupSoap.toSoapModel(returnValue);
338 }
339 catch (Exception e) {
340 _log.error(e, e);
341
342 throw new RemoteException(e.getMessage());
343 }
344 }
345
346
352 public static com.liferay.portal.model.GroupSoap getGroup(long groupId)
353 throws RemoteException {
354 try {
355 com.liferay.portal.model.Group returnValue = GroupServiceUtil.getGroup(groupId);
356
357 return com.liferay.portal.model.GroupSoap.toSoapModel(returnValue);
358 }
359 catch (Exception e) {
360 _log.error(e, e);
361
362 throw new RemoteException(e.getMessage());
363 }
364 }
365
366
373 public static com.liferay.portal.model.GroupSoap getGroup(long companyId,
374 java.lang.String groupKey) throws RemoteException {
375 try {
376 com.liferay.portal.model.Group returnValue = GroupServiceUtil.getGroup(companyId,
377 groupKey);
378
379 return com.liferay.portal.model.GroupSoap.toSoapModel(returnValue);
380 }
381 catch (Exception e) {
382 _log.error(e, e);
383
384 throw new RemoteException(e.getMessage());
385 }
386 }
387
388
397 public static com.liferay.portal.model.GroupSoap[] getGroups(
398 long companyId, long parentGroupId, boolean site)
399 throws RemoteException {
400 try {
401 java.util.List<com.liferay.portal.model.Group> returnValue = GroupServiceUtil.getGroups(companyId,
402 parentGroupId, site);
403
404 return com.liferay.portal.model.GroupSoap.toSoapModels(returnValue);
405 }
406 catch (Exception e) {
407 _log.error(e, e);
408
409 throw new RemoteException(e.getMessage());
410 }
411 }
412
413
423 public static com.liferay.portal.model.GroupSoap[] getManageableSiteGroups(
424 java.util.Collection<com.liferay.portal.model.Portlet> portlets, int max)
425 throws RemoteException {
426 try {
427 java.util.List<com.liferay.portal.model.Group> returnValue = GroupServiceUtil.getManageableSiteGroups(portlets,
428 max);
429
430 return com.liferay.portal.model.GroupSoap.toSoapModels(returnValue);
431 }
432 catch (Exception e) {
433 _log.error(e, e);
434
435 throw new RemoteException(e.getMessage());
436 }
437 }
438
439
451 @Deprecated
452 public static com.liferay.portal.model.GroupSoap[] getManageableSites(
453 java.util.Collection<com.liferay.portal.model.Portlet> portlets, int max)
454 throws RemoteException {
455 try {
456 java.util.List<com.liferay.portal.model.Group> returnValue = GroupServiceUtil.getManageableSites(portlets,
457 max);
458
459 return com.liferay.portal.model.GroupSoap.toSoapModels(returnValue);
460 }
461 catch (Exception e) {
462 _log.error(e, e);
463
464 throw new RemoteException(e.getMessage());
465 }
466 }
467
468
474 public static com.liferay.portal.model.GroupSoap[] getOrganizationsGroups(
475 com.liferay.portal.model.OrganizationSoap[] organizations)
476 throws RemoteException {
477 try {
478 java.util.List<com.liferay.portal.model.Group> returnValue = GroupServiceUtil.getOrganizationsGroups(com.liferay.portal.model.impl.OrganizationModelImpl.toModels(
479 organizations));
480
481 return com.liferay.portal.model.GroupSoap.toSoapModels(returnValue);
482 }
483 catch (Exception e) {
484 _log.error(e, e);
485
486 throw new RemoteException(e.getMessage());
487 }
488 }
489
490
497 public static com.liferay.portal.model.GroupSoap getUserGroup(
498 long companyId, long userId) throws RemoteException {
499 try {
500 com.liferay.portal.model.Group returnValue = GroupServiceUtil.getUserGroup(companyId,
501 userId);
502
503 return com.liferay.portal.model.GroupSoap.toSoapModel(returnValue);
504 }
505 catch (Exception e) {
506 _log.error(e, e);
507
508 throw new RemoteException(e.getMessage());
509 }
510 }
511
512
518 public static com.liferay.portal.model.GroupSoap[] getUserGroupsGroups(
519 com.liferay.portal.model.UserGroupSoap[] userGroups)
520 throws RemoteException {
521 try {
522 java.util.List<com.liferay.portal.model.Group> returnValue = GroupServiceUtil.getUserGroupsGroups(com.liferay.portal.model.impl.UserGroupModelImpl.toModels(
523 userGroups));
524
525 return com.liferay.portal.model.GroupSoap.toSoapModels(returnValue);
526 }
527 catch (Exception e) {
528 _log.error(e, e);
529
530 throw new RemoteException(e.getMessage());
531 }
532 }
533
534
555 public static com.liferay.portal.model.GroupSoap[] getUserOrganizationsGroups(
556 long userId, int start, int end) throws RemoteException {
557 try {
558 java.util.List<com.liferay.portal.model.Group> returnValue = GroupServiceUtil.getUserOrganizationsGroups(userId,
559 start, end);
560
561 return com.liferay.portal.model.GroupSoap.toSoapModels(returnValue);
562 }
563 catch (Exception e) {
564 _log.error(e, e);
565
566 throw new RemoteException(e.getMessage());
567 }
568 }
569
570
574 @Deprecated
575 public static com.liferay.portal.model.GroupSoap[] getUserPlaces(
576 long userId, java.lang.String[] classNames,
577 boolean includeControlPanel, int max) throws RemoteException {
578 try {
579 java.util.List<com.liferay.portal.model.Group> returnValue = GroupServiceUtil.getUserPlaces(userId,
580 classNames, includeControlPanel, max);
581
582 return com.liferay.portal.model.GroupSoap.toSoapModels(returnValue);
583 }
584 catch (Exception e) {
585 _log.error(e, e);
586
587 throw new RemoteException(e.getMessage());
588 }
589 }
590
591
625 @Deprecated
626 public static com.liferay.portal.model.GroupSoap[] getUserPlaces(
627 long userId, java.lang.String[] classNames, int max)
628 throws RemoteException {
629 try {
630 java.util.List<com.liferay.portal.model.Group> returnValue = GroupServiceUtil.getUserPlaces(userId,
631 classNames, max);
632
633 return com.liferay.portal.model.GroupSoap.toSoapModels(returnValue);
634 }
635 catch (Exception e) {
636 _log.error(e, e);
637
638 throw new RemoteException(e.getMessage());
639 }
640 }
641
642
675 @Deprecated
676 public static com.liferay.portal.model.GroupSoap[] getUserPlaces(
677 java.lang.String[] classNames, int max) throws RemoteException {
678 try {
679 java.util.List<com.liferay.portal.model.Group> returnValue = GroupServiceUtil.getUserPlaces(classNames,
680 max);
681
682 return com.liferay.portal.model.GroupSoap.toSoapModels(returnValue);
683 }
684 catch (Exception e) {
685 _log.error(e, e);
686
687 throw new RemoteException(e.getMessage());
688 }
689 }
690
691
700 @Deprecated
701 public static int getUserPlacesCount() throws RemoteException {
702 try {
703 int returnValue = GroupServiceUtil.getUserPlacesCount();
704
705 return returnValue;
706 }
707 catch (Exception e) {
708 _log.error(e, e);
709
710 throw new RemoteException(e.getMessage());
711 }
712 }
713
714
722 @Deprecated
723 public static com.liferay.portal.model.GroupSoap[] getUserSites()
724 throws RemoteException {
725 try {
726 java.util.List<com.liferay.portal.model.Group> returnValue = GroupServiceUtil.getUserSites();
727
728 return com.liferay.portal.model.GroupSoap.toSoapModels(returnValue);
729 }
730 catch (Exception e) {
731 _log.error(e, e);
732
733 throw new RemoteException(e.getMessage());
734 }
735 }
736
737 public static com.liferay.portal.model.GroupSoap[] getUserSitesGroups()
738 throws RemoteException {
739 try {
740 java.util.List<com.liferay.portal.model.Group> returnValue = GroupServiceUtil.getUserSitesGroups();
741
742 return com.liferay.portal.model.GroupSoap.toSoapModels(returnValue);
743 }
744 catch (Exception e) {
745 _log.error(e, e);
746
747 throw new RemoteException(e.getMessage());
748 }
749 }
750
751
783 public static com.liferay.portal.model.GroupSoap[] getUserSitesGroups(
784 long userId, java.lang.String[] classNames, int max)
785 throws RemoteException {
786 try {
787 java.util.List<com.liferay.portal.model.Group> returnValue = GroupServiceUtil.getUserSitesGroups(userId,
788 classNames, max);
789
790 return com.liferay.portal.model.GroupSoap.toSoapModels(returnValue);
791 }
792 catch (Exception e) {
793 _log.error(e, e);
794
795 throw new RemoteException(e.getMessage());
796 }
797 }
798
799
830 public static com.liferay.portal.model.GroupSoap[] getUserSitesGroups(
831 java.lang.String[] classNames, int max) throws RemoteException {
832 try {
833 java.util.List<com.liferay.portal.model.Group> returnValue = GroupServiceUtil.getUserSitesGroups(classNames,
834 max);
835
836 return com.liferay.portal.model.GroupSoap.toSoapModels(returnValue);
837 }
838 catch (Exception e) {
839 _log.error(e, e);
840
841 throw new RemoteException(e.getMessage());
842 }
843 }
844
845
853 public static int getUserSitesGroupsCount() throws RemoteException {
854 try {
855 int returnValue = GroupServiceUtil.getUserSitesGroupsCount();
856
857 return returnValue;
858 }
859 catch (Exception e) {
860 _log.error(e, e);
861
862 throw new RemoteException(e.getMessage());
863 }
864 }
865
866
876 public static boolean hasUserGroup(long userId, long groupId)
877 throws RemoteException {
878 try {
879 boolean returnValue = GroupServiceUtil.hasUserGroup(userId, groupId);
880
881 return returnValue;
882 }
883 catch (Exception e) {
884 _log.error(e, e);
885
886 throw new RemoteException(e.getMessage());
887 }
888 }
889
890
920 public static com.liferay.portal.model.GroupSoap[] search(long companyId,
921 java.lang.String name, java.lang.String description,
922 java.lang.String[] params, int start, int end)
923 throws RemoteException {
924 try {
925 java.util.List<com.liferay.portal.model.Group> returnValue = GroupServiceUtil.search(companyId,
926 name, description, params, start, end);
927
928 return com.liferay.portal.model.GroupSoap.toSoapModels(returnValue);
929 }
930 catch (Exception e) {
931 _log.error(e, e);
932
933 throw new RemoteException(e.getMessage());
934 }
935 }
936
937
954 public static int searchCount(long companyId, java.lang.String name,
955 java.lang.String description, java.lang.String[] params)
956 throws RemoteException {
957 try {
958 int returnValue = GroupServiceUtil.searchCount(companyId, name,
959 description, params);
960
961 return returnValue;
962 }
963 catch (Exception e) {
964 _log.error(e, e);
965
966 throw new RemoteException(e.getMessage());
967 }
968 }
969
970
977 public static void setRoleGroups(long roleId, long[] groupIds)
978 throws RemoteException {
979 try {
980 GroupServiceUtil.setRoleGroups(roleId, groupIds);
981 }
982 catch (Exception e) {
983 _log.error(e, e);
984
985 throw new RemoteException(e.getMessage());
986 }
987 }
988
989
995 public static void unsetRoleGroups(long roleId, long[] groupIds)
996 throws RemoteException {
997 try {
998 GroupServiceUtil.unsetRoleGroups(roleId, groupIds);
999 }
1000 catch (Exception e) {
1001 _log.error(e, e);
1002
1003 throw new RemoteException(e.getMessage());
1004 }
1005 }
1006
1007
1015 public static com.liferay.portal.model.GroupSoap updateFriendlyURL(
1016 long groupId, java.lang.String friendlyURL) throws RemoteException {
1017 try {
1018 com.liferay.portal.model.Group returnValue = GroupServiceUtil.updateFriendlyURL(groupId,
1019 friendlyURL);
1020
1021 return com.liferay.portal.model.GroupSoap.toSoapModel(returnValue);
1022 }
1023 catch (Exception e) {
1024 _log.error(e, e);
1025
1026 throw new RemoteException(e.getMessage());
1027 }
1028 }
1029
1030 public static com.liferay.portal.model.GroupSoap updateGroup(long groupId,
1031 long parentGroupId, java.lang.String[] nameMapLanguageIds,
1032 java.lang.String[] nameMapValues,
1033 java.lang.String[] descriptionMapLanguageIds,
1034 java.lang.String[] descriptionMapValues, int type,
1035 boolean manualMembership, int membershipRestriction,
1036 java.lang.String friendlyURL, boolean inheritContent, boolean active,
1037 com.liferay.portal.service.ServiceContext serviceContext)
1038 throws RemoteException {
1039 try {
1040 Map<Locale, String> nameMap = LocalizationUtil.getLocalizationMap(nameMapLanguageIds,
1041 nameMapValues);
1042 Map<Locale, String> descriptionMap = LocalizationUtil.getLocalizationMap(descriptionMapLanguageIds,
1043 descriptionMapValues);
1044
1045 com.liferay.portal.model.Group returnValue = GroupServiceUtil.updateGroup(groupId,
1046 parentGroupId, nameMap, descriptionMap, type,
1047 manualMembership, membershipRestriction, friendlyURL,
1048 inheritContent, active, serviceContext);
1049
1050 return com.liferay.portal.model.GroupSoap.toSoapModel(returnValue);
1051 }
1052 catch (Exception e) {
1053 _log.error(e, e);
1054
1055 throw new RemoteException(e.getMessage());
1056 }
1057 }
1058
1059
1084 @Deprecated
1085 public static com.liferay.portal.model.GroupSoap updateGroup(long groupId,
1086 long parentGroupId, java.lang.String name,
1087 java.lang.String description, int type, boolean manualMembership,
1088 int membershipRestriction, java.lang.String friendlyURL,
1089 boolean inheritContent, boolean active,
1090 com.liferay.portal.service.ServiceContext serviceContext)
1091 throws RemoteException {
1092 try {
1093 com.liferay.portal.model.Group returnValue = GroupServiceUtil.updateGroup(groupId,
1094 parentGroupId, name, description, type, manualMembership,
1095 membershipRestriction, friendlyURL, inheritContent, active,
1096 serviceContext);
1097
1098 return com.liferay.portal.model.GroupSoap.toSoapModel(returnValue);
1099 }
1100 catch (Exception e) {
1101 _log.error(e, e);
1102
1103 throw new RemoteException(e.getMessage());
1104 }
1105 }
1106
1107
1115 public static com.liferay.portal.model.GroupSoap updateGroup(long groupId,
1116 java.lang.String typeSettings) throws RemoteException {
1117 try {
1118 com.liferay.portal.model.Group returnValue = GroupServiceUtil.updateGroup(groupId,
1119 typeSettings);
1120
1121 return com.liferay.portal.model.GroupSoap.toSoapModel(returnValue);
1122 }
1123 catch (Exception e) {
1124 _log.error(e, e);
1125
1126 throw new RemoteException(e.getMessage());
1127 }
1128 }
1129
1130 private static Log _log = LogFactoryUtil.getLog(GroupServiceSoap.class);
1131 }