001    /**
002     * Copyright (c) 2000-present 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 aQute.bnd.annotation.ProviderType;
018    
019    import com.liferay.portal.kernel.log.Log;
020    import com.liferay.portal.kernel.log.LogFactoryUtil;
021    import com.liferay.portal.kernel.util.MethodHandler;
022    import com.liferay.portal.kernel.util.MethodKey;
023    import com.liferay.portal.security.auth.HttpPrincipal;
024    import com.liferay.portal.service.OrganizationServiceUtil;
025    
026    /**
027     * Provides the HTTP utility for the
028     * {@link com.liferay.portal.service.OrganizationServiceUtil} service utility. The
029     * static methods of this class calls the same methods of the service utility.
030     * However, the signatures are different because it requires an additional
031     * {@link com.liferay.portal.security.auth.HttpPrincipal} parameter.
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 OrganizationServiceSoap
050     * @see com.liferay.portal.security.auth.HttpPrincipal
051     * @see com.liferay.portal.service.OrganizationServiceUtil
052     * @generated
053     */
054    @ProviderType
055    public class OrganizationServiceHttp {
056            public static void addGroupOrganizations(HttpPrincipal httpPrincipal,
057                    long groupId, long[] organizationIds)
058                    throws com.liferay.portal.kernel.exception.PortalException {
059                    try {
060                            MethodKey methodKey = new MethodKey(OrganizationServiceUtil.class,
061                                            "addGroupOrganizations",
062                                            _addGroupOrganizationsParameterTypes0);
063    
064                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
065                                            organizationIds);
066    
067                            try {
068                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
069                            }
070                            catch (Exception e) {
071                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
072                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
073                                    }
074    
075                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
076                            }
077                    }
078                    catch (com.liferay.portal.kernel.exception.SystemException se) {
079                            _log.error(se, se);
080    
081                            throw se;
082                    }
083            }
084    
085            public static com.liferay.portal.model.Organization addOrganization(
086                    HttpPrincipal httpPrincipal, long parentOrganizationId,
087                    java.lang.String name, java.lang.String type, boolean recursable,
088                    long regionId, long countryId, int statusId, java.lang.String comments,
089                    boolean site,
090                    java.util.List<com.liferay.portal.model.Address> addresses,
091                    java.util.List<com.liferay.portal.model.EmailAddress> emailAddresses,
092                    java.util.List<com.liferay.portal.model.OrgLabor> orgLabors,
093                    java.util.List<com.liferay.portal.model.Phone> phones,
094                    java.util.List<com.liferay.portal.model.Website> websites,
095                    com.liferay.portal.service.ServiceContext serviceContext)
096                    throws com.liferay.portal.kernel.exception.PortalException {
097                    try {
098                            MethodKey methodKey = new MethodKey(OrganizationServiceUtil.class,
099                                            "addOrganization", _addOrganizationParameterTypes1);
100    
101                            MethodHandler methodHandler = new MethodHandler(methodKey,
102                                            parentOrganizationId, name, type, recursable, regionId,
103                                            countryId, statusId, comments, site, addresses,
104                                            emailAddresses, orgLabors, phones, websites, serviceContext);
105    
106                            Object returnObj = null;
107    
108                            try {
109                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
110                            }
111                            catch (Exception e) {
112                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
113                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
114                                    }
115    
116                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
117                            }
118    
119                            return (com.liferay.portal.model.Organization)returnObj;
120                    }
121                    catch (com.liferay.portal.kernel.exception.SystemException se) {
122                            _log.error(se, se);
123    
124                            throw se;
125                    }
126            }
127    
128            public static com.liferay.portal.model.Organization addOrganization(
129                    HttpPrincipal httpPrincipal, long parentOrganizationId,
130                    java.lang.String name, java.lang.String type, boolean recursable,
131                    long regionId, long countryId, int statusId, java.lang.String comments,
132                    boolean site, com.liferay.portal.service.ServiceContext serviceContext)
133                    throws com.liferay.portal.kernel.exception.PortalException {
134                    try {
135                            MethodKey methodKey = new MethodKey(OrganizationServiceUtil.class,
136                                            "addOrganization", _addOrganizationParameterTypes2);
137    
138                            MethodHandler methodHandler = new MethodHandler(methodKey,
139                                            parentOrganizationId, name, type, recursable, regionId,
140                                            countryId, statusId, comments, site, serviceContext);
141    
142                            Object returnObj = null;
143    
144                            try {
145                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
146                            }
147                            catch (Exception e) {
148                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
149                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
150                                    }
151    
152                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
153                            }
154    
155                            return (com.liferay.portal.model.Organization)returnObj;
156                    }
157                    catch (com.liferay.portal.kernel.exception.SystemException se) {
158                            _log.error(se, se);
159    
160                            throw se;
161                    }
162            }
163    
164            public static com.liferay.portal.model.Organization addOrganization(
165                    HttpPrincipal httpPrincipal, long parentOrganizationId,
166                    java.lang.String name, java.lang.String type, long regionId,
167                    long countryId, int statusId, java.lang.String comments, boolean site,
168                    java.util.List<com.liferay.portal.model.Address> addresses,
169                    java.util.List<com.liferay.portal.model.EmailAddress> emailAddresses,
170                    java.util.List<com.liferay.portal.model.OrgLabor> orgLabors,
171                    java.util.List<com.liferay.portal.model.Phone> phones,
172                    java.util.List<com.liferay.portal.model.Website> websites,
173                    com.liferay.portal.service.ServiceContext serviceContext)
174                    throws com.liferay.portal.kernel.exception.PortalException {
175                    try {
176                            MethodKey methodKey = new MethodKey(OrganizationServiceUtil.class,
177                                            "addOrganization", _addOrganizationParameterTypes3);
178    
179                            MethodHandler methodHandler = new MethodHandler(methodKey,
180                                            parentOrganizationId, name, type, regionId, countryId,
181                                            statusId, comments, site, addresses, emailAddresses,
182                                            orgLabors, phones, websites, serviceContext);
183    
184                            Object returnObj = null;
185    
186                            try {
187                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
188                            }
189                            catch (Exception e) {
190                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
191                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
192                                    }
193    
194                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
195                            }
196    
197                            return (com.liferay.portal.model.Organization)returnObj;
198                    }
199                    catch (com.liferay.portal.kernel.exception.SystemException se) {
200                            _log.error(se, se);
201    
202                            throw se;
203                    }
204            }
205    
206            public static com.liferay.portal.model.Organization addOrganization(
207                    HttpPrincipal httpPrincipal, long parentOrganizationId,
208                    java.lang.String name, java.lang.String type, long regionId,
209                    long countryId, int statusId, java.lang.String comments, boolean site,
210                    com.liferay.portal.service.ServiceContext serviceContext)
211                    throws com.liferay.portal.kernel.exception.PortalException {
212                    try {
213                            MethodKey methodKey = new MethodKey(OrganizationServiceUtil.class,
214                                            "addOrganization", _addOrganizationParameterTypes4);
215    
216                            MethodHandler methodHandler = new MethodHandler(methodKey,
217                                            parentOrganizationId, name, type, regionId, countryId,
218                                            statusId, comments, site, serviceContext);
219    
220                            Object returnObj = null;
221    
222                            try {
223                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
224                            }
225                            catch (Exception e) {
226                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
227                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
228                                    }
229    
230                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
231                            }
232    
233                            return (com.liferay.portal.model.Organization)returnObj;
234                    }
235                    catch (com.liferay.portal.kernel.exception.SystemException se) {
236                            _log.error(se, se);
237    
238                            throw se;
239                    }
240            }
241    
242            public static void addPasswordPolicyOrganizations(
243                    HttpPrincipal httpPrincipal, long passwordPolicyId,
244                    long[] organizationIds)
245                    throws com.liferay.portal.kernel.exception.PortalException {
246                    try {
247                            MethodKey methodKey = new MethodKey(OrganizationServiceUtil.class,
248                                            "addPasswordPolicyOrganizations",
249                                            _addPasswordPolicyOrganizationsParameterTypes5);
250    
251                            MethodHandler methodHandler = new MethodHandler(methodKey,
252                                            passwordPolicyId, organizationIds);
253    
254                            try {
255                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
256                            }
257                            catch (Exception e) {
258                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
259                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
260                                    }
261    
262                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
263                            }
264                    }
265                    catch (com.liferay.portal.kernel.exception.SystemException se) {
266                            _log.error(se, se);
267    
268                            throw se;
269                    }
270            }
271    
272            public static void deleteLogo(HttpPrincipal httpPrincipal,
273                    long organizationId)
274                    throws com.liferay.portal.kernel.exception.PortalException {
275                    try {
276                            MethodKey methodKey = new MethodKey(OrganizationServiceUtil.class,
277                                            "deleteLogo", _deleteLogoParameterTypes6);
278    
279                            MethodHandler methodHandler = new MethodHandler(methodKey,
280                                            organizationId);
281    
282                            try {
283                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
284                            }
285                            catch (Exception e) {
286                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
287                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
288                                    }
289    
290                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
291                            }
292                    }
293                    catch (com.liferay.portal.kernel.exception.SystemException se) {
294                            _log.error(se, se);
295    
296                            throw se;
297                    }
298            }
299    
300            public static void deleteOrganization(HttpPrincipal httpPrincipal,
301                    long organizationId)
302                    throws com.liferay.portal.kernel.exception.PortalException {
303                    try {
304                            MethodKey methodKey = new MethodKey(OrganizationServiceUtil.class,
305                                            "deleteOrganization", _deleteOrganizationParameterTypes7);
306    
307                            MethodHandler methodHandler = new MethodHandler(methodKey,
308                                            organizationId);
309    
310                            try {
311                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
312                            }
313                            catch (Exception e) {
314                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
315                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
316                                    }
317    
318                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
319                            }
320                    }
321                    catch (com.liferay.portal.kernel.exception.SystemException se) {
322                            _log.error(se, se);
323    
324                            throw se;
325                    }
326            }
327    
328            public static java.util.List<com.liferay.portal.model.Organization> getManageableOrganizations(
329                    HttpPrincipal httpPrincipal, java.lang.String actionId, int max)
330                    throws com.liferay.portal.kernel.exception.PortalException {
331                    try {
332                            MethodKey methodKey = new MethodKey(OrganizationServiceUtil.class,
333                                            "getManageableOrganizations",
334                                            _getManageableOrganizationsParameterTypes8);
335    
336                            MethodHandler methodHandler = new MethodHandler(methodKey,
337                                            actionId, max);
338    
339                            Object returnObj = null;
340    
341                            try {
342                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
343                            }
344                            catch (Exception e) {
345                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
346                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
347                                    }
348    
349                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
350                            }
351    
352                            return (java.util.List<com.liferay.portal.model.Organization>)returnObj;
353                    }
354                    catch (com.liferay.portal.kernel.exception.SystemException se) {
355                            _log.error(se, se);
356    
357                            throw se;
358                    }
359            }
360    
361            public static com.liferay.portal.model.Organization getOrganization(
362                    HttpPrincipal httpPrincipal, long organizationId)
363                    throws com.liferay.portal.kernel.exception.PortalException {
364                    try {
365                            MethodKey methodKey = new MethodKey(OrganizationServiceUtil.class,
366                                            "getOrganization", _getOrganizationParameterTypes9);
367    
368                            MethodHandler methodHandler = new MethodHandler(methodKey,
369                                            organizationId);
370    
371                            Object returnObj = null;
372    
373                            try {
374                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
375                            }
376                            catch (Exception e) {
377                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
378                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
379                                    }
380    
381                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
382                            }
383    
384                            return (com.liferay.portal.model.Organization)returnObj;
385                    }
386                    catch (com.liferay.portal.kernel.exception.SystemException se) {
387                            _log.error(se, se);
388    
389                            throw se;
390                    }
391            }
392    
393            public static long getOrganizationId(HttpPrincipal httpPrincipal,
394                    long companyId, java.lang.String name)
395                    throws com.liferay.portal.kernel.exception.PortalException {
396                    try {
397                            MethodKey methodKey = new MethodKey(OrganizationServiceUtil.class,
398                                            "getOrganizationId", _getOrganizationIdParameterTypes10);
399    
400                            MethodHandler methodHandler = new MethodHandler(methodKey,
401                                            companyId, name);
402    
403                            Object returnObj = null;
404    
405                            try {
406                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
407                            }
408                            catch (Exception e) {
409                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
410                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
411                                    }
412    
413                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
414                            }
415    
416                            return ((Long)returnObj).longValue();
417                    }
418                    catch (com.liferay.portal.kernel.exception.SystemException se) {
419                            _log.error(se, se);
420    
421                            throw se;
422                    }
423            }
424    
425            public static java.util.List<com.liferay.portal.model.Organization> getOrganizations(
426                    HttpPrincipal httpPrincipal, long companyId, long parentOrganizationId) {
427                    try {
428                            MethodKey methodKey = new MethodKey(OrganizationServiceUtil.class,
429                                            "getOrganizations", _getOrganizationsParameterTypes11);
430    
431                            MethodHandler methodHandler = new MethodHandler(methodKey,
432                                            companyId, parentOrganizationId);
433    
434                            Object returnObj = null;
435    
436                            try {
437                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
438                            }
439                            catch (Exception e) {
440                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
441                            }
442    
443                            return (java.util.List<com.liferay.portal.model.Organization>)returnObj;
444                    }
445                    catch (com.liferay.portal.kernel.exception.SystemException se) {
446                            _log.error(se, se);
447    
448                            throw se;
449                    }
450            }
451    
452            public static java.util.List<com.liferay.portal.model.Organization> getOrganizations(
453                    HttpPrincipal httpPrincipal, long companyId, long parentOrganizationId,
454                    int start, int end) {
455                    try {
456                            MethodKey methodKey = new MethodKey(OrganizationServiceUtil.class,
457                                            "getOrganizations", _getOrganizationsParameterTypes12);
458    
459                            MethodHandler methodHandler = new MethodHandler(methodKey,
460                                            companyId, parentOrganizationId, start, end);
461    
462                            Object returnObj = null;
463    
464                            try {
465                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
466                            }
467                            catch (Exception e) {
468                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
469                            }
470    
471                            return (java.util.List<com.liferay.portal.model.Organization>)returnObj;
472                    }
473                    catch (com.liferay.portal.kernel.exception.SystemException se) {
474                            _log.error(se, se);
475    
476                            throw se;
477                    }
478            }
479    
480            public static int getOrganizationsCount(HttpPrincipal httpPrincipal,
481                    long companyId, long parentOrganizationId) {
482                    try {
483                            MethodKey methodKey = new MethodKey(OrganizationServiceUtil.class,
484                                            "getOrganizationsCount",
485                                            _getOrganizationsCountParameterTypes13);
486    
487                            MethodHandler methodHandler = new MethodHandler(methodKey,
488                                            companyId, parentOrganizationId);
489    
490                            Object returnObj = null;
491    
492                            try {
493                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
494                            }
495                            catch (Exception e) {
496                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
497                            }
498    
499                            return ((Integer)returnObj).intValue();
500                    }
501                    catch (com.liferay.portal.kernel.exception.SystemException se) {
502                            _log.error(se, se);
503    
504                            throw se;
505                    }
506            }
507    
508            public static java.util.List<com.liferay.portal.model.Organization> getUserOrganizations(
509                    HttpPrincipal httpPrincipal, long userId)
510                    throws com.liferay.portal.kernel.exception.PortalException {
511                    try {
512                            MethodKey methodKey = new MethodKey(OrganizationServiceUtil.class,
513                                            "getUserOrganizations",
514                                            _getUserOrganizationsParameterTypes14);
515    
516                            MethodHandler methodHandler = new MethodHandler(methodKey, userId);
517    
518                            Object returnObj = null;
519    
520                            try {
521                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
522                            }
523                            catch (Exception e) {
524                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
525                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
526                                    }
527    
528                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
529                            }
530    
531                            return (java.util.List<com.liferay.portal.model.Organization>)returnObj;
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 setGroupOrganizations(HttpPrincipal httpPrincipal,
541                    long groupId, long[] organizationIds)
542                    throws com.liferay.portal.kernel.exception.PortalException {
543                    try {
544                            MethodKey methodKey = new MethodKey(OrganizationServiceUtil.class,
545                                            "setGroupOrganizations",
546                                            _setGroupOrganizationsParameterTypes15);
547    
548                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
549                                            organizationIds);
550    
551                            try {
552                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
553                            }
554                            catch (Exception e) {
555                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
556                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
557                                    }
558    
559                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
560                            }
561                    }
562                    catch (com.liferay.portal.kernel.exception.SystemException se) {
563                            _log.error(se, se);
564    
565                            throw se;
566                    }
567            }
568    
569            public static void unsetGroupOrganizations(HttpPrincipal httpPrincipal,
570                    long groupId, long[] organizationIds)
571                    throws com.liferay.portal.kernel.exception.PortalException {
572                    try {
573                            MethodKey methodKey = new MethodKey(OrganizationServiceUtil.class,
574                                            "unsetGroupOrganizations",
575                                            _unsetGroupOrganizationsParameterTypes16);
576    
577                            MethodHandler methodHandler = new MethodHandler(methodKey, groupId,
578                                            organizationIds);
579    
580                            try {
581                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
582                            }
583                            catch (Exception e) {
584                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
585                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
586                                    }
587    
588                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
589                            }
590                    }
591                    catch (com.liferay.portal.kernel.exception.SystemException se) {
592                            _log.error(se, se);
593    
594                            throw se;
595                    }
596            }
597    
598            public static void unsetPasswordPolicyOrganizations(
599                    HttpPrincipal httpPrincipal, long passwordPolicyId,
600                    long[] organizationIds)
601                    throws com.liferay.portal.kernel.exception.PortalException {
602                    try {
603                            MethodKey methodKey = new MethodKey(OrganizationServiceUtil.class,
604                                            "unsetPasswordPolicyOrganizations",
605                                            _unsetPasswordPolicyOrganizationsParameterTypes17);
606    
607                            MethodHandler methodHandler = new MethodHandler(methodKey,
608                                            passwordPolicyId, organizationIds);
609    
610                            try {
611                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
612                            }
613                            catch (Exception e) {
614                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
615                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
616                                    }
617    
618                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
619                            }
620                    }
621                    catch (com.liferay.portal.kernel.exception.SystemException se) {
622                            _log.error(se, se);
623    
624                            throw se;
625                    }
626            }
627    
628            public static com.liferay.portal.model.Organization updateOrganization(
629                    HttpPrincipal httpPrincipal, long organizationId,
630                    long parentOrganizationId, java.lang.String name,
631                    java.lang.String type, boolean recursable, long regionId,
632                    long countryId, int statusId, java.lang.String comments, boolean site,
633                    java.util.List<com.liferay.portal.model.Address> addresses,
634                    java.util.List<com.liferay.portal.model.EmailAddress> emailAddresses,
635                    java.util.List<com.liferay.portal.model.OrgLabor> orgLabors,
636                    java.util.List<com.liferay.portal.model.Phone> phones,
637                    java.util.List<com.liferay.portal.model.Website> websites,
638                    com.liferay.portal.service.ServiceContext serviceContext)
639                    throws com.liferay.portal.kernel.exception.PortalException {
640                    try {
641                            MethodKey methodKey = new MethodKey(OrganizationServiceUtil.class,
642                                            "updateOrganization", _updateOrganizationParameterTypes18);
643    
644                            MethodHandler methodHandler = new MethodHandler(methodKey,
645                                            organizationId, parentOrganizationId, name, type,
646                                            recursable, regionId, countryId, statusId, comments, site,
647                                            addresses, emailAddresses, orgLabors, phones, websites,
648                                            serviceContext);
649    
650                            Object returnObj = null;
651    
652                            try {
653                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
654                            }
655                            catch (Exception e) {
656                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
657                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
658                                    }
659    
660                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
661                            }
662    
663                            return (com.liferay.portal.model.Organization)returnObj;
664                    }
665                    catch (com.liferay.portal.kernel.exception.SystemException se) {
666                            _log.error(se, se);
667    
668                            throw se;
669                    }
670            }
671    
672            public static com.liferay.portal.model.Organization updateOrganization(
673                    HttpPrincipal httpPrincipal, long organizationId,
674                    long parentOrganizationId, java.lang.String name,
675                    java.lang.String type, boolean recursable, long regionId,
676                    long countryId, int statusId, java.lang.String comments, boolean site,
677                    com.liferay.portal.service.ServiceContext serviceContext)
678                    throws com.liferay.portal.kernel.exception.PortalException {
679                    try {
680                            MethodKey methodKey = new MethodKey(OrganizationServiceUtil.class,
681                                            "updateOrganization", _updateOrganizationParameterTypes19);
682    
683                            MethodHandler methodHandler = new MethodHandler(methodKey,
684                                            organizationId, parentOrganizationId, name, type,
685                                            recursable, regionId, countryId, statusId, comments, site,
686                                            serviceContext);
687    
688                            Object returnObj = null;
689    
690                            try {
691                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
692                            }
693                            catch (Exception e) {
694                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
695                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
696                                    }
697    
698                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
699                            }
700    
701                            return (com.liferay.portal.model.Organization)returnObj;
702                    }
703                    catch (com.liferay.portal.kernel.exception.SystemException se) {
704                            _log.error(se, se);
705    
706                            throw se;
707                    }
708            }
709    
710            public static com.liferay.portal.model.Organization updateOrganization(
711                    HttpPrincipal httpPrincipal, long organizationId,
712                    long parentOrganizationId, java.lang.String name,
713                    java.lang.String type, long regionId, long countryId, int statusId,
714                    java.lang.String comments, boolean logo, byte[] logoBytes,
715                    boolean site,
716                    java.util.List<com.liferay.portal.model.Address> addresses,
717                    java.util.List<com.liferay.portal.model.EmailAddress> emailAddresses,
718                    java.util.List<com.liferay.portal.model.OrgLabor> orgLabors,
719                    java.util.List<com.liferay.portal.model.Phone> phones,
720                    java.util.List<com.liferay.portal.model.Website> websites,
721                    com.liferay.portal.service.ServiceContext serviceContext)
722                    throws com.liferay.portal.kernel.exception.PortalException {
723                    try {
724                            MethodKey methodKey = new MethodKey(OrganizationServiceUtil.class,
725                                            "updateOrganization", _updateOrganizationParameterTypes20);
726    
727                            MethodHandler methodHandler = new MethodHandler(methodKey,
728                                            organizationId, parentOrganizationId, name, type, regionId,
729                                            countryId, statusId, comments, logo, logoBytes, site,
730                                            addresses, emailAddresses, orgLabors, phones, websites,
731                                            serviceContext);
732    
733                            Object returnObj = null;
734    
735                            try {
736                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
737                            }
738                            catch (Exception e) {
739                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
740                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
741                                    }
742    
743                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
744                            }
745    
746                            return (com.liferay.portal.model.Organization)returnObj;
747                    }
748                    catch (com.liferay.portal.kernel.exception.SystemException se) {
749                            _log.error(se, se);
750    
751                            throw se;
752                    }
753            }
754    
755            public static com.liferay.portal.model.Organization updateOrganization(
756                    HttpPrincipal httpPrincipal, long organizationId,
757                    long parentOrganizationId, java.lang.String name,
758                    java.lang.String type, long regionId, long countryId, int statusId,
759                    java.lang.String comments, boolean site,
760                    java.util.List<com.liferay.portal.model.Address> addresses,
761                    java.util.List<com.liferay.portal.model.EmailAddress> emailAddresses,
762                    java.util.List<com.liferay.portal.model.OrgLabor> orgLabors,
763                    java.util.List<com.liferay.portal.model.Phone> phones,
764                    java.util.List<com.liferay.portal.model.Website> websites,
765                    com.liferay.portal.service.ServiceContext serviceContext)
766                    throws com.liferay.portal.kernel.exception.PortalException {
767                    try {
768                            MethodKey methodKey = new MethodKey(OrganizationServiceUtil.class,
769                                            "updateOrganization", _updateOrganizationParameterTypes21);
770    
771                            MethodHandler methodHandler = new MethodHandler(methodKey,
772                                            organizationId, parentOrganizationId, name, type, regionId,
773                                            countryId, statusId, comments, site, addresses,
774                                            emailAddresses, orgLabors, phones, websites, serviceContext);
775    
776                            Object returnObj = null;
777    
778                            try {
779                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
780                            }
781                            catch (Exception e) {
782                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
783                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
784                                    }
785    
786                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
787                            }
788    
789                            return (com.liferay.portal.model.Organization)returnObj;
790                    }
791                    catch (com.liferay.portal.kernel.exception.SystemException se) {
792                            _log.error(se, se);
793    
794                            throw se;
795                    }
796            }
797    
798            public static com.liferay.portal.model.Organization updateOrganization(
799                    HttpPrincipal httpPrincipal, long organizationId,
800                    long parentOrganizationId, java.lang.String name,
801                    java.lang.String type, long regionId, long countryId, int statusId,
802                    java.lang.String comments, boolean site,
803                    com.liferay.portal.service.ServiceContext serviceContext)
804                    throws com.liferay.portal.kernel.exception.PortalException {
805                    try {
806                            MethodKey methodKey = new MethodKey(OrganizationServiceUtil.class,
807                                            "updateOrganization", _updateOrganizationParameterTypes22);
808    
809                            MethodHandler methodHandler = new MethodHandler(methodKey,
810                                            organizationId, parentOrganizationId, name, type, regionId,
811                                            countryId, statusId, comments, site, serviceContext);
812    
813                            Object returnObj = null;
814    
815                            try {
816                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
817                            }
818                            catch (Exception e) {
819                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
820                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
821                                    }
822    
823                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
824                            }
825    
826                            return (com.liferay.portal.model.Organization)returnObj;
827                    }
828                    catch (com.liferay.portal.kernel.exception.SystemException se) {
829                            _log.error(se, se);
830    
831                            throw se;
832                    }
833            }
834    
835            private static Log _log = LogFactoryUtil.getLog(OrganizationServiceHttp.class);
836            private static final Class<?>[] _addGroupOrganizationsParameterTypes0 = new Class[] {
837                            long.class, long[].class
838                    };
839            private static final Class<?>[] _addOrganizationParameterTypes1 = new Class[] {
840                            long.class, java.lang.String.class, java.lang.String.class,
841                            boolean.class, long.class, long.class, int.class,
842                            java.lang.String.class, boolean.class, java.util.List.class,
843                            java.util.List.class, java.util.List.class, java.util.List.class,
844                            java.util.List.class,
845                            com.liferay.portal.service.ServiceContext.class
846                    };
847            private static final Class<?>[] _addOrganizationParameterTypes2 = new Class[] {
848                            long.class, java.lang.String.class, java.lang.String.class,
849                            boolean.class, long.class, long.class, int.class,
850                            java.lang.String.class, boolean.class,
851                            com.liferay.portal.service.ServiceContext.class
852                    };
853            private static final Class<?>[] _addOrganizationParameterTypes3 = new Class[] {
854                            long.class, java.lang.String.class, java.lang.String.class,
855                            long.class, long.class, int.class, java.lang.String.class,
856                            boolean.class, java.util.List.class, java.util.List.class,
857                            java.util.List.class, java.util.List.class, java.util.List.class,
858                            com.liferay.portal.service.ServiceContext.class
859                    };
860            private static final Class<?>[] _addOrganizationParameterTypes4 = new Class[] {
861                            long.class, java.lang.String.class, java.lang.String.class,
862                            long.class, long.class, int.class, java.lang.String.class,
863                            boolean.class, com.liferay.portal.service.ServiceContext.class
864                    };
865            private static final Class<?>[] _addPasswordPolicyOrganizationsParameterTypes5 =
866                    new Class[] { long.class, long[].class };
867            private static final Class<?>[] _deleteLogoParameterTypes6 = new Class[] {
868                            long.class
869                    };
870            private static final Class<?>[] _deleteOrganizationParameterTypes7 = new Class[] {
871                            long.class
872                    };
873            private static final Class<?>[] _getManageableOrganizationsParameterTypes8 = new Class[] {
874                            java.lang.String.class, int.class
875                    };
876            private static final Class<?>[] _getOrganizationParameterTypes9 = new Class[] {
877                            long.class
878                    };
879            private static final Class<?>[] _getOrganizationIdParameterTypes10 = new Class[] {
880                            long.class, java.lang.String.class
881                    };
882            private static final Class<?>[] _getOrganizationsParameterTypes11 = new Class[] {
883                            long.class, long.class
884                    };
885            private static final Class<?>[] _getOrganizationsParameterTypes12 = new Class[] {
886                            long.class, long.class, int.class, int.class
887                    };
888            private static final Class<?>[] _getOrganizationsCountParameterTypes13 = new Class[] {
889                            long.class, long.class
890                    };
891            private static final Class<?>[] _getUserOrganizationsParameterTypes14 = new Class[] {
892                            long.class
893                    };
894            private static final Class<?>[] _setGroupOrganizationsParameterTypes15 = new Class[] {
895                            long.class, long[].class
896                    };
897            private static final Class<?>[] _unsetGroupOrganizationsParameterTypes16 = new Class[] {
898                            long.class, long[].class
899                    };
900            private static final Class<?>[] _unsetPasswordPolicyOrganizationsParameterTypes17 =
901                    new Class[] { long.class, long[].class };
902            private static final Class<?>[] _updateOrganizationParameterTypes18 = new Class[] {
903                            long.class, long.class, java.lang.String.class,
904                            java.lang.String.class, boolean.class, long.class, long.class,
905                            int.class, java.lang.String.class, boolean.class,
906                            java.util.List.class, java.util.List.class, java.util.List.class,
907                            java.util.List.class, java.util.List.class,
908                            com.liferay.portal.service.ServiceContext.class
909                    };
910            private static final Class<?>[] _updateOrganizationParameterTypes19 = new Class[] {
911                            long.class, long.class, java.lang.String.class,
912                            java.lang.String.class, boolean.class, long.class, long.class,
913                            int.class, java.lang.String.class, boolean.class,
914                            com.liferay.portal.service.ServiceContext.class
915                    };
916            private static final Class<?>[] _updateOrganizationParameterTypes20 = new Class[] {
917                            long.class, long.class, java.lang.String.class,
918                            java.lang.String.class, long.class, long.class, int.class,
919                            java.lang.String.class, boolean.class, byte[].class, boolean.class,
920                            java.util.List.class, java.util.List.class, java.util.List.class,
921                            java.util.List.class, java.util.List.class,
922                            com.liferay.portal.service.ServiceContext.class
923                    };
924            private static final Class<?>[] _updateOrganizationParameterTypes21 = new Class[] {
925                            long.class, long.class, java.lang.String.class,
926                            java.lang.String.class, long.class, long.class, int.class,
927                            java.lang.String.class, boolean.class, java.util.List.class,
928                            java.util.List.class, java.util.List.class, java.util.List.class,
929                            java.util.List.class,
930                            com.liferay.portal.service.ServiceContext.class
931                    };
932            private static final Class<?>[] _updateOrganizationParameterTypes22 = new Class[] {
933                            long.class, long.class, java.lang.String.class,
934                            java.lang.String.class, long.class, long.class, int.class,
935                            java.lang.String.class, boolean.class,
936                            com.liferay.portal.service.ServiceContext.class
937                    };
938    }