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.CompanyServiceUtil;
025    
026    /**
027     * Provides the HTTP utility for the
028     * {@link CompanyServiceUtil} 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 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 CompanyServiceSoap
050     * @see HttpPrincipal
051     * @see CompanyServiceUtil
052     * @generated
053     */
054    @ProviderType
055    public class CompanyServiceHttp {
056            public static com.liferay.portal.model.Company addCompany(
057                    HttpPrincipal httpPrincipal, java.lang.String webId,
058                    java.lang.String virtualHost, java.lang.String mx, boolean system,
059                    int maxUsers, boolean active)
060                    throws com.liferay.portal.kernel.exception.PortalException {
061                    try {
062                            MethodKey methodKey = new MethodKey(CompanyServiceUtil.class,
063                                            "addCompany", _addCompanyParameterTypes0);
064    
065                            MethodHandler methodHandler = new MethodHandler(methodKey, webId,
066                                            virtualHost, mx, system, maxUsers, active);
067    
068                            Object returnObj = null;
069    
070                            try {
071                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
072                            }
073                            catch (Exception e) {
074                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
075                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
076                                    }
077    
078                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
079                            }
080    
081                            return (com.liferay.portal.model.Company)returnObj;
082                    }
083                    catch (com.liferay.portal.kernel.exception.SystemException se) {
084                            _log.error(se, se);
085    
086                            throw se;
087                    }
088            }
089    
090            public static com.liferay.portal.model.Company deleteCompany(
091                    HttpPrincipal httpPrincipal, long companyId)
092                    throws com.liferay.portal.kernel.exception.PortalException {
093                    try {
094                            MethodKey methodKey = new MethodKey(CompanyServiceUtil.class,
095                                            "deleteCompany", _deleteCompanyParameterTypes1);
096    
097                            MethodHandler methodHandler = new MethodHandler(methodKey, companyId);
098    
099                            Object returnObj = null;
100    
101                            try {
102                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
103                            }
104                            catch (Exception e) {
105                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
106                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
107                                    }
108    
109                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
110                            }
111    
112                            return (com.liferay.portal.model.Company)returnObj;
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 deleteLogo(HttpPrincipal httpPrincipal, long companyId)
122                    throws com.liferay.portal.kernel.exception.PortalException {
123                    try {
124                            MethodKey methodKey = new MethodKey(CompanyServiceUtil.class,
125                                            "deleteLogo", _deleteLogoParameterTypes2);
126    
127                            MethodHandler methodHandler = new MethodHandler(methodKey, companyId);
128    
129                            try {
130                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
131                            }
132                            catch (Exception e) {
133                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
134                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
135                                    }
136    
137                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
138                            }
139                    }
140                    catch (com.liferay.portal.kernel.exception.SystemException se) {
141                            _log.error(se, se);
142    
143                            throw se;
144                    }
145            }
146    
147            public static com.liferay.portal.model.Company getCompanyById(
148                    HttpPrincipal httpPrincipal, long companyId)
149                    throws com.liferay.portal.kernel.exception.PortalException {
150                    try {
151                            MethodKey methodKey = new MethodKey(CompanyServiceUtil.class,
152                                            "getCompanyById", _getCompanyByIdParameterTypes3);
153    
154                            MethodHandler methodHandler = new MethodHandler(methodKey, companyId);
155    
156                            Object returnObj = null;
157    
158                            try {
159                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
160                            }
161                            catch (Exception e) {
162                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
163                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
164                                    }
165    
166                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
167                            }
168    
169                            return (com.liferay.portal.model.Company)returnObj;
170                    }
171                    catch (com.liferay.portal.kernel.exception.SystemException se) {
172                            _log.error(se, se);
173    
174                            throw se;
175                    }
176            }
177    
178            public static com.liferay.portal.model.Company getCompanyByLogoId(
179                    HttpPrincipal httpPrincipal, long logoId)
180                    throws com.liferay.portal.kernel.exception.PortalException {
181                    try {
182                            MethodKey methodKey = new MethodKey(CompanyServiceUtil.class,
183                                            "getCompanyByLogoId", _getCompanyByLogoIdParameterTypes4);
184    
185                            MethodHandler methodHandler = new MethodHandler(methodKey, logoId);
186    
187                            Object returnObj = null;
188    
189                            try {
190                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
191                            }
192                            catch (Exception e) {
193                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
194                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
195                                    }
196    
197                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
198                            }
199    
200                            return (com.liferay.portal.model.Company)returnObj;
201                    }
202                    catch (com.liferay.portal.kernel.exception.SystemException se) {
203                            _log.error(se, se);
204    
205                            throw se;
206                    }
207            }
208    
209            public static com.liferay.portal.model.Company getCompanyByMx(
210                    HttpPrincipal httpPrincipal, java.lang.String mx)
211                    throws com.liferay.portal.kernel.exception.PortalException {
212                    try {
213                            MethodKey methodKey = new MethodKey(CompanyServiceUtil.class,
214                                            "getCompanyByMx", _getCompanyByMxParameterTypes5);
215    
216                            MethodHandler methodHandler = new MethodHandler(methodKey, mx);
217    
218                            Object returnObj = null;
219    
220                            try {
221                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
222                            }
223                            catch (Exception e) {
224                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
225                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
226                                    }
227    
228                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
229                            }
230    
231                            return (com.liferay.portal.model.Company)returnObj;
232                    }
233                    catch (com.liferay.portal.kernel.exception.SystemException se) {
234                            _log.error(se, se);
235    
236                            throw se;
237                    }
238            }
239    
240            public static com.liferay.portal.model.Company getCompanyByVirtualHost(
241                    HttpPrincipal httpPrincipal, java.lang.String virtualHost)
242                    throws com.liferay.portal.kernel.exception.PortalException {
243                    try {
244                            MethodKey methodKey = new MethodKey(CompanyServiceUtil.class,
245                                            "getCompanyByVirtualHost",
246                                            _getCompanyByVirtualHostParameterTypes6);
247    
248                            MethodHandler methodHandler = new MethodHandler(methodKey,
249                                            virtualHost);
250    
251                            Object returnObj = null;
252    
253                            try {
254                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
255                            }
256                            catch (Exception e) {
257                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
258                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
259                                    }
260    
261                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
262                            }
263    
264                            return (com.liferay.portal.model.Company)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.Company getCompanyByWebId(
274                    HttpPrincipal httpPrincipal, java.lang.String webId)
275                    throws com.liferay.portal.kernel.exception.PortalException {
276                    try {
277                            MethodKey methodKey = new MethodKey(CompanyServiceUtil.class,
278                                            "getCompanyByWebId", _getCompanyByWebIdParameterTypes7);
279    
280                            MethodHandler methodHandler = new MethodHandler(methodKey, webId);
281    
282                            Object returnObj = null;
283    
284                            try {
285                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
286                            }
287                            catch (Exception e) {
288                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
289                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
290                                    }
291    
292                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
293                            }
294    
295                            return (com.liferay.portal.model.Company)returnObj;
296                    }
297                    catch (com.liferay.portal.kernel.exception.SystemException se) {
298                            _log.error(se, se);
299    
300                            throw se;
301                    }
302            }
303    
304            public static void removePreferences(HttpPrincipal httpPrincipal,
305                    long companyId, java.lang.String[] keys)
306                    throws com.liferay.portal.kernel.exception.PortalException {
307                    try {
308                            MethodKey methodKey = new MethodKey(CompanyServiceUtil.class,
309                                            "removePreferences", _removePreferencesParameterTypes8);
310    
311                            MethodHandler methodHandler = new MethodHandler(methodKey,
312                                            companyId, keys);
313    
314                            try {
315                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
316                            }
317                            catch (Exception e) {
318                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
319                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
320                                    }
321    
322                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
323                            }
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 com.liferay.portal.model.Company updateCompany(
333                    HttpPrincipal httpPrincipal, long companyId,
334                    java.lang.String virtualHost, java.lang.String mx, int maxUsers,
335                    boolean active)
336                    throws com.liferay.portal.kernel.exception.PortalException {
337                    try {
338                            MethodKey methodKey = new MethodKey(CompanyServiceUtil.class,
339                                            "updateCompany", _updateCompanyParameterTypes9);
340    
341                            MethodHandler methodHandler = new MethodHandler(methodKey,
342                                            companyId, virtualHost, mx, maxUsers, active);
343    
344                            Object returnObj = null;
345    
346                            try {
347                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
348                            }
349                            catch (Exception e) {
350                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
351                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
352                                    }
353    
354                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
355                            }
356    
357                            return (com.liferay.portal.model.Company)returnObj;
358                    }
359                    catch (com.liferay.portal.kernel.exception.SystemException se) {
360                            _log.error(se, se);
361    
362                            throw se;
363                    }
364            }
365    
366            public static com.liferay.portal.model.Company updateCompany(
367                    HttpPrincipal httpPrincipal, long companyId,
368                    java.lang.String virtualHost, java.lang.String mx,
369                    java.lang.String homeURL, boolean logo, byte[] logoBytes,
370                    java.lang.String name, java.lang.String legalName,
371                    java.lang.String legalId, java.lang.String legalType,
372                    java.lang.String sicCode, java.lang.String tickerSymbol,
373                    java.lang.String industry, java.lang.String type, java.lang.String size)
374                    throws com.liferay.portal.kernel.exception.PortalException {
375                    try {
376                            MethodKey methodKey = new MethodKey(CompanyServiceUtil.class,
377                                            "updateCompany", _updateCompanyParameterTypes10);
378    
379                            MethodHandler methodHandler = new MethodHandler(methodKey,
380                                            companyId, virtualHost, mx, homeURL, logo, logoBytes, name,
381                                            legalName, legalId, legalType, sicCode, tickerSymbol,
382                                            industry, type, size);
383    
384                            Object returnObj = null;
385    
386                            try {
387                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
388                            }
389                            catch (Exception e) {
390                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
391                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
392                                    }
393    
394                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
395                            }
396    
397                            return (com.liferay.portal.model.Company)returnObj;
398                    }
399                    catch (com.liferay.portal.kernel.exception.SystemException se) {
400                            _log.error(se, se);
401    
402                            throw se;
403                    }
404            }
405    
406            public static com.liferay.portal.model.Company updateCompany(
407                    HttpPrincipal httpPrincipal, long companyId,
408                    java.lang.String virtualHost, java.lang.String mx,
409                    java.lang.String homeURL, boolean logo, byte[] logoBytes,
410                    java.lang.String name, java.lang.String legalName,
411                    java.lang.String legalId, java.lang.String legalType,
412                    java.lang.String sicCode, java.lang.String tickerSymbol,
413                    java.lang.String industry, java.lang.String type,
414                    java.lang.String size, java.lang.String languageId,
415                    java.lang.String timeZoneId,
416                    java.util.List<com.liferay.portal.model.Address> addresses,
417                    java.util.List<com.liferay.portal.model.EmailAddress> emailAddresses,
418                    java.util.List<com.liferay.portal.model.Phone> phones,
419                    java.util.List<com.liferay.portal.model.Website> websites,
420                    com.liferay.portal.kernel.util.UnicodeProperties properties)
421                    throws com.liferay.portal.kernel.exception.PortalException {
422                    try {
423                            MethodKey methodKey = new MethodKey(CompanyServiceUtil.class,
424                                            "updateCompany", _updateCompanyParameterTypes11);
425    
426                            MethodHandler methodHandler = new MethodHandler(methodKey,
427                                            companyId, virtualHost, mx, homeURL, logo, logoBytes, name,
428                                            legalName, legalId, legalType, sicCode, tickerSymbol,
429                                            industry, type, size, languageId, timeZoneId, addresses,
430                                            emailAddresses, phones, websites, properties);
431    
432                            Object returnObj = null;
433    
434                            try {
435                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
436                            }
437                            catch (Exception e) {
438                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
439                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
440                                    }
441    
442                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
443                            }
444    
445                            return (com.liferay.portal.model.Company)returnObj;
446                    }
447                    catch (com.liferay.portal.kernel.exception.SystemException se) {
448                            _log.error(se, se);
449    
450                            throw se;
451                    }
452            }
453    
454            public static com.liferay.portal.model.Company updateCompany(
455                    HttpPrincipal httpPrincipal, long companyId,
456                    java.lang.String virtualHost, java.lang.String mx,
457                    java.lang.String homeURL, java.lang.String name,
458                    java.lang.String legalName, java.lang.String legalId,
459                    java.lang.String legalType, java.lang.String sicCode,
460                    java.lang.String tickerSymbol, java.lang.String industry,
461                    java.lang.String type, java.lang.String size)
462                    throws com.liferay.portal.kernel.exception.PortalException {
463                    try {
464                            MethodKey methodKey = new MethodKey(CompanyServiceUtil.class,
465                                            "updateCompany", _updateCompanyParameterTypes12);
466    
467                            MethodHandler methodHandler = new MethodHandler(methodKey,
468                                            companyId, virtualHost, mx, homeURL, name, legalName,
469                                            legalId, legalType, sicCode, tickerSymbol, industry, type,
470                                            size);
471    
472                            Object returnObj = null;
473    
474                            try {
475                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
476                            }
477                            catch (Exception e) {
478                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
479                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
480                                    }
481    
482                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
483                            }
484    
485                            return (com.liferay.portal.model.Company)returnObj;
486                    }
487                    catch (com.liferay.portal.kernel.exception.SystemException se) {
488                            _log.error(se, se);
489    
490                            throw se;
491                    }
492            }
493    
494            public static com.liferay.portal.model.Company updateCompany(
495                    HttpPrincipal httpPrincipal, long companyId,
496                    java.lang.String virtualHost, java.lang.String mx,
497                    java.lang.String homeURL, java.lang.String name,
498                    java.lang.String legalName, java.lang.String legalId,
499                    java.lang.String legalType, java.lang.String sicCode,
500                    java.lang.String tickerSymbol, java.lang.String industry,
501                    java.lang.String type, java.lang.String size,
502                    java.lang.String languageId, java.lang.String timeZoneId,
503                    java.util.List<com.liferay.portal.model.Address> addresses,
504                    java.util.List<com.liferay.portal.model.EmailAddress> emailAddresses,
505                    java.util.List<com.liferay.portal.model.Phone> phones,
506                    java.util.List<com.liferay.portal.model.Website> websites,
507                    com.liferay.portal.kernel.util.UnicodeProperties properties)
508                    throws com.liferay.portal.kernel.exception.PortalException {
509                    try {
510                            MethodKey methodKey = new MethodKey(CompanyServiceUtil.class,
511                                            "updateCompany", _updateCompanyParameterTypes13);
512    
513                            MethodHandler methodHandler = new MethodHandler(methodKey,
514                                            companyId, virtualHost, mx, homeURL, name, legalName,
515                                            legalId, legalType, sicCode, tickerSymbol, industry, type,
516                                            size, languageId, timeZoneId, addresses, emailAddresses,
517                                            phones, websites, properties);
518    
519                            Object returnObj = null;
520    
521                            try {
522                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
523                            }
524                            catch (Exception e) {
525                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
526                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
527                                    }
528    
529                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
530                            }
531    
532                            return (com.liferay.portal.model.Company)returnObj;
533                    }
534                    catch (com.liferay.portal.kernel.exception.SystemException se) {
535                            _log.error(se, se);
536    
537                            throw se;
538                    }
539            }
540    
541            public static void updateDisplay(HttpPrincipal httpPrincipal,
542                    long companyId, java.lang.String languageId, java.lang.String timeZoneId)
543                    throws com.liferay.portal.kernel.exception.PortalException {
544                    try {
545                            MethodKey methodKey = new MethodKey(CompanyServiceUtil.class,
546                                            "updateDisplay", _updateDisplayParameterTypes14);
547    
548                            MethodHandler methodHandler = new MethodHandler(methodKey,
549                                            companyId, languageId, timeZoneId);
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 com.liferay.portal.model.Company updateLogo(
570                    HttpPrincipal httpPrincipal, long companyId, byte[] bytes)
571                    throws com.liferay.portal.kernel.exception.PortalException {
572                    try {
573                            MethodKey methodKey = new MethodKey(CompanyServiceUtil.class,
574                                            "updateLogo", _updateLogoParameterTypes15);
575    
576                            MethodHandler methodHandler = new MethodHandler(methodKey,
577                                            companyId, bytes);
578    
579                            Object returnObj = null;
580    
581                            try {
582                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
583                            }
584                            catch (Exception e) {
585                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
586                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
587                                    }
588    
589                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
590                            }
591    
592                            return (com.liferay.portal.model.Company)returnObj;
593                    }
594                    catch (com.liferay.portal.kernel.exception.SystemException se) {
595                            _log.error(se, se);
596    
597                            throw se;
598                    }
599            }
600    
601            public static com.liferay.portal.model.Company updateLogo(
602                    HttpPrincipal httpPrincipal, long companyId,
603                    java.io.InputStream inputStream)
604                    throws com.liferay.portal.kernel.exception.PortalException {
605                    try {
606                            MethodKey methodKey = new MethodKey(CompanyServiceUtil.class,
607                                            "updateLogo", _updateLogoParameterTypes16);
608    
609                            MethodHandler methodHandler = new MethodHandler(methodKey,
610                                            companyId, inputStream);
611    
612                            Object returnObj = null;
613    
614                            try {
615                                    returnObj = TunnelUtil.invoke(httpPrincipal, methodHandler);
616                            }
617                            catch (Exception e) {
618                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
619                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
620                                    }
621    
622                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
623                            }
624    
625                            return (com.liferay.portal.model.Company)returnObj;
626                    }
627                    catch (com.liferay.portal.kernel.exception.SystemException se) {
628                            _log.error(se, se);
629    
630                            throw se;
631                    }
632            }
633    
634            public static void updatePreferences(HttpPrincipal httpPrincipal,
635                    long companyId,
636                    com.liferay.portal.kernel.util.UnicodeProperties properties)
637                    throws com.liferay.portal.kernel.exception.PortalException {
638                    try {
639                            MethodKey methodKey = new MethodKey(CompanyServiceUtil.class,
640                                            "updatePreferences", _updatePreferencesParameterTypes17);
641    
642                            MethodHandler methodHandler = new MethodHandler(methodKey,
643                                            companyId, properties);
644    
645                            try {
646                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
647                            }
648                            catch (Exception e) {
649                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
650                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
651                                    }
652    
653                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
654                            }
655                    }
656                    catch (com.liferay.portal.kernel.exception.SystemException se) {
657                            _log.error(se, se);
658    
659                            throw se;
660                    }
661            }
662    
663            public static void updateSecurity(HttpPrincipal httpPrincipal,
664                    long companyId, java.lang.String authType, boolean autoLogin,
665                    boolean sendPassword, boolean strangers, boolean strangersWithMx,
666                    boolean strangersVerify, boolean siteLogo)
667                    throws com.liferay.portal.kernel.exception.PortalException {
668                    try {
669                            MethodKey methodKey = new MethodKey(CompanyServiceUtil.class,
670                                            "updateSecurity", _updateSecurityParameterTypes18);
671    
672                            MethodHandler methodHandler = new MethodHandler(methodKey,
673                                            companyId, authType, autoLogin, sendPassword, strangers,
674                                            strangersWithMx, strangersVerify, siteLogo);
675    
676                            try {
677                                    TunnelUtil.invoke(httpPrincipal, methodHandler);
678                            }
679                            catch (Exception e) {
680                                    if (e instanceof com.liferay.portal.kernel.exception.PortalException) {
681                                            throw (com.liferay.portal.kernel.exception.PortalException)e;
682                                    }
683    
684                                    throw new com.liferay.portal.kernel.exception.SystemException(e);
685                            }
686                    }
687                    catch (com.liferay.portal.kernel.exception.SystemException se) {
688                            _log.error(se, se);
689    
690                            throw se;
691                    }
692            }
693    
694            private static Log _log = LogFactoryUtil.getLog(CompanyServiceHttp.class);
695            private static final Class<?>[] _addCompanyParameterTypes0 = new Class[] {
696                            java.lang.String.class, java.lang.String.class,
697                            java.lang.String.class, boolean.class, int.class, boolean.class
698                    };
699            private static final Class<?>[] _deleteCompanyParameterTypes1 = new Class[] {
700                            long.class
701                    };
702            private static final Class<?>[] _deleteLogoParameterTypes2 = new Class[] {
703                            long.class
704                    };
705            private static final Class<?>[] _getCompanyByIdParameterTypes3 = new Class[] {
706                            long.class
707                    };
708            private static final Class<?>[] _getCompanyByLogoIdParameterTypes4 = new Class[] {
709                            long.class
710                    };
711            private static final Class<?>[] _getCompanyByMxParameterTypes5 = new Class[] {
712                            java.lang.String.class
713                    };
714            private static final Class<?>[] _getCompanyByVirtualHostParameterTypes6 = new Class[] {
715                            java.lang.String.class
716                    };
717            private static final Class<?>[] _getCompanyByWebIdParameterTypes7 = new Class[] {
718                            java.lang.String.class
719                    };
720            private static final Class<?>[] _removePreferencesParameterTypes8 = new Class[] {
721                            long.class, java.lang.String[].class
722                    };
723            private static final Class<?>[] _updateCompanyParameterTypes9 = new Class[] {
724                            long.class, java.lang.String.class, java.lang.String.class,
725                            int.class, boolean.class
726                    };
727            private static final Class<?>[] _updateCompanyParameterTypes10 = new Class[] {
728                            long.class, java.lang.String.class, java.lang.String.class,
729                            java.lang.String.class, boolean.class, byte[].class,
730                            java.lang.String.class, java.lang.String.class,
731                            java.lang.String.class, java.lang.String.class,
732                            java.lang.String.class, java.lang.String.class,
733                            java.lang.String.class, java.lang.String.class,
734                            java.lang.String.class
735                    };
736            private static final Class<?>[] _updateCompanyParameterTypes11 = new Class[] {
737                            long.class, java.lang.String.class, java.lang.String.class,
738                            java.lang.String.class, boolean.class, byte[].class,
739                            java.lang.String.class, java.lang.String.class,
740                            java.lang.String.class, java.lang.String.class,
741                            java.lang.String.class, java.lang.String.class,
742                            java.lang.String.class, java.lang.String.class,
743                            java.lang.String.class, java.lang.String.class,
744                            java.lang.String.class, java.util.List.class, java.util.List.class,
745                            java.util.List.class, java.util.List.class,
746                            com.liferay.portal.kernel.util.UnicodeProperties.class
747                    };
748            private static final Class<?>[] _updateCompanyParameterTypes12 = new Class[] {
749                            long.class, java.lang.String.class, java.lang.String.class,
750                            java.lang.String.class, java.lang.String.class,
751                            java.lang.String.class, java.lang.String.class,
752                            java.lang.String.class, java.lang.String.class,
753                            java.lang.String.class, java.lang.String.class,
754                            java.lang.String.class, java.lang.String.class
755                    };
756            private static final Class<?>[] _updateCompanyParameterTypes13 = new Class[] {
757                            long.class, java.lang.String.class, java.lang.String.class,
758                            java.lang.String.class, java.lang.String.class,
759                            java.lang.String.class, java.lang.String.class,
760                            java.lang.String.class, java.lang.String.class,
761                            java.lang.String.class, java.lang.String.class,
762                            java.lang.String.class, java.lang.String.class,
763                            java.lang.String.class, java.lang.String.class, java.util.List.class,
764                            java.util.List.class, java.util.List.class, java.util.List.class,
765                            com.liferay.portal.kernel.util.UnicodeProperties.class
766                    };
767            private static final Class<?>[] _updateDisplayParameterTypes14 = new Class[] {
768                            long.class, java.lang.String.class, java.lang.String.class
769                    };
770            private static final Class<?>[] _updateLogoParameterTypes15 = new Class[] {
771                            long.class, byte[].class
772                    };
773            private static final Class<?>[] _updateLogoParameterTypes16 = new Class[] {
774                            long.class, java.io.InputStream.class
775                    };
776            private static final Class<?>[] _updatePreferencesParameterTypes17 = new Class[] {
777                            long.class, com.liferay.portal.kernel.util.UnicodeProperties.class
778                    };
779            private static final Class<?>[] _updateSecurityParameterTypes18 = new Class[] {
780                            long.class, java.lang.String.class, boolean.class, boolean.class,
781                            boolean.class, boolean.class, boolean.class, boolean.class
782                    };
783    }