001    /**
002     * Copyright (c) 2000-2013 Liferay, Inc. All rights reserved.
003     *
004     * This library is free software; you can redistribute it and/or modify it under
005     * the terms of the GNU Lesser General Public License as published by the Free
006     * Software Foundation; either version 2.1 of the License, or (at your option)
007     * any later version.
008     *
009     * This library is distributed in the hope that it will be useful, but WITHOUT
010     * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
011     * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
012     * details.
013     */
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.UserServiceUtil;
023    
024    /**
025     * <p>
026     * This class provides a HTTP utility for the
027     * {@link com.liferay.portal.service.UserServiceUtil} service utility. The
028     * static methods of this class calls the same methods of the service utility.
029     * However, the signatures are different because it requires an additional
030     * {@link com.liferay.portal.security.auth.HttpPrincipal} parameter.
031     * </p>
032     *
033     * <p>
034     * The benefits of using the HTTP utility is that it is fast and allows for
035     * tunneling without the cost of serializing to text. The drawback is that it
036     * only works with Java.
037     * </p>
038     *
039     * <p>
040     * Set the property <b>tunnel.servlet.hosts.allowed</b> in portal.properties to
041     * configure security.
042     * </p>
043     *
044     * <p>
045     * The HTTP utility is only generated for remote services.
046     * </p>
047     *
048     * @author    Brian Wing Shun Chan
049     * @see       UserServiceSoap
050     * @see       com.liferay.portal.security.auth.HttpPrincipal
051     * @see       com.liferay.portal.service.UserServiceUtil
052     * @generated
053     */
054    public class UserServiceHttp {
055            public static void addGroupUsers(HttpPrincipal httpPrincipal, long groupId,
056                    long[] userIds, com.liferay.portal.service.ServiceContext serviceContext)
057                    throws com.liferay.portal.kernel.exception.PortalException,
058                            com.liferay.portal.kernel.exception.SystemException {
059                    try {
060                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
061                                            "addGroupUsers", _addGroupUsersParameterTypes0);
062    
063                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
064                                            userIds, serviceContext);
065    
066                            try {
067                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
068                            }
069                            catch (Exception e) {
070                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
071                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
072                                    }
073    
074                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
075                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
076                                    }
077    
078                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
079                            }
080                    }
081                    catch (com.liferay.portal.kernel.exception.SystemException se) {
082                            _log.error(se, se);
083    
084                            throw se;
085                    }
086            }
087    
088            public static void addOrganizationUsers(HttpPrincipal httpPrincipal,
089                    long organizationId, long[] userIds)
090                    throws com.liferay.portal.kernel.exception.PortalException,
091                            com.liferay.portal.kernel.exception.SystemException {
092                    try {
093                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
094                                            "addOrganizationUsers", _addOrganizationUsersParameterTypes1);
095    
096                            MethodHandler methodHandler = new MethodHandler(methodKey,
097                                            organizationId, userIds);
098    
099                            try {
100                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
101                            }
102                            catch (Exception e) {
103                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
104                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
105                                    }
106    
107                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
108                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
109                                    }
110    
111                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
112                            }
113                    }
114                    catch (com.liferay.portal.kernel.exception.SystemException se) {
115                            _log.error(se, se);
116    
117                            throw se;
118                    }
119            }
120    
121            public static void addPasswordPolicyUsers(HttpPrincipal httpPrincipal,
122                    long passwordPolicyId, long[] userIds)
123                    throws com.liferay.portal.kernel.exception.PortalException,
124                            com.liferay.portal.kernel.exception.SystemException {
125                    try {
126                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
127                                            "addPasswordPolicyUsers",
128                                            _addPasswordPolicyUsersParameterTypes2);
129    
130                            MethodHandler methodHandler = new MethodHandler(methodKey,
131                                            passwordPolicyId, userIds);
132    
133                            try {
134                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
135                            }
136                            catch (Exception e) {
137                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
138                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
139                                    }
140    
141                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
142                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
143                                    }
144    
145                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
146                            }
147                    }
148                    catch (com.liferay.portal.kernel.exception.SystemException se) {
149                            _log.error(se, se);
150    
151                            throw se;
152                    }
153            }
154    
155            public static void addRoleUsers(HttpPrincipal httpPrincipal, long roleId,
156                    long[] userIds)
157                    throws com.liferay.portal.kernel.exception.PortalException,
158                            com.liferay.portal.kernel.exception.SystemException {
159                    try {
160                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
161                                            "addRoleUsers", _addRoleUsersParameterTypes3);
162    
163                            MethodHandler methodHandler = new MethodHandler(methodKey, roleId,
164                                            userIds);
165    
166                            try {
167                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
168                            }
169                            catch (Exception e) {
170                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
171                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
172                                    }
173    
174                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
175                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
176                                    }
177    
178                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
179                            }
180                    }
181                    catch (com.liferay.portal.kernel.exception.SystemException se) {
182                            _log.error(se, se);
183    
184                            throw se;
185                    }
186            }
187    
188            public static void addTeamUsers(HttpPrincipal httpPrincipal, long teamId,
189                    long[] userIds)
190                    throws com.liferay.portal.kernel.exception.PortalException,
191                            com.liferay.portal.kernel.exception.SystemException {
192                    try {
193                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
194                                            "addTeamUsers", _addTeamUsersParameterTypes4);
195    
196                            MethodHandler methodHandler = new MethodHandler(methodKey, teamId,
197                                            userIds);
198    
199                            try {
200                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
201                            }
202                            catch (Exception e) {
203                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
204                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
205                                    }
206    
207                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
208                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
209                                    }
210    
211                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
212                            }
213                    }
214                    catch (com.liferay.portal.kernel.exception.SystemException se) {
215                            _log.error(se, se);
216    
217                            throw se;
218                    }
219            }
220    
221            public static com.liferay.portal.model.User addUser(
222                    HttpPrincipal httpPrincipal, long companyId, boolean autoPassword,
223                    java.lang.String password1, java.lang.String password2,
224                    boolean autoScreenName, java.lang.String screenName,
225                    java.lang.String emailAddress, long facebookId,
226                    java.lang.String openId, java.util.Locale locale,
227                    java.lang.String firstName, java.lang.String middleName,
228                    java.lang.String lastName, int prefixId, int suffixId, boolean male,
229                    int birthdayMonth, int birthdayDay, int birthdayYear,
230                    java.lang.String jobTitle, long[] groupIds, long[] organizationIds,
231                    long[] roleIds, long[] userGroupIds, boolean sendEmail,
232                    com.liferay.portal.service.ServiceContext serviceContext)
233                    throws com.liferay.portal.kernel.exception.PortalException,
234                            com.liferay.portal.kernel.exception.SystemException {
235                    try {
236                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
237                                            "addUser", _addUserParameterTypes5);
238    
239                            MethodHandler methodHandler = new MethodHandler(methodKey,
240                                            companyId, autoPassword, password1, password2,
241                                            autoScreenName, screenName, emailAddress, facebookId,
242                                            openId, locale, firstName, middleName, lastName, prefixId,
243                                            suffixId, male, birthdayMonth, birthdayDay, birthdayYear,
244                                            jobTitle, groupIds, organizationIds, roleIds, userGroupIds,
245                                            sendEmail, serviceContext);
246    
247                            Object returnObj = null;
248    
249                            try {
250                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
251                            }
252                            catch (Exception e) {
253                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
254                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
255                                    }
256    
257                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
258                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
259                                    }
260    
261                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
262                            }
263    
264                            return (com.liferay.portal.model.User)returnObj;
265                    }
266                    catch (com.liferay.portal.kernel.exception.SystemException se) {
267                            _log.error(se, se);
268    
269                            throw se;
270                    }
271            }
272    
273            public static com.liferay.portal.model.User addUser(
274                    HttpPrincipal httpPrincipal, long companyId, boolean autoPassword,
275                    java.lang.String password1, java.lang.String password2,
276                    boolean autoScreenName, java.lang.String screenName,
277                    java.lang.String emailAddress, long facebookId,
278                    java.lang.String openId, java.util.Locale locale,
279                    java.lang.String firstName, java.lang.String middleName,
280                    java.lang.String lastName, int prefixId, int suffixId, boolean male,
281                    int birthdayMonth, int birthdayDay, int birthdayYear,
282                    java.lang.String jobTitle, long[] groupIds, long[] organizationIds,
283                    long[] roleIds, long[] userGroupIds,
284                    java.util.List<com.liferay.portal.model.Address> addresses,
285                    java.util.List<com.liferay.portal.model.EmailAddress> emailAddresses,
286                    java.util.List<com.liferay.portal.model.Phone> phones,
287                    java.util.List<com.liferay.portal.model.Website> websites,
288                    java.util.List<com.liferay.portlet.announcements.model.AnnouncementsDelivery> announcementsDelivers,
289                    boolean sendEmail,
290                    com.liferay.portal.service.ServiceContext serviceContext)
291                    throws com.liferay.portal.kernel.exception.PortalException,
292                            com.liferay.portal.kernel.exception.SystemException {
293                    try {
294                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
295                                            "addUser", _addUserParameterTypes6);
296    
297                            MethodHandler methodHandler = new MethodHandler(methodKey,
298                                            companyId, autoPassword, password1, password2,
299                                            autoScreenName, screenName, emailAddress, facebookId,
300                                            openId, locale, firstName, middleName, lastName, prefixId,
301                                            suffixId, male, birthdayMonth, birthdayDay, birthdayYear,
302                                            jobTitle, groupIds, organizationIds, roleIds, userGroupIds,
303                                            addresses, emailAddresses, phones, websites,
304                                            announcementsDelivers, sendEmail, serviceContext);
305    
306                            Object returnObj = null;
307    
308                            try {
309                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
310                            }
311                            catch (Exception e) {
312                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
313                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
314                                    }
315    
316                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
317                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
318                                    }
319    
320                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
321                            }
322    
323                            return (com.liferay.portal.model.User)returnObj;
324                    }
325                    catch (com.liferay.portal.kernel.exception.SystemException se) {
326                            _log.error(se, se);
327    
328                            throw se;
329                    }
330            }
331    
332            public static void addUserGroupUsers(HttpPrincipal httpPrincipal,
333                    long userGroupId, long[] userIds)
334                    throws com.liferay.portal.kernel.exception.PortalException,
335                            com.liferay.portal.kernel.exception.SystemException {
336                    try {
337                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
338                                            "addUserGroupUsers", _addUserGroupUsersParameterTypes7);
339    
340                            MethodHandler methodHandler = new MethodHandler(methodKey,
341                                            userGroupId, userIds);
342    
343                            try {
344                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
345                            }
346                            catch (Exception e) {
347                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
348                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
349                                    }
350    
351                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
352                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
353                                    }
354    
355                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
356                            }
357                    }
358                    catch (com.liferay.portal.kernel.exception.SystemException se) {
359                            _log.error(se, se);
360    
361                            throw se;
362                    }
363            }
364    
365            public static com.liferay.portal.model.User addUserWithWorkflow(
366                    HttpPrincipal httpPrincipal, long companyId, boolean autoPassword,
367                    java.lang.String password1, java.lang.String password2,
368                    boolean autoScreenName, java.lang.String screenName,
369                    java.lang.String emailAddress, long facebookId,
370                    java.lang.String openId, java.util.Locale locale,
371                    java.lang.String firstName, java.lang.String middleName,
372                    java.lang.String lastName, int prefixId, int suffixId, boolean male,
373                    int birthdayMonth, int birthdayDay, int birthdayYear,
374                    java.lang.String jobTitle, long[] groupIds, long[] organizationIds,
375                    long[] roleIds, long[] userGroupIds, boolean sendEmail,
376                    com.liferay.portal.service.ServiceContext serviceContext)
377                    throws com.liferay.portal.kernel.exception.PortalException,
378                            com.liferay.portal.kernel.exception.SystemException {
379                    try {
380                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
381                                            "addUserWithWorkflow", _addUserWithWorkflowParameterTypes8);
382    
383                            MethodHandler methodHandler = new MethodHandler(methodKey,
384                                            companyId, autoPassword, password1, password2,
385                                            autoScreenName, screenName, emailAddress, facebookId,
386                                            openId, locale, firstName, middleName, lastName, prefixId,
387                                            suffixId, male, birthdayMonth, birthdayDay, birthdayYear,
388                                            jobTitle, groupIds, organizationIds, roleIds, userGroupIds,
389                                            sendEmail, serviceContext);
390    
391                            Object returnObj = null;
392    
393                            try {
394                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
395                            }
396                            catch (Exception e) {
397                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
398                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
399                                    }
400    
401                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
402                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
403                                    }
404    
405                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
406                            }
407    
408                            return (com.liferay.portal.model.User)returnObj;
409                    }
410                    catch (com.liferay.portal.kernel.exception.SystemException se) {
411                            _log.error(se, se);
412    
413                            throw se;
414                    }
415            }
416    
417            public static com.liferay.portal.model.User addUserWithWorkflow(
418                    HttpPrincipal httpPrincipal, long companyId, boolean autoPassword,
419                    java.lang.String password1, java.lang.String password2,
420                    boolean autoScreenName, java.lang.String screenName,
421                    java.lang.String emailAddress, long facebookId,
422                    java.lang.String openId, java.util.Locale locale,
423                    java.lang.String firstName, java.lang.String middleName,
424                    java.lang.String lastName, int prefixId, int suffixId, boolean male,
425                    int birthdayMonth, int birthdayDay, int birthdayYear,
426                    java.lang.String jobTitle, long[] groupIds, long[] organizationIds,
427                    long[] roleIds, long[] userGroupIds,
428                    java.util.List<com.liferay.portal.model.Address> addresses,
429                    java.util.List<com.liferay.portal.model.EmailAddress> emailAddresses,
430                    java.util.List<com.liferay.portal.model.Phone> phones,
431                    java.util.List<com.liferay.portal.model.Website> websites,
432                    java.util.List<com.liferay.portlet.announcements.model.AnnouncementsDelivery> announcementsDelivers,
433                    boolean sendEmail,
434                    com.liferay.portal.service.ServiceContext serviceContext)
435                    throws com.liferay.portal.kernel.exception.PortalException,
436                            com.liferay.portal.kernel.exception.SystemException {
437                    try {
438                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
439                                            "addUserWithWorkflow", _addUserWithWorkflowParameterTypes9);
440    
441                            MethodHandler methodHandler = new MethodHandler(methodKey,
442                                            companyId, autoPassword, password1, password2,
443                                            autoScreenName, screenName, emailAddress, facebookId,
444                                            openId, locale, firstName, middleName, lastName, prefixId,
445                                            suffixId, male, birthdayMonth, birthdayDay, birthdayYear,
446                                            jobTitle, groupIds, organizationIds, roleIds, userGroupIds,
447                                            addresses, emailAddresses, phones, websites,
448                                            announcementsDelivers, sendEmail, serviceContext);
449    
450                            Object returnObj = null;
451    
452                            try {
453                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
454                            }
455                            catch (Exception e) {
456                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
457                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
458                                    }
459    
460                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
461                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
462                                    }
463    
464                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
465                            }
466    
467                            return (com.liferay.portal.model.User)returnObj;
468                    }
469                    catch (com.liferay.portal.kernel.exception.SystemException se) {
470                            _log.error(se, se);
471    
472                            throw se;
473                    }
474            }
475    
476            public static void deletePortrait(HttpPrincipal httpPrincipal, long userId)
477                    throws com.liferay.portal.kernel.exception.PortalException,
478                            com.liferay.portal.kernel.exception.SystemException {
479                    try {
480                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
481                                            "deletePortrait", _deletePortraitParameterTypes10);
482    
483                            MethodHandler methodHandler = new MethodHandler(methodKey, userId);
484    
485                            try {
486                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
487                            }
488                            catch (Exception e) {
489                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
490                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
491                                    }
492    
493                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
494                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
495                                    }
496    
497                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
498                            }
499                    }
500                    catch (com.liferay.portal.kernel.exception.SystemException se) {
501                            _log.error(se, se);
502    
503                            throw se;
504                    }
505            }
506    
507            public static void deleteRoleUser(HttpPrincipal httpPrincipal, long roleId,
508                    long userId)
509                    throws com.liferay.portal.kernel.exception.PortalException,
510                            com.liferay.portal.kernel.exception.SystemException {
511                    try {
512                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
513                                            "deleteRoleUser", _deleteRoleUserParameterTypes11);
514    
515                            MethodHandler methodHandler = new MethodHandler(methodKey, roleId,
516                                            userId);
517    
518                            try {
519                                    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                    catch (com.liferay.portal.kernel.exception.SystemException se) {
534                            _log.error(se, se);
535    
536                            throw se;
537                    }
538            }
539    
540            public static void deleteUser(HttpPrincipal httpPrincipal, long userId)
541                    throws com.liferay.portal.kernel.exception.PortalException,
542                            com.liferay.portal.kernel.exception.SystemException {
543                    try {
544                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
545                                            "deleteUser", _deleteUserParameterTypes12);
546    
547                            MethodHandler methodHandler = new MethodHandler(methodKey, userId);
548    
549                            try {
550                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
551                            }
552                            catch (Exception e) {
553                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
554                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
555                                    }
556    
557                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
558                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
559                                    }
560    
561                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
562                            }
563                    }
564                    catch (com.liferay.portal.kernel.exception.SystemException se) {
565                            _log.error(se, se);
566    
567                            throw se;
568                    }
569            }
570    
571            public static java.util.List<com.liferay.portal.model.User> getCompanyUsers(
572                    HttpPrincipal httpPrincipal, long companyId, int start, int end)
573                    throws com.liferay.portal.kernel.exception.PortalException,
574                            com.liferay.portal.kernel.exception.SystemException {
575                    try {
576                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
577                                            "getCompanyUsers", _getCompanyUsersParameterTypes13);
578    
579                            MethodHandler methodHandler = new MethodHandler(methodKey,
580                                            companyId, start, end);
581    
582                            Object returnObj = null;
583    
584                            try {
585                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
586                            }
587                            catch (Exception e) {
588                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
589                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
590                                    }
591    
592                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
593                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
594                                    }
595    
596                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
597                            }
598    
599                            return (java.util.List<com.liferay.portal.model.User>)returnObj;
600                    }
601                    catch (com.liferay.portal.kernel.exception.SystemException se) {
602                            _log.error(se, se);
603    
604                            throw se;
605                    }
606            }
607    
608            public static int getCompanyUsersCount(HttpPrincipal httpPrincipal,
609                    long companyId)
610                    throws com.liferay.portal.kernel.exception.PortalException,
611                            com.liferay.portal.kernel.exception.SystemException {
612                    try {
613                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
614                                            "getCompanyUsersCount",
615                                            _getCompanyUsersCountParameterTypes14);
616    
617                            MethodHandler methodHandler = new MethodHandler(methodKey, companyId);
618    
619                            Object returnObj = null;
620    
621                            try {
622                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
623                            }
624                            catch (Exception e) {
625                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
626                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
627                                    }
628    
629                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
630                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
631                                    }
632    
633                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
634                            }
635    
636                            return ((Integer)returnObj).intValue();
637                    }
638                    catch (com.liferay.portal.kernel.exception.SystemException se) {
639                            _log.error(se, se);
640    
641                            throw se;
642                    }
643            }
644    
645            public static long getDefaultUserId(HttpPrincipal httpPrincipal,
646                    long companyId)
647                    throws com.liferay.portal.kernel.exception.PortalException,
648                            com.liferay.portal.kernel.exception.SystemException {
649                    try {
650                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
651                                            "getDefaultUserId", _getDefaultUserIdParameterTypes15);
652    
653                            MethodHandler methodHandler = new MethodHandler(methodKey, companyId);
654    
655                            Object returnObj = null;
656    
657                            try {
658                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
659                            }
660                            catch (Exception e) {
661                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
662                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
663                                    }
664    
665                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
666                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
667                                    }
668    
669                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
670                            }
671    
672                            return ((Long)returnObj).longValue();
673                    }
674                    catch (com.liferay.portal.kernel.exception.SystemException se) {
675                            _log.error(se, se);
676    
677                            throw se;
678                    }
679            }
680    
681            public static long[] getGroupUserIds(HttpPrincipal httpPrincipal,
682                    long groupId)
683                    throws com.liferay.portal.kernel.exception.PortalException,
684                            com.liferay.portal.kernel.exception.SystemException {
685                    try {
686                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
687                                            "getGroupUserIds", _getGroupUserIdsParameterTypes16);
688    
689                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId);
690    
691                            Object returnObj = null;
692    
693                            try {
694                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
695                            }
696                            catch (Exception e) {
697                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
698                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
699                                    }
700    
701                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
702                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
703                                    }
704    
705                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
706                            }
707    
708                            return (long[])returnObj;
709                    }
710                    catch (com.liferay.portal.kernel.exception.SystemException se) {
711                            _log.error(se, se);
712    
713                            throw se;
714                    }
715            }
716    
717            public static java.util.List<com.liferay.portal.model.User> getGroupUsers(
718                    HttpPrincipal httpPrincipal, long groupId)
719                    throws com.liferay.portal.kernel.exception.PortalException,
720                            com.liferay.portal.kernel.exception.SystemException {
721                    try {
722                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
723                                            "getGroupUsers", _getGroupUsersParameterTypes17);
724    
725                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId);
726    
727                            Object returnObj = null;
728    
729                            try {
730                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
731                            }
732                            catch (Exception e) {
733                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
734                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
735                                    }
736    
737                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
738                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
739                                    }
740    
741                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
742                            }
743    
744                            return (java.util.List<com.liferay.portal.model.User>)returnObj;
745                    }
746                    catch (com.liferay.portal.kernel.exception.SystemException se) {
747                            _log.error(se, se);
748    
749                            throw se;
750                    }
751            }
752    
753            public static long[] getOrganizationUserIds(HttpPrincipal httpPrincipal,
754                    long organizationId)
755                    throws com.liferay.portal.kernel.exception.PortalException,
756                            com.liferay.portal.kernel.exception.SystemException {
757                    try {
758                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
759                                            "getOrganizationUserIds",
760                                            _getOrganizationUserIdsParameterTypes18);
761    
762                            MethodHandler methodHandler = new MethodHandler(methodKey,
763                                            organizationId);
764    
765                            Object returnObj = null;
766    
767                            try {
768                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
769                            }
770                            catch (Exception e) {
771                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
772                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
773                                    }
774    
775                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
776                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
777                                    }
778    
779                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
780                            }
781    
782                            return (long[])returnObj;
783                    }
784                    catch (com.liferay.portal.kernel.exception.SystemException se) {
785                            _log.error(se, se);
786    
787                            throw se;
788                    }
789            }
790    
791            public static java.util.List<com.liferay.portal.model.User> getOrganizationUsers(
792                    HttpPrincipal httpPrincipal, long organizationId)
793                    throws com.liferay.portal.kernel.exception.PortalException,
794                            com.liferay.portal.kernel.exception.SystemException {
795                    try {
796                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
797                                            "getOrganizationUsers",
798                                            _getOrganizationUsersParameterTypes19);
799    
800                            MethodHandler methodHandler = new MethodHandler(methodKey,
801                                            organizationId);
802    
803                            Object returnObj = null;
804    
805                            try {
806                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
807                            }
808                            catch (Exception e) {
809                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
810                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
811                                    }
812    
813                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
814                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
815                                    }
816    
817                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
818                            }
819    
820                            return (java.util.List<com.liferay.portal.model.User>)returnObj;
821                    }
822                    catch (com.liferay.portal.kernel.exception.SystemException se) {
823                            _log.error(se, se);
824    
825                            throw se;
826                    }
827            }
828    
829            public static long[] getRoleUserIds(HttpPrincipal httpPrincipal, long roleId)
830                    throws com.liferay.portal.kernel.exception.PortalException,
831                            com.liferay.portal.kernel.exception.SystemException {
832                    try {
833                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
834                                            "getRoleUserIds", _getRoleUserIdsParameterTypes20);
835    
836                            MethodHandler methodHandler = new MethodHandler(methodKey, roleId);
837    
838                            Object returnObj = null;
839    
840                            try {
841                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
842                            }
843                            catch (Exception e) {
844                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
845                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
846                                    }
847    
848                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
849                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
850                                    }
851    
852                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
853                            }
854    
855                            return (long[])returnObj;
856                    }
857                    catch (com.liferay.portal.kernel.exception.SystemException se) {
858                            _log.error(se, se);
859    
860                            throw se;
861                    }
862            }
863    
864            public static com.liferay.portal.model.User getUserByEmailAddress(
865                    HttpPrincipal httpPrincipal, long companyId,
866                    java.lang.String emailAddress)
867                    throws com.liferay.portal.kernel.exception.PortalException,
868                            com.liferay.portal.kernel.exception.SystemException {
869                    try {
870                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
871                                            "getUserByEmailAddress",
872                                            _getUserByEmailAddressParameterTypes21);
873    
874                            MethodHandler methodHandler = new MethodHandler(methodKey,
875                                            companyId, emailAddress);
876    
877                            Object returnObj = null;
878    
879                            try {
880                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
881                            }
882                            catch (Exception e) {
883                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
884                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
885                                    }
886    
887                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
888                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
889                                    }
890    
891                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
892                            }
893    
894                            return (com.liferay.portal.model.User)returnObj;
895                    }
896                    catch (com.liferay.portal.kernel.exception.SystemException se) {
897                            _log.error(se, se);
898    
899                            throw se;
900                    }
901            }
902    
903            public static com.liferay.portal.model.User getUserById(
904                    HttpPrincipal httpPrincipal, long userId)
905                    throws com.liferay.portal.kernel.exception.PortalException,
906                            com.liferay.portal.kernel.exception.SystemException {
907                    try {
908                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
909                                            "getUserById", _getUserByIdParameterTypes22);
910    
911                            MethodHandler methodHandler = new MethodHandler(methodKey, userId);
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.User)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.User getUserByScreenName(
940                    HttpPrincipal httpPrincipal, long companyId, java.lang.String screenName)
941                    throws com.liferay.portal.kernel.exception.PortalException,
942                            com.liferay.portal.kernel.exception.SystemException {
943                    try {
944                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
945                                            "getUserByScreenName", _getUserByScreenNameParameterTypes23);
946    
947                            MethodHandler methodHandler = new MethodHandler(methodKey,
948                                            companyId, screenName);
949    
950                            Object returnObj = null;
951    
952                            try {
953                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
954                            }
955                            catch (Exception e) {
956                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
957                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
958                                    }
959    
960                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
961                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
962                                    }
963    
964                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
965                            }
966    
967                            return (com.liferay.portal.model.User)returnObj;
968                    }
969                    catch (com.liferay.portal.kernel.exception.SystemException se) {
970                            _log.error(se, se);
971    
972                            throw se;
973                    }
974            }
975    
976            public static java.util.List<com.liferay.portal.model.User> getUserGroupUsers(
977                    HttpPrincipal httpPrincipal, long userGroupId)
978                    throws com.liferay.portal.kernel.exception.PortalException,
979                            com.liferay.portal.kernel.exception.SystemException {
980                    try {
981                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
982                                            "getUserGroupUsers", _getUserGroupUsersParameterTypes24);
983    
984                            MethodHandler methodHandler = new MethodHandler(methodKey,
985                                            userGroupId);
986    
987                            Object returnObj = null;
988    
989                            try {
990                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
991                            }
992                            catch (Exception e) {
993                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
994                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
995                                    }
996    
997                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
998                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
999                                    }
1000    
1001                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1002                            }
1003    
1004                            return (java.util.List<com.liferay.portal.model.User>)returnObj;
1005                    }
1006                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1007                            _log.error(se, se);
1008    
1009                            throw se;
1010                    }
1011            }
1012    
1013            public static long getUserIdByEmailAddress(HttpPrincipal httpPrincipal,
1014                    long companyId, java.lang.String emailAddress)
1015                    throws com.liferay.portal.kernel.exception.PortalException,
1016                            com.liferay.portal.kernel.exception.SystemException {
1017                    try {
1018                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1019                                            "getUserIdByEmailAddress",
1020                                            _getUserIdByEmailAddressParameterTypes25);
1021    
1022                            MethodHandler methodHandler = new MethodHandler(methodKey,
1023                                            companyId, emailAddress);
1024    
1025                            Object returnObj = null;
1026    
1027                            try {
1028                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
1029                            }
1030                            catch (Exception e) {
1031                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1032                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1033                                    }
1034    
1035                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1036                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1037                                    }
1038    
1039                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1040                            }
1041    
1042                            return ((Long)returnObj).longValue();
1043                    }
1044                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1045                            _log.error(se, se);
1046    
1047                            throw se;
1048                    }
1049            }
1050    
1051            public static long getUserIdByScreenName(HttpPrincipal httpPrincipal,
1052                    long companyId, java.lang.String screenName)
1053                    throws com.liferay.portal.kernel.exception.PortalException,
1054                            com.liferay.portal.kernel.exception.SystemException {
1055                    try {
1056                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1057                                            "getUserIdByScreenName",
1058                                            _getUserIdByScreenNameParameterTypes26);
1059    
1060                            MethodHandler methodHandler = new MethodHandler(methodKey,
1061                                            companyId, screenName);
1062    
1063                            Object returnObj = null;
1064    
1065                            try {
1066                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
1067                            }
1068                            catch (Exception e) {
1069                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1070                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1071                                    }
1072    
1073                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1074                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1075                                    }
1076    
1077                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1078                            }
1079    
1080                            return ((Long)returnObj).longValue();
1081                    }
1082                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1083                            _log.error(se, se);
1084    
1085                            throw se;
1086                    }
1087            }
1088    
1089            public static boolean hasGroupUser(HttpPrincipal httpPrincipal,
1090                    long groupId, long userId)
1091                    throws com.liferay.portal.kernel.exception.PortalException,
1092                            com.liferay.portal.kernel.exception.SystemException {
1093                    try {
1094                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1095                                            "hasGroupUser", _hasGroupUserParameterTypes27);
1096    
1097                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
1098                                            userId);
1099    
1100                            Object returnObj = null;
1101    
1102                            try {
1103                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
1104                            }
1105                            catch (Exception e) {
1106                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1107                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1108                                    }
1109    
1110                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1111                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1112                                    }
1113    
1114                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1115                            }
1116    
1117                            return ((Boolean)returnObj).booleanValue();
1118                    }
1119                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1120                            _log.error(se, se);
1121    
1122                            throw se;
1123                    }
1124            }
1125    
1126            public static boolean hasRoleUser(HttpPrincipal httpPrincipal, long roleId,
1127                    long userId)
1128                    throws com.liferay.portal.kernel.exception.PortalException,
1129                            com.liferay.portal.kernel.exception.SystemException {
1130                    try {
1131                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1132                                            "hasRoleUser", _hasRoleUserParameterTypes28);
1133    
1134                            MethodHandler methodHandler = new MethodHandler(methodKey, roleId,
1135                                            userId);
1136    
1137                            Object returnObj = null;
1138    
1139                            try {
1140                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
1141                            }
1142                            catch (Exception e) {
1143                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1144                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1145                                    }
1146    
1147                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1148                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1149                                    }
1150    
1151                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1152                            }
1153    
1154                            return ((Boolean)returnObj).booleanValue();
1155                    }
1156                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1157                            _log.error(se, se);
1158    
1159                            throw se;
1160                    }
1161            }
1162    
1163            public static boolean hasRoleUser(HttpPrincipal httpPrincipal,
1164                    long companyId, java.lang.String name, long userId, boolean inherited)
1165                    throws com.liferay.portal.kernel.exception.PortalException,
1166                            com.liferay.portal.kernel.exception.SystemException {
1167                    try {
1168                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1169                                            "hasRoleUser", _hasRoleUserParameterTypes29);
1170    
1171                            MethodHandler methodHandler = new MethodHandler(methodKey,
1172                                            companyId, name, userId, inherited);
1173    
1174                            Object returnObj = null;
1175    
1176                            try {
1177                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
1178                            }
1179                            catch (Exception e) {
1180                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1181                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1182                                    }
1183    
1184                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1185                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1186                                    }
1187    
1188                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1189                            }
1190    
1191                            return ((Boolean)returnObj).booleanValue();
1192                    }
1193                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1194                            _log.error(se, se);
1195    
1196                            throw se;
1197                    }
1198            }
1199    
1200            public static void setRoleUsers(HttpPrincipal httpPrincipal, long roleId,
1201                    long[] userIds)
1202                    throws com.liferay.portal.kernel.exception.PortalException,
1203                            com.liferay.portal.kernel.exception.SystemException {
1204                    try {
1205                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1206                                            "setRoleUsers", _setRoleUsersParameterTypes30);
1207    
1208                            MethodHandler methodHandler = new MethodHandler(methodKey, roleId,
1209                                            userIds);
1210    
1211                            try {
1212                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
1213                            }
1214                            catch (Exception e) {
1215                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1216                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1217                                    }
1218    
1219                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1220                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1221                                    }
1222    
1223                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1224                            }
1225                    }
1226                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1227                            _log.error(se, se);
1228    
1229                            throw se;
1230                    }
1231            }
1232    
1233            public static void setUserGroupUsers(HttpPrincipal httpPrincipal,
1234                    long userGroupId, long[] userIds)
1235                    throws com.liferay.portal.kernel.exception.PortalException,
1236                            com.liferay.portal.kernel.exception.SystemException {
1237                    try {
1238                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1239                                            "setUserGroupUsers", _setUserGroupUsersParameterTypes31);
1240    
1241                            MethodHandler methodHandler = new MethodHandler(methodKey,
1242                                            userGroupId, userIds);
1243    
1244                            try {
1245                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
1246                            }
1247                            catch (Exception e) {
1248                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1249                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1250                                    }
1251    
1252                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1253                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1254                                    }
1255    
1256                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1257                            }
1258                    }
1259                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1260                            _log.error(se, se);
1261    
1262                            throw se;
1263                    }
1264            }
1265    
1266            public static void unsetGroupTeamsUsers(HttpPrincipal httpPrincipal,
1267                    long groupId, long[] userIds)
1268                    throws com.liferay.portal.kernel.exception.PortalException,
1269                            com.liferay.portal.kernel.exception.SystemException {
1270                    try {
1271                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1272                                            "unsetGroupTeamsUsers",
1273                                            _unsetGroupTeamsUsersParameterTypes32);
1274    
1275                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
1276                                            userIds);
1277    
1278                            try {
1279                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
1280                            }
1281                            catch (Exception e) {
1282                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1283                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1284                                    }
1285    
1286                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1287                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1288                                    }
1289    
1290                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1291                            }
1292                    }
1293                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1294                            _log.error(se, se);
1295    
1296                            throw se;
1297                    }
1298            }
1299    
1300            public static void unsetGroupUsers(HttpPrincipal httpPrincipal,
1301                    long groupId, long[] userIds,
1302                    com.liferay.portal.service.ServiceContext serviceContext)
1303                    throws com.liferay.portal.kernel.exception.PortalException,
1304                            com.liferay.portal.kernel.exception.SystemException {
1305                    try {
1306                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1307                                            "unsetGroupUsers", _unsetGroupUsersParameterTypes33);
1308    
1309                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
1310                                            userIds, serviceContext);
1311    
1312                            try {
1313                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
1314                            }
1315                            catch (Exception e) {
1316                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1317                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1318                                    }
1319    
1320                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1321                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1322                                    }
1323    
1324                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1325                            }
1326                    }
1327                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1328                            _log.error(se, se);
1329    
1330                            throw se;
1331                    }
1332            }
1333    
1334            public static void unsetOrganizationUsers(HttpPrincipal httpPrincipal,
1335                    long organizationId, long[] userIds)
1336                    throws com.liferay.portal.kernel.exception.PortalException,
1337                            com.liferay.portal.kernel.exception.SystemException {
1338                    try {
1339                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1340                                            "unsetOrganizationUsers",
1341                                            _unsetOrganizationUsersParameterTypes34);
1342    
1343                            MethodHandler methodHandler = new MethodHandler(methodKey,
1344                                            organizationId, userIds);
1345    
1346                            try {
1347                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
1348                            }
1349                            catch (Exception e) {
1350                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1351                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1352                                    }
1353    
1354                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1355                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1356                                    }
1357    
1358                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1359                            }
1360                    }
1361                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1362                            _log.error(se, se);
1363    
1364                            throw se;
1365                    }
1366            }
1367    
1368            public static void unsetPasswordPolicyUsers(HttpPrincipal httpPrincipal,
1369                    long passwordPolicyId, long[] userIds)
1370                    throws com.liferay.portal.kernel.exception.PortalException,
1371                            com.liferay.portal.kernel.exception.SystemException {
1372                    try {
1373                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1374                                            "unsetPasswordPolicyUsers",
1375                                            _unsetPasswordPolicyUsersParameterTypes35);
1376    
1377                            MethodHandler methodHandler = new MethodHandler(methodKey,
1378                                            passwordPolicyId, userIds);
1379    
1380                            try {
1381                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
1382                            }
1383                            catch (Exception e) {
1384                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1385                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1386                                    }
1387    
1388                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1389                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1390                                    }
1391    
1392                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1393                            }
1394                    }
1395                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1396                            _log.error(se, se);
1397    
1398                            throw se;
1399                    }
1400            }
1401    
1402            public static void unsetRoleUsers(HttpPrincipal httpPrincipal, long roleId,
1403                    long[] userIds)
1404                    throws com.liferay.portal.kernel.exception.PortalException,
1405                            com.liferay.portal.kernel.exception.SystemException {
1406                    try {
1407                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1408                                            "unsetRoleUsers", _unsetRoleUsersParameterTypes36);
1409    
1410                            MethodHandler methodHandler = new MethodHandler(methodKey, roleId,
1411                                            userIds);
1412    
1413                            try {
1414                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
1415                            }
1416                            catch (Exception e) {
1417                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1418                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1419                                    }
1420    
1421                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1422                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1423                                    }
1424    
1425                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1426                            }
1427                    }
1428                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1429                            _log.error(se, se);
1430    
1431                            throw se;
1432                    }
1433            }
1434    
1435            public static void unsetTeamUsers(HttpPrincipal httpPrincipal, long teamId,
1436                    long[] userIds)
1437                    throws com.liferay.portal.kernel.exception.PortalException,
1438                            com.liferay.portal.kernel.exception.SystemException {
1439                    try {
1440                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1441                                            "unsetTeamUsers", _unsetTeamUsersParameterTypes37);
1442    
1443                            MethodHandler methodHandler = new MethodHandler(methodKey, teamId,
1444                                            userIds);
1445    
1446                            try {
1447                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
1448                            }
1449                            catch (Exception e) {
1450                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1451                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1452                                    }
1453    
1454                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1455                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1456                                    }
1457    
1458                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1459                            }
1460                    }
1461                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1462                            _log.error(se, se);
1463    
1464                            throw se;
1465                    }
1466            }
1467    
1468            public static void unsetUserGroupUsers(HttpPrincipal httpPrincipal,
1469                    long userGroupId, long[] userIds)
1470                    throws com.liferay.portal.kernel.exception.PortalException,
1471                            com.liferay.portal.kernel.exception.SystemException {
1472                    try {
1473                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1474                                            "unsetUserGroupUsers", _unsetUserGroupUsersParameterTypes38);
1475    
1476                            MethodHandler methodHandler = new MethodHandler(methodKey,
1477                                            userGroupId, userIds);
1478    
1479                            try {
1480                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
1481                            }
1482                            catch (Exception e) {
1483                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1484                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1485                                    }
1486    
1487                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1488                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1489                                    }
1490    
1491                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1492                            }
1493                    }
1494                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1495                            _log.error(se, se);
1496    
1497                            throw se;
1498                    }
1499            }
1500    
1501            public static com.liferay.portal.model.User updateAgreedToTermsOfUse(
1502                    HttpPrincipal httpPrincipal, long userId, boolean agreedToTermsOfUse)
1503                    throws com.liferay.portal.kernel.exception.PortalException,
1504                            com.liferay.portal.kernel.exception.SystemException {
1505                    try {
1506                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1507                                            "updateAgreedToTermsOfUse",
1508                                            _updateAgreedToTermsOfUseParameterTypes39);
1509    
1510                            MethodHandler methodHandler = new MethodHandler(methodKey, userId,
1511                                            agreedToTermsOfUse);
1512    
1513                            Object returnObj = null;
1514    
1515                            try {
1516                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
1517                            }
1518                            catch (Exception e) {
1519                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1520                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1521                                    }
1522    
1523                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1524                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1525                                    }
1526    
1527                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1528                            }
1529    
1530                            return (com.liferay.portal.model.User)returnObj;
1531                    }
1532                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1533                            _log.error(se, se);
1534    
1535                            throw se;
1536                    }
1537            }
1538    
1539            public static com.liferay.portal.model.User updateEmailAddress(
1540                    HttpPrincipal httpPrincipal, long userId, java.lang.String password,
1541                    java.lang.String emailAddress1, java.lang.String emailAddress2,
1542                    com.liferay.portal.service.ServiceContext serviceContext)
1543                    throws com.liferay.portal.kernel.exception.PortalException,
1544                            com.liferay.portal.kernel.exception.SystemException {
1545                    try {
1546                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1547                                            "updateEmailAddress", _updateEmailAddressParameterTypes40);
1548    
1549                            MethodHandler methodHandler = new MethodHandler(methodKey, userId,
1550                                            password, emailAddress1, emailAddress2, serviceContext);
1551    
1552                            Object returnObj = null;
1553    
1554                            try {
1555                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
1556                            }
1557                            catch (Exception e) {
1558                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1559                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1560                                    }
1561    
1562                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1563                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1564                                    }
1565    
1566                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1567                            }
1568    
1569                            return (com.liferay.portal.model.User)returnObj;
1570                    }
1571                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1572                            _log.error(se, se);
1573    
1574                            throw se;
1575                    }
1576            }
1577    
1578            public static com.liferay.portal.model.User updateIncompleteUser(
1579                    HttpPrincipal httpPrincipal, long companyId, boolean autoPassword,
1580                    java.lang.String password1, java.lang.String password2,
1581                    boolean autoScreenName, java.lang.String screenName,
1582                    java.lang.String emailAddress, long facebookId,
1583                    java.lang.String openId, java.util.Locale locale,
1584                    java.lang.String firstName, java.lang.String middleName,
1585                    java.lang.String lastName, int prefixId, int suffixId, boolean male,
1586                    int birthdayMonth, int birthdayDay, int birthdayYear,
1587                    java.lang.String jobTitle, boolean updateUserInformation,
1588                    boolean sendEmail,
1589                    com.liferay.portal.service.ServiceContext serviceContext)
1590                    throws com.liferay.portal.kernel.exception.PortalException,
1591                            com.liferay.portal.kernel.exception.SystemException {
1592                    try {
1593                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1594                                            "updateIncompleteUser",
1595                                            _updateIncompleteUserParameterTypes41);
1596    
1597                            MethodHandler methodHandler = new MethodHandler(methodKey,
1598                                            companyId, autoPassword, password1, password2,
1599                                            autoScreenName, screenName, emailAddress, facebookId,
1600                                            openId, locale, firstName, middleName, lastName, prefixId,
1601                                            suffixId, male, birthdayMonth, birthdayDay, birthdayYear,
1602                                            jobTitle, updateUserInformation, sendEmail, serviceContext);
1603    
1604                            Object returnObj = null;
1605    
1606                            try {
1607                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
1608                            }
1609                            catch (Exception e) {
1610                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1611                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1612                                    }
1613    
1614                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1615                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1616                                    }
1617    
1618                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1619                            }
1620    
1621                            return (com.liferay.portal.model.User)returnObj;
1622                    }
1623                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1624                            _log.error(se, se);
1625    
1626                            throw se;
1627                    }
1628            }
1629    
1630            public static com.liferay.portal.model.User updateLockoutById(
1631                    HttpPrincipal httpPrincipal, long userId, boolean lockout)
1632                    throws com.liferay.portal.kernel.exception.PortalException,
1633                            com.liferay.portal.kernel.exception.SystemException {
1634                    try {
1635                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1636                                            "updateLockoutById", _updateLockoutByIdParameterTypes42);
1637    
1638                            MethodHandler methodHandler = new MethodHandler(methodKey, userId,
1639                                            lockout);
1640    
1641                            Object returnObj = null;
1642    
1643                            try {
1644                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
1645                            }
1646                            catch (Exception e) {
1647                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1648                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1649                                    }
1650    
1651                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1652                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1653                                    }
1654    
1655                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1656                            }
1657    
1658                            return (com.liferay.portal.model.User)returnObj;
1659                    }
1660                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1661                            _log.error(se, se);
1662    
1663                            throw se;
1664                    }
1665            }
1666    
1667            public static com.liferay.portal.model.User updateOpenId(
1668                    HttpPrincipal httpPrincipal, long userId, java.lang.String openId)
1669                    throws com.liferay.portal.kernel.exception.PortalException,
1670                            com.liferay.portal.kernel.exception.SystemException {
1671                    try {
1672                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1673                                            "updateOpenId", _updateOpenIdParameterTypes43);
1674    
1675                            MethodHandler methodHandler = new MethodHandler(methodKey, userId,
1676                                            openId);
1677    
1678                            Object returnObj = null;
1679    
1680                            try {
1681                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
1682                            }
1683                            catch (Exception e) {
1684                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1685                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1686                                    }
1687    
1688                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1689                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1690                                    }
1691    
1692                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1693                            }
1694    
1695                            return (com.liferay.portal.model.User)returnObj;
1696                    }
1697                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1698                            _log.error(se, se);
1699    
1700                            throw se;
1701                    }
1702            }
1703    
1704            public static void updateOrganizations(HttpPrincipal httpPrincipal,
1705                    long userId, long[] organizationIds,
1706                    com.liferay.portal.service.ServiceContext serviceContext)
1707                    throws com.liferay.portal.kernel.exception.PortalException,
1708                            com.liferay.portal.kernel.exception.SystemException {
1709                    try {
1710                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1711                                            "updateOrganizations", _updateOrganizationsParameterTypes44);
1712    
1713                            MethodHandler methodHandler = new MethodHandler(methodKey, userId,
1714                                            organizationIds, serviceContext);
1715    
1716                            try {
1717                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
1718                            }
1719                            catch (Exception e) {
1720                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1721                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1722                                    }
1723    
1724                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1725                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1726                                    }
1727    
1728                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1729                            }
1730                    }
1731                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1732                            _log.error(se, se);
1733    
1734                            throw se;
1735                    }
1736            }
1737    
1738            public static com.liferay.portal.model.User updatePassword(
1739                    HttpPrincipal httpPrincipal, long userId, java.lang.String password1,
1740                    java.lang.String password2, boolean passwordReset)
1741                    throws com.liferay.portal.kernel.exception.PortalException,
1742                            com.liferay.portal.kernel.exception.SystemException {
1743                    try {
1744                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1745                                            "updatePassword", _updatePasswordParameterTypes45);
1746    
1747                            MethodHandler methodHandler = new MethodHandler(methodKey, userId,
1748                                            password1, password2, passwordReset);
1749    
1750                            Object returnObj = null;
1751    
1752                            try {
1753                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
1754                            }
1755                            catch (Exception e) {
1756                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1757                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1758                                    }
1759    
1760                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1761                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1762                                    }
1763    
1764                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1765                            }
1766    
1767                            return (com.liferay.portal.model.User)returnObj;
1768                    }
1769                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1770                            _log.error(se, se);
1771    
1772                            throw se;
1773                    }
1774            }
1775    
1776            public static com.liferay.portal.model.User updatePortrait(
1777                    HttpPrincipal httpPrincipal, long userId, byte[] bytes)
1778                    throws com.liferay.portal.kernel.exception.PortalException,
1779                            com.liferay.portal.kernel.exception.SystemException {
1780                    try {
1781                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1782                                            "updatePortrait", _updatePortraitParameterTypes46);
1783    
1784                            MethodHandler methodHandler = new MethodHandler(methodKey, userId,
1785                                            bytes);
1786    
1787                            Object returnObj = null;
1788    
1789                            try {
1790                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
1791                            }
1792                            catch (Exception e) {
1793                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1794                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1795                                    }
1796    
1797                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1798                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1799                                    }
1800    
1801                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1802                            }
1803    
1804                            return (com.liferay.portal.model.User)returnObj;
1805                    }
1806                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1807                            _log.error(se, se);
1808    
1809                            throw se;
1810                    }
1811            }
1812    
1813            public static com.liferay.portal.model.User updateReminderQuery(
1814                    HttpPrincipal httpPrincipal, long userId, java.lang.String question,
1815                    java.lang.String answer)
1816                    throws com.liferay.portal.kernel.exception.PortalException,
1817                            com.liferay.portal.kernel.exception.SystemException {
1818                    try {
1819                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1820                                            "updateReminderQuery", _updateReminderQueryParameterTypes47);
1821    
1822                            MethodHandler methodHandler = new MethodHandler(methodKey, userId,
1823                                            question, answer);
1824    
1825                            Object returnObj = null;
1826    
1827                            try {
1828                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
1829                            }
1830                            catch (Exception e) {
1831                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1832                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1833                                    }
1834    
1835                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1836                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1837                                    }
1838    
1839                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1840                            }
1841    
1842                            return (com.liferay.portal.model.User)returnObj;
1843                    }
1844                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1845                            _log.error(se, se);
1846    
1847                            throw se;
1848                    }
1849            }
1850    
1851            public static com.liferay.portal.model.User updateScreenName(
1852                    HttpPrincipal httpPrincipal, long userId, java.lang.String screenName)
1853                    throws com.liferay.portal.kernel.exception.PortalException,
1854                            com.liferay.portal.kernel.exception.SystemException {
1855                    try {
1856                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1857                                            "updateScreenName", _updateScreenNameParameterTypes48);
1858    
1859                            MethodHandler methodHandler = new MethodHandler(methodKey, userId,
1860                                            screenName);
1861    
1862                            Object returnObj = null;
1863    
1864                            try {
1865                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
1866                            }
1867                            catch (Exception e) {
1868                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1869                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1870                                    }
1871    
1872                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1873                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1874                                    }
1875    
1876                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1877                            }
1878    
1879                            return (com.liferay.portal.model.User)returnObj;
1880                    }
1881                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1882                            _log.error(se, se);
1883    
1884                            throw se;
1885                    }
1886            }
1887    
1888            public static com.liferay.portal.model.User updateStatus(
1889                    HttpPrincipal httpPrincipal, long userId, int status)
1890                    throws com.liferay.portal.kernel.exception.PortalException,
1891                            com.liferay.portal.kernel.exception.SystemException {
1892                    try {
1893                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1894                                            "updateStatus", _updateStatusParameterTypes49);
1895    
1896                            MethodHandler methodHandler = new MethodHandler(methodKey, userId,
1897                                            status);
1898    
1899                            Object returnObj = null;
1900    
1901                            try {
1902                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
1903                            }
1904                            catch (Exception e) {
1905                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1906                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1907                                    }
1908    
1909                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1910                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1911                                    }
1912    
1913                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1914                            }
1915    
1916                            return (com.liferay.portal.model.User)returnObj;
1917                    }
1918                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1919                            _log.error(se, se);
1920    
1921                            throw se;
1922                    }
1923            }
1924    
1925            public static com.liferay.portal.model.User updateUser(
1926                    HttpPrincipal httpPrincipal, long userId, java.lang.String oldPassword,
1927                    java.lang.String newPassword1, java.lang.String newPassword2,
1928                    boolean passwordReset, java.lang.String reminderQueryQuestion,
1929                    java.lang.String reminderQueryAnswer, java.lang.String screenName,
1930                    java.lang.String emailAddress, long facebookId,
1931                    java.lang.String openId, java.lang.String languageId,
1932                    java.lang.String timeZoneId, java.lang.String greeting,
1933                    java.lang.String comments, java.lang.String firstName,
1934                    java.lang.String middleName, java.lang.String lastName, int prefixId,
1935                    int suffixId, boolean male, int birthdayMonth, int birthdayDay,
1936                    int birthdayYear, java.lang.String smsSn, java.lang.String aimSn,
1937                    java.lang.String facebookSn, java.lang.String icqSn,
1938                    java.lang.String jabberSn, java.lang.String msnSn,
1939                    java.lang.String mySpaceSn, java.lang.String skypeSn,
1940                    java.lang.String twitterSn, java.lang.String ymSn,
1941                    java.lang.String jobTitle, long[] groupIds, long[] organizationIds,
1942                    long[] roleIds,
1943                    java.util.List<com.liferay.portal.model.UserGroupRole> userGroupRoles,
1944                    long[] userGroupIds,
1945                    java.util.List<com.liferay.portal.model.Address> addresses,
1946                    java.util.List<com.liferay.portal.model.EmailAddress> emailAddresses,
1947                    java.util.List<com.liferay.portal.model.Phone> phones,
1948                    java.util.List<com.liferay.portal.model.Website> websites,
1949                    java.util.List<com.liferay.portlet.announcements.model.AnnouncementsDelivery> announcementsDelivers,
1950                    com.liferay.portal.service.ServiceContext serviceContext)
1951                    throws com.liferay.portal.kernel.exception.PortalException,
1952                            com.liferay.portal.kernel.exception.SystemException {
1953                    try {
1954                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
1955                                            "updateUser", _updateUserParameterTypes50);
1956    
1957                            MethodHandler methodHandler = new MethodHandler(methodKey, userId,
1958                                            oldPassword, newPassword1, newPassword2, passwordReset,
1959                                            reminderQueryQuestion, reminderQueryAnswer, screenName,
1960                                            emailAddress, facebookId, openId, languageId, timeZoneId,
1961                                            greeting, comments, firstName, middleName, lastName,
1962                                            prefixId, suffixId, male, birthdayMonth, birthdayDay,
1963                                            birthdayYear, smsSn, aimSn, facebookSn, icqSn, jabberSn,
1964                                            msnSn, mySpaceSn, skypeSn, twitterSn, ymSn, jobTitle,
1965                                            groupIds, organizationIds, roleIds, userGroupRoles,
1966                                            userGroupIds, addresses, emailAddresses, phones, websites,
1967                                            announcementsDelivers, serviceContext);
1968    
1969                            Object returnObj = null;
1970    
1971                            try {
1972                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
1973                            }
1974                            catch (Exception e) {
1975                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
1976                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
1977                                    }
1978    
1979                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
1980                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
1981                                    }
1982    
1983                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
1984                            }
1985    
1986                            return (com.liferay.portal.model.User)returnObj;
1987                    }
1988                    catch (com.liferay.portal.kernel.exception.SystemException se) {
1989                            _log.error(se, se);
1990    
1991                            throw se;
1992                    }
1993            }
1994    
1995            public static com.liferay.portal.model.User updateUser(
1996                    HttpPrincipal httpPrincipal, long userId, java.lang.String oldPassword,
1997                    java.lang.String newPassword1, java.lang.String newPassword2,
1998                    boolean passwordReset, java.lang.String reminderQueryQuestion,
1999                    java.lang.String reminderQueryAnswer, java.lang.String screenName,
2000                    java.lang.String emailAddress, long facebookId,
2001                    java.lang.String openId, java.lang.String languageId,
2002                    java.lang.String timeZoneId, java.lang.String greeting,
2003                    java.lang.String comments, java.lang.String firstName,
2004                    java.lang.String middleName, java.lang.String lastName, int prefixId,
2005                    int suffixId, boolean male, int birthdayMonth, int birthdayDay,
2006                    int birthdayYear, java.lang.String smsSn, java.lang.String aimSn,
2007                    java.lang.String facebookSn, java.lang.String icqSn,
2008                    java.lang.String jabberSn, java.lang.String msnSn,
2009                    java.lang.String mySpaceSn, java.lang.String skypeSn,
2010                    java.lang.String twitterSn, java.lang.String ymSn,
2011                    java.lang.String jobTitle, long[] groupIds, long[] organizationIds,
2012                    long[] roleIds,
2013                    java.util.List<com.liferay.portal.model.UserGroupRole> userGroupRoles,
2014                    long[] userGroupIds,
2015                    com.liferay.portal.service.ServiceContext serviceContext)
2016                    throws com.liferay.portal.kernel.exception.PortalException,
2017                            com.liferay.portal.kernel.exception.SystemException {
2018                    try {
2019                            MethodKey methodKey = new MethodKey(UserServiceUtil.class.getName(),
2020                                            "updateUser", _updateUserParameterTypes51);
2021    
2022                            MethodHandler methodHandler = new MethodHandler(methodKey, userId,
2023                                            oldPassword, newPassword1, newPassword2, passwordReset,
2024                                            reminderQueryQuestion, reminderQueryAnswer, screenName,
2025                                            emailAddress, facebookId, openId, languageId, timeZoneId,
2026                                            greeting, comments, firstName, middleName, lastName,
2027                                            prefixId, suffixId, male, birthdayMonth, birthdayDay,
2028                                            birthdayYear, smsSn, aimSn, facebookSn, icqSn, jabberSn,
2029                                            msnSn, mySpaceSn, skypeSn, twitterSn, ymSn, jobTitle,
2030                                            groupIds, organizationIds, roleIds, userGroupRoles,
2031                                            userGroupIds, serviceContext);
2032    
2033                            Object returnObj = null;
2034    
2035                            try {
2036                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
2037                            }
2038                            catch (Exception e) {
2039                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
2040                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
2041                                    }
2042    
2043                                    if (e instanceof com.liferay.portal.kernel.exception.SystemException) {
2044                                            throw (com.liferay.portal.kernel.exception.SystemException)e;
2045                                    }
2046    
2047                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
2048                            }
2049    
2050                            return (com.liferay.portal.model.User)returnObj;
2051                    }
2052                    catch (com.liferay.portal.kernel.exception.SystemException se) {
2053                            _log.error(se, se);
2054    
2055                            throw se;
2056                    }
2057            }
2058    
2059            private static Log _log = LogFactoryUtil.getLog(UserServiceHttp.class);
2060            private static final Class<?>[] _addGroupUsersParameterTypes0 = new Class[] {
2061                            long.class, long[].class,
2062                            com.liferay.portal.service.ServiceContext.class
2063                    };
2064            private static final Class<?>[] _addOrganizationUsersParameterTypes1 = new Class[] {
2065                            long.class, long[].class
2066                    };
2067            private static final Class<?>[] _addPasswordPolicyUsersParameterTypes2 = new Class[] {
2068                            long.class, long[].class
2069                    };
2070            private static final Class<?>[] _addRoleUsersParameterTypes3 = new Class[] {
2071                            long.class, long[].class
2072                    };
2073            private static final Class<?>[] _addTeamUsersParameterTypes4 = new Class[] {
2074                            long.class, long[].class
2075                    };
2076            private static final Class<?>[] _addUserParameterTypes5 = new Class[] {
2077                            long.class, boolean.class, java.lang.String.class,
2078                            java.lang.String.class, boolean.class, java.lang.String.class,
2079                            java.lang.String.class, long.class, java.lang.String.class,
2080                            java.util.Locale.class, java.lang.String.class,
2081                            java.lang.String.class, java.lang.String.class, int.class, int.class,
2082                            boolean.class, int.class, int.class, int.class,
2083                            java.lang.String.class, long[].class, long[].class, long[].class,
2084                            long[].class, boolean.class,
2085                            com.liferay.portal.service.ServiceContext.class
2086                    };
2087            private static final Class<?>[] _addUserParameterTypes6 = new Class[] {
2088                            long.class, boolean.class, java.lang.String.class,
2089                            java.lang.String.class, boolean.class, java.lang.String.class,
2090                            java.lang.String.class, long.class, java.lang.String.class,
2091                            java.util.Locale.class, java.lang.String.class,
2092                            java.lang.String.class, java.lang.String.class, int.class, int.class,
2093                            boolean.class, int.class, int.class, int.class,
2094                            java.lang.String.class, long[].class, long[].class, long[].class,
2095                            long[].class, java.util.List.class, java.util.List.class,
2096                            java.util.List.class, java.util.List.class, java.util.List.class,
2097                            boolean.class, com.liferay.portal.service.ServiceContext.class
2098                    };
2099            private static final Class<?>[] _addUserGroupUsersParameterTypes7 = new Class[] {
2100                            long.class, long[].class
2101                    };
2102            private static final Class<?>[] _addUserWithWorkflowParameterTypes8 = new Class[] {
2103                            long.class, boolean.class, java.lang.String.class,
2104                            java.lang.String.class, boolean.class, java.lang.String.class,
2105                            java.lang.String.class, long.class, java.lang.String.class,
2106                            java.util.Locale.class, java.lang.String.class,
2107                            java.lang.String.class, java.lang.String.class, int.class, int.class,
2108                            boolean.class, int.class, int.class, int.class,
2109                            java.lang.String.class, long[].class, long[].class, long[].class,
2110                            long[].class, boolean.class,
2111                            com.liferay.portal.service.ServiceContext.class
2112                    };
2113            private static final Class<?>[] _addUserWithWorkflowParameterTypes9 = new Class[] {
2114                            long.class, boolean.class, java.lang.String.class,
2115                            java.lang.String.class, boolean.class, java.lang.String.class,
2116                            java.lang.String.class, long.class, java.lang.String.class,
2117                            java.util.Locale.class, java.lang.String.class,
2118                            java.lang.String.class, java.lang.String.class, int.class, int.class,
2119                            boolean.class, int.class, int.class, int.class,
2120                            java.lang.String.class, long[].class, long[].class, long[].class,
2121                            long[].class, java.util.List.class, java.util.List.class,
2122                            java.util.List.class, java.util.List.class, java.util.List.class,
2123                            boolean.class, com.liferay.portal.service.ServiceContext.class
2124                    };
2125            private static final Class<?>[] _deletePortraitParameterTypes10 = new Class[] {
2126                            long.class
2127                    };
2128            private static final Class<?>[] _deleteRoleUserParameterTypes11 = new Class[] {
2129                            long.class, long.class
2130                    };
2131            private static final Class<?>[] _deleteUserParameterTypes12 = new Class[] {
2132                            long.class
2133                    };
2134            private static final Class<?>[] _getCompanyUsersParameterTypes13 = new Class[] {
2135                            long.class, int.class, int.class
2136                    };
2137            private static final Class<?>[] _getCompanyUsersCountParameterTypes14 = new Class[] {
2138                            long.class
2139                    };
2140            private static final Class<?>[] _getDefaultUserIdParameterTypes15 = new Class[] {
2141                            long.class
2142                    };
2143            private static final Class<?>[] _getGroupUserIdsParameterTypes16 = new Class[] {
2144                            long.class
2145                    };
2146            private static final Class<?>[] _getGroupUsersParameterTypes17 = new Class[] {
2147                            long.class
2148                    };
2149            private static final Class<?>[] _getOrganizationUserIdsParameterTypes18 = new Class[] {
2150                            long.class
2151                    };
2152            private static final Class<?>[] _getOrganizationUsersParameterTypes19 = new Class[] {
2153                            long.class
2154                    };
2155            private static final Class<?>[] _getRoleUserIdsParameterTypes20 = new Class[] {
2156                            long.class
2157                    };
2158            private static final Class<?>[] _getUserByEmailAddressParameterTypes21 = new Class[] {
2159                            long.class, java.lang.String.class
2160                    };
2161            private static final Class<?>[] _getUserByIdParameterTypes22 = new Class[] {
2162                            long.class
2163                    };
2164            private static final Class<?>[] _getUserByScreenNameParameterTypes23 = new Class[] {
2165                            long.class, java.lang.String.class
2166                    };
2167            private static final Class<?>[] _getUserGroupUsersParameterTypes24 = new Class[] {
2168                            long.class
2169                    };
2170            private static final Class<?>[] _getUserIdByEmailAddressParameterTypes25 = new Class[] {
2171                            long.class, java.lang.String.class
2172                    };
2173            private static final Class<?>[] _getUserIdByScreenNameParameterTypes26 = new Class[] {
2174                            long.class, java.lang.String.class
2175                    };
2176            private static final Class<?>[] _hasGroupUserParameterTypes27 = new Class[] {
2177                            long.class, long.class
2178                    };
2179            private static final Class<?>[] _hasRoleUserParameterTypes28 = new Class[] {
2180                            long.class, long.class
2181                    };
2182            private static final Class<?>[] _hasRoleUserParameterTypes29 = new Class[] {
2183                            long.class, java.lang.String.class, long.class, boolean.class
2184                    };
2185            private static final Class<?>[] _setRoleUsersParameterTypes30 = new Class[] {
2186                            long.class, long[].class
2187                    };
2188            private static final Class<?>[] _setUserGroupUsersParameterTypes31 = new Class[] {
2189                            long.class, long[].class
2190                    };
2191            private static final Class<?>[] _unsetGroupTeamsUsersParameterTypes32 = new Class[] {
2192                            long.class, long[].class
2193                    };
2194            private static final Class<?>[] _unsetGroupUsersParameterTypes33 = new Class[] {
2195                            long.class, long[].class,
2196                            com.liferay.portal.service.ServiceContext.class
2197                    };
2198            private static final Class<?>[] _unsetOrganizationUsersParameterTypes34 = new Class[] {
2199                            long.class, long[].class
2200                    };
2201            private static final Class<?>[] _unsetPasswordPolicyUsersParameterTypes35 = new Class[] {
2202                            long.class, long[].class
2203                    };
2204            private static final Class<?>[] _unsetRoleUsersParameterTypes36 = new Class[] {
2205                            long.class, long[].class
2206                    };
2207            private static final Class<?>[] _unsetTeamUsersParameterTypes37 = new Class[] {
2208                            long.class, long[].class
2209                    };
2210            private static final Class<?>[] _unsetUserGroupUsersParameterTypes38 = new Class[] {
2211                            long.class, long[].class
2212                    };
2213            private static final Class<?>[] _updateAgreedToTermsOfUseParameterTypes39 = new Class[] {
2214                            long.class, boolean.class
2215                    };
2216            private static final Class<?>[] _updateEmailAddressParameterTypes40 = new Class[] {
2217                            long.class, java.lang.String.class, java.lang.String.class,
2218                            java.lang.String.class,
2219                            com.liferay.portal.service.ServiceContext.class
2220                    };
2221            private static final Class<?>[] _updateIncompleteUserParameterTypes41 = new Class[] {
2222                            long.class, boolean.class, java.lang.String.class,
2223                            java.lang.String.class, boolean.class, java.lang.String.class,
2224                            java.lang.String.class, long.class, java.lang.String.class,
2225                            java.util.Locale.class, java.lang.String.class,
2226                            java.lang.String.class, java.lang.String.class, int.class, int.class,
2227                            boolean.class, int.class, int.class, int.class,
2228                            java.lang.String.class, boolean.class, boolean.class,
2229                            com.liferay.portal.service.ServiceContext.class
2230                    };
2231            private static final Class<?>[] _updateLockoutByIdParameterTypes42 = new Class[] {
2232                            long.class, boolean.class
2233                    };
2234            private static final Class<?>[] _updateOpenIdParameterTypes43 = new Class[] {
2235                            long.class, java.lang.String.class
2236                    };
2237            private static final Class<?>[] _updateOrganizationsParameterTypes44 = new Class[] {
2238                            long.class, long[].class,
2239                            com.liferay.portal.service.ServiceContext.class
2240                    };
2241            private static final Class<?>[] _updatePasswordParameterTypes45 = new Class[] {
2242                            long.class, java.lang.String.class, java.lang.String.class,
2243                            boolean.class
2244                    };
2245            private static final Class<?>[] _updatePortraitParameterTypes46 = new Class[] {
2246                            long.class, byte[].class
2247                    };
2248            private static final Class<?>[] _updateReminderQueryParameterTypes47 = new Class[] {
2249                            long.class, java.lang.String.class, java.lang.String.class
2250                    };
2251            private static final Class<?>[] _updateScreenNameParameterTypes48 = new Class[] {
2252                            long.class, java.lang.String.class
2253                    };
2254            private static final Class<?>[] _updateStatusParameterTypes49 = new Class[] {
2255                            long.class, int.class
2256                    };
2257            private static final Class<?>[] _updateUserParameterTypes50 = new Class[] {
2258                            long.class, java.lang.String.class, java.lang.String.class,
2259                            java.lang.String.class, boolean.class, java.lang.String.class,
2260                            java.lang.String.class, java.lang.String.class,
2261                            java.lang.String.class, long.class, java.lang.String.class,
2262                            java.lang.String.class, java.lang.String.class,
2263                            java.lang.String.class, java.lang.String.class,
2264                            java.lang.String.class, java.lang.String.class,
2265                            java.lang.String.class, int.class, int.class, boolean.class,
2266                            int.class, int.class, int.class, java.lang.String.class,
2267                            java.lang.String.class, java.lang.String.class,
2268                            java.lang.String.class, java.lang.String.class,
2269                            java.lang.String.class, java.lang.String.class,
2270                            java.lang.String.class, java.lang.String.class,
2271                            java.lang.String.class, java.lang.String.class, long[].class,
2272                            long[].class, long[].class, java.util.List.class, long[].class,
2273                            java.util.List.class, java.util.List.class, java.util.List.class,
2274                            java.util.List.class, java.util.List.class,
2275                            com.liferay.portal.service.ServiceContext.class
2276                    };
2277            private static final Class<?>[] _updateUserParameterTypes51 = new Class[] {
2278                            long.class, java.lang.String.class, java.lang.String.class,
2279                            java.lang.String.class, boolean.class, java.lang.String.class,
2280                            java.lang.String.class, java.lang.String.class,
2281                            java.lang.String.class, long.class, java.lang.String.class,
2282                            java.lang.String.class, java.lang.String.class,
2283                            java.lang.String.class, java.lang.String.class,
2284                            java.lang.String.class, java.lang.String.class,
2285                            java.lang.String.class, int.class, int.class, boolean.class,
2286                            int.class, int.class, int.class, java.lang.String.class,
2287                            java.lang.String.class, java.lang.String.class,
2288                            java.lang.String.class, java.lang.String.class,
2289                            java.lang.String.class, java.lang.String.class,
2290                            java.lang.String.class, java.lang.String.class,
2291                            java.lang.String.class, java.lang.String.class, long[].class,
2292                            long[].class, long[].class, java.util.List.class, long[].class,
2293                            com.liferay.portal.service.ServiceContext.class
2294                    };
2295    }