001    /**
002     * Copyright (c) 2000-2013 Liferay, Inc. All rights reserved.
003     *
004     * This library is free software; you can redistribute it and/or modify it under
005     * the terms of the GNU Lesser General Public License as published by the Free
006     * Software Foundation; either version 2.1 of the License, or (at your option)
007     * any later version.
008     *
009     * This library is distributed in the hope that it will be useful, but WITHOUT
010     * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
011     * FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
012     * details.
013     */
014    
015    package com.liferay.portal.service.http;
016    
017    import com.liferay.portal.kernel.log.Log;
018    import com.liferay.portal.kernel.log.LogFactoryUtil;
019    import com.liferay.portal.service.OrganizationServiceUtil;
020    
021    import java.rmi.RemoteException;
022    
023    /**
024     * Provides the SOAP utility for the
025     * {@link com.liferay.portal.service.OrganizationServiceUtil} service utility. The
026     * static methods of this class calls the same methods of the service utility.
027     * However, the signatures are different because it is difficult for SOAP to
028     * support certain types.
029     *
030     * <p>
031     * ServiceBuilder follows certain rules in translating the methods. For example,
032     * if the method in the service utility returns a {@link java.util.List}, that
033     * is translated to an array of {@link com.liferay.portal.model.OrganizationSoap}.
034     * If the method in the service utility returns a
035     * {@link com.liferay.portal.model.Organization}, that is translated to a
036     * {@link com.liferay.portal.model.OrganizationSoap}. Methods that SOAP cannot
037     * safely wire are skipped.
038     * </p>
039     *
040     * <p>
041     * The benefits of using the SOAP utility is that it is cross platform
042     * compatible. SOAP allows different languages like Java, .NET, C++, PHP, and
043     * even Perl, to call the generated services. One drawback of SOAP is that it is
044     * slow because it needs to serialize all calls into a text format (XML).
045     * </p>
046     *
047     * <p>
048     * You can see a list of services at http://localhost:8080/api/axis. Set the
049     * property <b>axis.servlet.hosts.allowed</b> in portal.properties to configure
050     * security.
051     * </p>
052     *
053     * <p>
054     * The SOAP utility is only generated for remote services.
055     * </p>
056     *
057     * @author Brian Wing Shun Chan
058     * @see OrganizationServiceHttp
059     * @see com.liferay.portal.model.OrganizationSoap
060     * @see com.liferay.portal.service.OrganizationServiceUtil
061     * @generated
062     */
063    public class OrganizationServiceSoap {
064            /**
065            * Adds the organizations to the group.
066            *
067            * @param groupId the primary key of the group
068            * @param organizationIds the primary keys of the organizations
069            * @throws PortalException if a group or organization with the primary key
070            could not be found or if the user did not have permission to
071            assign group members
072            * @throws SystemException if a system exception occurred
073            */
074            public static void addGroupOrganizations(long groupId,
075                    long[] organizationIds) throws RemoteException {
076                    try {
077                            OrganizationServiceUtil.addGroupOrganizations(groupId,
078                                    organizationIds);
079                    }
080                    catch (Exception e) {
081                            _log.error(e, e);
082    
083                            throw new RemoteException(e.getMessage());
084                    }
085            }
086    
087            /**
088            * Adds an organization with additional parameters.
089            *
090            * <p>
091            * This method handles the creation and bookkeeping of the organization
092            * including its resources, metadata, and internal data structures.
093            * </p>
094            *
095            * @param parentOrganizationId the primary key of the organization's
096            parent organization
097            * @param name the organization's name
098            * @param type the organization's type
099            * @param recursable whether the permissions of the organization are to
100            be inherited by its suborganizations
101            * @param regionId the primary key of the organization's region
102            * @param countryId the primary key of the organization's country
103            * @param statusId the organization's workflow status
104            * @param comments the comments about the organization
105            * @param site whether the organization is to be associated with a main
106            site
107            * @param addresses the organization's addresses
108            * @param emailAddresses the organization's email addresses
109            * @param orgLabors the organization's hours of operation
110            * @param phones the organization's phone numbers
111            * @param websites the organization's websites
112            * @param serviceContext the service context to be applied (optionally
113            <code>null</code>). Can set asset category IDs, asset tag
114            names, and expando bridge attributes for the organization.
115            * @return the organization
116            * @throws PortalException if a parent organization with the primary key
117            could not be found, if the organization's information was
118            invalid, or if the user did not have permission to add the
119            organization
120            * @throws SystemException if a system exception occurred
121            * @deprecated As of 6.2.0, replaced by {@link #addOrganization(long,
122            String, String, long, long, int, String, boolean,
123            java.util.List, java.util.List, java.util.List,
124            java.util.List, java.util.List, ServiceContext)}
125            */
126            public static com.liferay.portal.model.OrganizationSoap addOrganization(
127                    long parentOrganizationId, java.lang.String name,
128                    java.lang.String type, boolean recursable, long regionId,
129                    long countryId, int statusId, java.lang.String comments, boolean site,
130                    com.liferay.portal.model.AddressSoap[] addresses,
131                    com.liferay.portal.model.EmailAddressSoap[] emailAddresses,
132                    com.liferay.portal.model.OrgLaborSoap[] orgLabors,
133                    com.liferay.portal.model.PhoneSoap[] phones,
134                    com.liferay.portal.model.WebsiteSoap[] websites,
135                    com.liferay.portal.service.ServiceContext serviceContext)
136                    throws RemoteException {
137                    try {
138                            com.liferay.portal.model.Organization returnValue = OrganizationServiceUtil.addOrganization(parentOrganizationId,
139                                            name, type, recursable, regionId, countryId, statusId,
140                                            comments, site,
141                                            com.liferay.portal.model.impl.AddressModelImpl.toModels(
142                                                    addresses),
143                                            com.liferay.portal.model.impl.EmailAddressModelImpl.toModels(
144                                                    emailAddresses),
145                                            com.liferay.portal.model.impl.OrgLaborModelImpl.toModels(
146                                                    orgLabors),
147                                            com.liferay.portal.model.impl.PhoneModelImpl.toModels(
148                                                    phones),
149                                            com.liferay.portal.model.impl.WebsiteModelImpl.toModels(
150                                                    websites), serviceContext);
151    
152                            return com.liferay.portal.model.OrganizationSoap.toSoapModel(returnValue);
153                    }
154                    catch (Exception e) {
155                            _log.error(e, e);
156    
157                            throw new RemoteException(e.getMessage());
158                    }
159            }
160    
161            /**
162            * Adds an organization.
163            *
164            * <p>
165            * This method handles the creation and bookkeeping of the organization
166            * including its resources, metadata, and internal data structures.
167            * </p>
168            *
169            * @param parentOrganizationId the primary key of the organization's
170            parent organization
171            * @param name the organization's name
172            * @param type the organization's type
173            * @param recursable whether the permissions of the organization are to
174            be inherited by its suborganizations
175            * @param regionId the primary key of the organization's region
176            * @param countryId the primary key of the organization's country
177            * @param statusId the organization's workflow status
178            * @param comments the comments about the organization
179            * @param site whether the organization is to be associated with a main
180            site
181            * @param serviceContext the service context to be applied (optionally
182            <code>null</code>). Can set asset category IDs, asset tag
183            names, and expando bridge attributes for the organization.
184            * @return the organization
185            * @throws PortalException if the parent organization with the primary
186            key could not be found, if the organization information was
187            invalid, or if the user did not have permission to add the
188            organization
189            * @throws SystemException if a system exception occurred
190            * @deprecated As of 6.2.0, replaced by {@link #addOrganization(long,
191            String, String, long, long, int, String, boolean,
192            ServiceContext)}
193            */
194            public static com.liferay.portal.model.OrganizationSoap addOrganization(
195                    long parentOrganizationId, java.lang.String name,
196                    java.lang.String type, boolean recursable, long regionId,
197                    long countryId, int statusId, java.lang.String comments, boolean site,
198                    com.liferay.portal.service.ServiceContext serviceContext)
199                    throws RemoteException {
200                    try {
201                            com.liferay.portal.model.Organization returnValue = OrganizationServiceUtil.addOrganization(parentOrganizationId,
202                                            name, type, recursable, regionId, countryId, statusId,
203                                            comments, site, serviceContext);
204    
205                            return com.liferay.portal.model.OrganizationSoap.toSoapModel(returnValue);
206                    }
207                    catch (Exception e) {
208                            _log.error(e, e);
209    
210                            throw new RemoteException(e.getMessage());
211                    }
212            }
213    
214            /**
215            * Adds an organization with additional parameters.
216            *
217            * <p>
218            * This method handles the creation and bookkeeping of the organization
219            * including its resources, metadata, and internal data structures.
220            * </p>
221            *
222            * @param parentOrganizationId the primary key of the organization's parent
223            organization
224            * @param name the organization's name
225            * @param type the organization's type
226            * @param regionId the primary key of the organization's region
227            * @param countryId the primary key of the organization's country
228            * @param statusId the organization's workflow status
229            * @param comments the comments about the organization
230            * @param site whether the organization is to be associated with a main
231            site
232            * @param addresses the organization's addresses
233            * @param emailAddresses the organization's email addresses
234            * @param orgLabors the organization's hours of operation
235            * @param phones the organization's phone numbers
236            * @param websites the organization's websites
237            * @param serviceContext the service context to be applied (optionally
238            <code>null</code>). Can set asset category IDs, asset tag names,
239            and expando bridge attributes for the organization.
240            * @return the organization
241            * @throws PortalException if a parent organization with the primary key
242            could not be found, if the organization's information was
243            invalid, or if the user did not have permission to add the
244            organization
245            * @throws SystemException if a system exception occurred
246            */
247            public static com.liferay.portal.model.OrganizationSoap addOrganization(
248                    long parentOrganizationId, java.lang.String name,
249                    java.lang.String type, long regionId, long countryId, int statusId,
250                    java.lang.String comments, boolean site,
251                    com.liferay.portal.model.AddressSoap[] addresses,
252                    com.liferay.portal.model.EmailAddressSoap[] emailAddresses,
253                    com.liferay.portal.model.OrgLaborSoap[] orgLabors,
254                    com.liferay.portal.model.PhoneSoap[] phones,
255                    com.liferay.portal.model.WebsiteSoap[] websites,
256                    com.liferay.portal.service.ServiceContext serviceContext)
257                    throws RemoteException {
258                    try {
259                            com.liferay.portal.model.Organization returnValue = OrganizationServiceUtil.addOrganization(parentOrganizationId,
260                                            name, type, regionId, countryId, statusId, comments, site,
261                                            com.liferay.portal.model.impl.AddressModelImpl.toModels(
262                                                    addresses),
263                                            com.liferay.portal.model.impl.EmailAddressModelImpl.toModels(
264                                                    emailAddresses),
265                                            com.liferay.portal.model.impl.OrgLaborModelImpl.toModels(
266                                                    orgLabors),
267                                            com.liferay.portal.model.impl.PhoneModelImpl.toModels(
268                                                    phones),
269                                            com.liferay.portal.model.impl.WebsiteModelImpl.toModels(
270                                                    websites), serviceContext);
271    
272                            return com.liferay.portal.model.OrganizationSoap.toSoapModel(returnValue);
273                    }
274                    catch (Exception e) {
275                            _log.error(e, e);
276    
277                            throw new RemoteException(e.getMessage());
278                    }
279            }
280    
281            /**
282            * Adds an organization.
283            *
284            * <p>
285            * This method handles the creation and bookkeeping of the organization
286            * including its resources, metadata, and internal data structures.
287            * </p>
288            *
289            * @param parentOrganizationId the primary key of the organization's parent
290            organization
291            * @param name the organization's name
292            * @param type the organization's type
293            * @param regionId the primary key of the organization's region
294            * @param countryId the primary key of the organization's country
295            * @param statusId the organization's workflow status
296            * @param comments the comments about the organization
297            * @param site whether the organization is to be associated with a main
298            site
299            * @param serviceContext the service context to be applied (optionally
300            <code>null</code>). Can set asset category IDs, asset tag names,
301            and expando bridge attributes for the organization.
302            * @return the organization
303            * @throws PortalException if the parent organization with the primary key
304            could not be found, if the organization information was invalid,
305            or if the user did not have permission to add the organization
306            * @throws SystemException if a system exception occurred
307            */
308            public static com.liferay.portal.model.OrganizationSoap addOrganization(
309                    long parentOrganizationId, java.lang.String name,
310                    java.lang.String type, long regionId, long countryId, int statusId,
311                    java.lang.String comments, boolean site,
312                    com.liferay.portal.service.ServiceContext serviceContext)
313                    throws RemoteException {
314                    try {
315                            com.liferay.portal.model.Organization returnValue = OrganizationServiceUtil.addOrganization(parentOrganizationId,
316                                            name, type, regionId, countryId, statusId, comments, site,
317                                            serviceContext);
318    
319                            return com.liferay.portal.model.OrganizationSoap.toSoapModel(returnValue);
320                    }
321                    catch (Exception e) {
322                            _log.error(e, e);
323    
324                            throw new RemoteException(e.getMessage());
325                    }
326            }
327    
328            /**
329            * Assigns the password policy to the organizations, removing any other
330            * currently assigned password policies.
331            *
332            * @param passwordPolicyId the primary key of the password policy
333            * @param organizationIds the primary keys of the organizations
334            * @throws PortalException if the user did not have permission to update the
335            password policy
336            * @throws SystemException if a system exception occurred
337            */
338            public static void addPasswordPolicyOrganizations(long passwordPolicyId,
339                    long[] organizationIds) throws RemoteException {
340                    try {
341                            OrganizationServiceUtil.addPasswordPolicyOrganizations(passwordPolicyId,
342                                    organizationIds);
343                    }
344                    catch (Exception e) {
345                            _log.error(e, e);
346    
347                            throw new RemoteException(e.getMessage());
348                    }
349            }
350    
351            /**
352            * Deletes the logo of the organization.
353            *
354            * @param organizationId the primary key of the organization
355            * @throws PortalException if an organization with the primary key could not
356            be found, if the organization's logo could not be found, or if
357            the user did not have permission to update the organization
358            * @throws SystemException if a system exception occurred
359            */
360            public static void deleteLogo(long organizationId)
361                    throws RemoteException {
362                    try {
363                            OrganizationServiceUtil.deleteLogo(organizationId);
364                    }
365                    catch (Exception e) {
366                            _log.error(e, e);
367    
368                            throw new RemoteException(e.getMessage());
369                    }
370            }
371    
372            /**
373            * Deletes the organization. The organization's associated resources and
374            * assets are also deleted.
375            *
376            * @param organizationId the primary key of the organization
377            * @throws PortalException if an organization with the primary key could not
378            be found, if the user did not have permission to delete the
379            organization, if the organization had a workflow in approved
380            status, or if the organization was a parent organization
381            * @throws SystemException if a system exception occurred
382            */
383            public static void deleteOrganization(long organizationId)
384                    throws RemoteException {
385                    try {
386                            OrganizationServiceUtil.deleteOrganization(organizationId);
387                    }
388                    catch (Exception e) {
389                            _log.error(e, e);
390    
391                            throw new RemoteException(e.getMessage());
392                    }
393            }
394    
395            /**
396            * Returns all the organizations which the user has permission to manage.
397            *
398            * @param actionId the permitted action
399            * @param max the maximum number of the organizations to be considered
400            * @return the organizations which the user has permission to manage
401            * @throws PortalException if a portal exception occurred
402            * @throws SystemException if a system exception occurred
403            * @deprecated As of 6.2.0, replaced by {@link #getOrganizations(long, long,
404            int, int)}
405            */
406            public static com.liferay.portal.model.OrganizationSoap[] getManageableOrganizations(
407                    java.lang.String actionId, int max) throws RemoteException {
408                    try {
409                            java.util.List<com.liferay.portal.model.Organization> returnValue = OrganizationServiceUtil.getManageableOrganizations(actionId,
410                                            max);
411    
412                            return com.liferay.portal.model.OrganizationSoap.toSoapModels(returnValue);
413                    }
414                    catch (Exception e) {
415                            _log.error(e, e);
416    
417                            throw new RemoteException(e.getMessage());
418                    }
419            }
420    
421            /**
422            * Returns the organization with the primary key.
423            *
424            * @param organizationId the primary key of the organization
425            * @return the organization with the primary key
426            * @throws PortalException if an organization with the primary key could not
427            be found or if the user did not have permission to view the
428            organization
429            * @throws SystemException if a system exception occurred
430            */
431            public static com.liferay.portal.model.OrganizationSoap getOrganization(
432                    long organizationId) throws RemoteException {
433                    try {
434                            com.liferay.portal.model.Organization returnValue = OrganizationServiceUtil.getOrganization(organizationId);
435    
436                            return com.liferay.portal.model.OrganizationSoap.toSoapModel(returnValue);
437                    }
438                    catch (Exception e) {
439                            _log.error(e, e);
440    
441                            throw new RemoteException(e.getMessage());
442                    }
443            }
444    
445            /**
446            * Returns the primary key of the organization with the name.
447            *
448            * @param companyId the primary key of the organization's company
449            * @param name the organization's name
450            * @return the primary key of the organization with the name, or
451            <code>0</code> if the organization could not be found
452            * @throws PortalException if the user did not have permission to view the
453            organization
454            * @throws SystemException if a system exception occurred
455            */
456            public static long getOrganizationId(long companyId, java.lang.String name)
457                    throws RemoteException {
458                    try {
459                            long returnValue = OrganizationServiceUtil.getOrganizationId(companyId,
460                                            name);
461    
462                            return returnValue;
463                    }
464                    catch (Exception e) {
465                            _log.error(e, e);
466    
467                            throw new RemoteException(e.getMessage());
468                    }
469            }
470    
471            /**
472            * Returns all the organizations belonging to the parent organization.
473            *
474            * @param companyId the primary key of the organizations' company
475            * @param parentOrganizationId the primary key of the organizations' parent
476            organization
477            * @return the organizations belonging to the parent organization
478            * @throws SystemException if a system exception occurred
479            */
480            public static com.liferay.portal.model.OrganizationSoap[] getOrganizations(
481                    long companyId, long parentOrganizationId) throws RemoteException {
482                    try {
483                            java.util.List<com.liferay.portal.model.Organization> returnValue = OrganizationServiceUtil.getOrganizations(companyId,
484                                            parentOrganizationId);
485    
486                            return com.liferay.portal.model.OrganizationSoap.toSoapModels(returnValue);
487                    }
488                    catch (Exception e) {
489                            _log.error(e, e);
490    
491                            throw new RemoteException(e.getMessage());
492                    }
493            }
494    
495            /**
496            * Returns a range of all the organizations belonging to the parent
497            * organization.
498            *
499            * <p>
500            * Useful when paginating results. Returns a maximum of <code>end -
501            * start</code> instances. <code>start</code> and <code>end</code> are not
502            * primary keys, they are indexes in the result set. Thus, <code>0</code>
503            * refers to the first result in the set. Setting both <code>start</code>
504            * and <code>end</code> to {@link
505            * com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full
506            * result set.
507            * </p>
508            *
509            * @param companyId the primary key of the organizations' company
510            * @param parentOrganizationId the primary key of the organizations' parent
511            organization
512            * @param start the lower bound of the range of organizations to return
513            * @param end the upper bound of the range of organizations to return (not
514            inclusive)
515            * @return the range of organizations belonging to the parent organization
516            * @throws SystemException if a system exception occurred
517            */
518            public static com.liferay.portal.model.OrganizationSoap[] getOrganizations(
519                    long companyId, long parentOrganizationId, int start, int end)
520                    throws RemoteException {
521                    try {
522                            java.util.List<com.liferay.portal.model.Organization> returnValue = OrganizationServiceUtil.getOrganizations(companyId,
523                                            parentOrganizationId, start, end);
524    
525                            return com.liferay.portal.model.OrganizationSoap.toSoapModels(returnValue);
526                    }
527                    catch (Exception e) {
528                            _log.error(e, e);
529    
530                            throw new RemoteException(e.getMessage());
531                    }
532            }
533    
534            /**
535            * Returns the number of organizations belonging to the parent organization.
536            *
537            * @param companyId the primary key of the organizations' company
538            * @param parentOrganizationId the primary key of the organizations' parent
539            organization
540            * @return the number of organizations belonging to the parent organization
541            * @throws SystemException if a system exception occurred
542            */
543            public static int getOrganizationsCount(long companyId,
544                    long parentOrganizationId) throws RemoteException {
545                    try {
546                            int returnValue = OrganizationServiceUtil.getOrganizationsCount(companyId,
547                                            parentOrganizationId);
548    
549                            return returnValue;
550                    }
551                    catch (Exception e) {
552                            _log.error(e, e);
553    
554                            throw new RemoteException(e.getMessage());
555                    }
556            }
557    
558            /**
559            * Returns all the organizations associated with the user.
560            *
561            * @param userId the primary key of the user
562            * @return the organizations associated with the user
563            * @throws PortalException if a user with the primary key could not be found
564            * @throws SystemException if a system exception occurred
565            */
566            public static com.liferay.portal.model.OrganizationSoap[] getUserOrganizations(
567                    long userId) throws RemoteException {
568                    try {
569                            java.util.List<com.liferay.portal.model.Organization> returnValue = OrganizationServiceUtil.getUserOrganizations(userId);
570    
571                            return com.liferay.portal.model.OrganizationSoap.toSoapModels(returnValue);
572                    }
573                    catch (Exception e) {
574                            _log.error(e, e);
575    
576                            throw new RemoteException(e.getMessage());
577                    }
578            }
579    
580            /**
581            * Sets the organizations in the group, removing and adding organizations to
582            * the group as necessary.
583            *
584            * @param groupId the primary key of the group
585            * @param organizationIds the primary keys of the organizations
586            * @throws PortalException if a group or organization with the primary key
587            could not be found or if the user did not have permission to
588            assign group members
589            * @throws SystemException if a system exception occurred
590            */
591            public static void setGroupOrganizations(long groupId,
592                    long[] organizationIds) throws RemoteException {
593                    try {
594                            OrganizationServiceUtil.setGroupOrganizations(groupId,
595                                    organizationIds);
596                    }
597                    catch (Exception e) {
598                            _log.error(e, e);
599    
600                            throw new RemoteException(e.getMessage());
601                    }
602            }
603    
604            /**
605            * Removes the organizations from the group.
606            *
607            * @param groupId the primary key of the group
608            * @param organizationIds the primary keys of the organizations
609            * @throws PortalException if a group or organization with the primary key
610            could not be found or if the user did not have permission to
611            assign group members
612            * @throws SystemException if a system exception occurred
613            */
614            public static void unsetGroupOrganizations(long groupId,
615                    long[] organizationIds) throws RemoteException {
616                    try {
617                            OrganizationServiceUtil.unsetGroupOrganizations(groupId,
618                                    organizationIds);
619                    }
620                    catch (Exception e) {
621                            _log.error(e, e);
622    
623                            throw new RemoteException(e.getMessage());
624                    }
625            }
626    
627            /**
628            * Removes the organizations from the password policy.
629            *
630            * @param passwordPolicyId the primary key of the password policy
631            * @param organizationIds the primary keys of the organizations
632            * @throws PortalException if a password policy or organization with the
633            primary key could not be found, or if the user did not have
634            permission to update the password policy
635            * @throws SystemException if a system exception occurred
636            */
637            public static void unsetPasswordPolicyOrganizations(long passwordPolicyId,
638                    long[] organizationIds) throws RemoteException {
639                    try {
640                            OrganizationServiceUtil.unsetPasswordPolicyOrganizations(passwordPolicyId,
641                                    organizationIds);
642                    }
643                    catch (Exception e) {
644                            _log.error(e, e);
645    
646                            throw new RemoteException(e.getMessage());
647                    }
648            }
649    
650            /**
651            * Updates the organization with additional parameters.
652            *
653            * @param organizationId the primary key of the organization
654            * @param parentOrganizationId the primary key of the organization's
655            parent organization
656            * @param name the organization's name
657            * @param type the organization's type
658            * @param recursable whether the permissions of the organization are to
659            be inherited by its suborganizations
660            * @param regionId the primary key of the organization's region
661            * @param countryId the primary key of the organization's country
662            * @param statusId the organization's workflow status
663            * @param comments the comments about the organization
664            * @param site whether the organization is to be associated with a main
665            site
666            * @param addresses the organization's addresses
667            * @param emailAddresses the organization's email addresses
668            * @param orgLabors the organization's hours of operation
669            * @param phones the organization's phone numbers
670            * @param websites the organization's websites
671            * @param serviceContext the service context to be applied (optionally
672            <code>null</code>). Can set asset category IDs and asset tag
673            names for the organization, and merge expando bridge
674            attributes for the organization.
675            * @return the organization
676            * @throws PortalException if an organization or parent organization
677            with the primary key could not be found, if the user did not
678            have permission to update the organization information, or if
679            the new information was invalid
680            * @throws SystemException if a system exception occurred
681            * @deprecated As of 6.2.0, replaced by {@link #updateOrganization(long,
682            long, String, String, long, long, int, String, boolean,
683            java.util.List, java.util.List, java.util.List,
684            java.util.List, java.util.List, ServiceContext)}
685            */
686            public static com.liferay.portal.model.OrganizationSoap updateOrganization(
687                    long organizationId, long parentOrganizationId, java.lang.String name,
688                    java.lang.String type, boolean recursable, long regionId,
689                    long countryId, int statusId, java.lang.String comments, boolean site,
690                    com.liferay.portal.model.AddressSoap[] addresses,
691                    com.liferay.portal.model.EmailAddressSoap[] emailAddresses,
692                    com.liferay.portal.model.OrgLaborSoap[] orgLabors,
693                    com.liferay.portal.model.PhoneSoap[] phones,
694                    com.liferay.portal.model.WebsiteSoap[] websites,
695                    com.liferay.portal.service.ServiceContext serviceContext)
696                    throws RemoteException {
697                    try {
698                            com.liferay.portal.model.Organization returnValue = OrganizationServiceUtil.updateOrganization(organizationId,
699                                            parentOrganizationId, name, type, recursable, regionId,
700                                            countryId, statusId, comments, site,
701                                            com.liferay.portal.model.impl.AddressModelImpl.toModels(
702                                                    addresses),
703                                            com.liferay.portal.model.impl.EmailAddressModelImpl.toModels(
704                                                    emailAddresses),
705                                            com.liferay.portal.model.impl.OrgLaborModelImpl.toModels(
706                                                    orgLabors),
707                                            com.liferay.portal.model.impl.PhoneModelImpl.toModels(
708                                                    phones),
709                                            com.liferay.portal.model.impl.WebsiteModelImpl.toModels(
710                                                    websites), serviceContext);
711    
712                            return com.liferay.portal.model.OrganizationSoap.toSoapModel(returnValue);
713                    }
714                    catch (Exception e) {
715                            _log.error(e, e);
716    
717                            throw new RemoteException(e.getMessage());
718                    }
719            }
720    
721            /**
722            * Updates the organization.
723            *
724            * @param organizationId the primary key of the organization
725            * @param parentOrganizationId the primary key of the organization's
726            parent organization
727            * @param name the organization's name
728            * @param type the organization's type
729            * @param recursable whether permissions of the organization are to be
730            inherited by its suborganizations
731            * @param regionId the primary key of the organization's region
732            * @param countryId the primary key of the organization's country
733            * @param statusId the organization's workflow status
734            * @param comments the comments about the organization
735            * @param site whether the organization is to be associated with a main
736            site
737            * @param serviceContext the service context to be applied (optionally
738            <code>null</code>). Can set asset category IDs and asset tag
739            names for the organization, and merge expando bridge
740            attributes for the organization.
741            * @return the organization
742            * @throws PortalException if an organization or parent organization
743            with the primary key could not be found, if the user did not
744            have permission to update the organization, or if the new
745            information was invalid
746            * @throws SystemException if a system exception occurred
747            * @deprecated As of 6.2.0, replaced by {@link #updateOrganization(long,
748            long, String, String, long, long, int, String, boolean,
749            ServiceContext)}
750            */
751            public static com.liferay.portal.model.OrganizationSoap updateOrganization(
752                    long organizationId, long parentOrganizationId, java.lang.String name,
753                    java.lang.String type, boolean recursable, long regionId,
754                    long countryId, int statusId, java.lang.String comments, boolean site,
755                    com.liferay.portal.service.ServiceContext serviceContext)
756                    throws RemoteException {
757                    try {
758                            com.liferay.portal.model.Organization returnValue = OrganizationServiceUtil.updateOrganization(organizationId,
759                                            parentOrganizationId, name, type, recursable, regionId,
760                                            countryId, statusId, comments, site, serviceContext);
761    
762                            return com.liferay.portal.model.OrganizationSoap.toSoapModel(returnValue);
763                    }
764                    catch (Exception e) {
765                            _log.error(e, e);
766    
767                            throw new RemoteException(e.getMessage());
768                    }
769            }
770    
771            /**
772            * Updates the organization with additional parameters.
773            *
774            * @param organizationId the primary key of the organization
775            * @param parentOrganizationId the primary key of the organization's parent
776            organization
777            * @param name the organization's name
778            * @param type the organization's type
779            * @param regionId the primary key of the organization's region
780            * @param countryId the primary key of the organization's country
781            * @param statusId the organization's workflow status
782            * @param comments the comments about the organization
783            * @param site whether the organization is to be associated with a main
784            site
785            * @param addresses the organization's addresses
786            * @param emailAddresses the organization's email addresses
787            * @param orgLabors the organization's hours of operation
788            * @param phones the organization's phone numbers
789            * @param websites the organization's websites
790            * @param serviceContext the service context to be applied (optionally
791            <code>null</code>). Can set asset category IDs and asset tag
792            names for the organization, and merge expando bridge attributes
793            for the organization.
794            * @return the organization
795            * @throws PortalException if an organization or parent organization with
796            the primary key could not be found, if the user did not have
797            permission to update the organization information, or if the new
798            information was invalid
799            * @throws SystemException if a system exception occurred
800            */
801            public static com.liferay.portal.model.OrganizationSoap updateOrganization(
802                    long organizationId, long parentOrganizationId, java.lang.String name,
803                    java.lang.String type, long regionId, long countryId, int statusId,
804                    java.lang.String comments, boolean site,
805                    com.liferay.portal.model.AddressSoap[] addresses,
806                    com.liferay.portal.model.EmailAddressSoap[] emailAddresses,
807                    com.liferay.portal.model.OrgLaborSoap[] orgLabors,
808                    com.liferay.portal.model.PhoneSoap[] phones,
809                    com.liferay.portal.model.WebsiteSoap[] websites,
810                    com.liferay.portal.service.ServiceContext serviceContext)
811                    throws RemoteException {
812                    try {
813                            com.liferay.portal.model.Organization returnValue = OrganizationServiceUtil.updateOrganization(organizationId,
814                                            parentOrganizationId, name, type, regionId, countryId,
815                                            statusId, comments, site,
816                                            com.liferay.portal.model.impl.AddressModelImpl.toModels(
817                                                    addresses),
818                                            com.liferay.portal.model.impl.EmailAddressModelImpl.toModels(
819                                                    emailAddresses),
820                                            com.liferay.portal.model.impl.OrgLaborModelImpl.toModels(
821                                                    orgLabors),
822                                            com.liferay.portal.model.impl.PhoneModelImpl.toModels(
823                                                    phones),
824                                            com.liferay.portal.model.impl.WebsiteModelImpl.toModels(
825                                                    websites), serviceContext);
826    
827                            return com.liferay.portal.model.OrganizationSoap.toSoapModel(returnValue);
828                    }
829                    catch (Exception e) {
830                            _log.error(e, e);
831    
832                            throw new RemoteException(e.getMessage());
833                    }
834            }
835    
836            /**
837            * Updates the organization.
838            *
839            * @param organizationId the primary key of the organization
840            * @param parentOrganizationId the primary key of the organization's parent
841            organization
842            * @param name the organization's name
843            * @param type the organization's type
844            * @param regionId the primary key of the organization's region
845            * @param countryId the primary key of the organization's country
846            * @param statusId the organization's workflow status
847            * @param comments the comments about the organization
848            * @param site whether the organization is to be associated with a main
849            site
850            * @param serviceContext the service context to be applied (optionally
851            <code>null</code>). Can set asset category IDs and asset tag
852            names for the organization, and merge expando bridge attributes
853            for the organization.
854            * @return the organization
855            * @throws PortalException if an organization or parent organization with
856            the primary key could not be found, if the user did not have
857            permission to update the organization, or if the new information
858            was invalid
859            * @throws SystemException if a system exception occurred
860            */
861            public static com.liferay.portal.model.OrganizationSoap updateOrganization(
862                    long organizationId, long parentOrganizationId, java.lang.String name,
863                    java.lang.String type, long regionId, long countryId, int statusId,
864                    java.lang.String comments, boolean site,
865                    com.liferay.portal.service.ServiceContext serviceContext)
866                    throws RemoteException {
867                    try {
868                            com.liferay.portal.model.Organization returnValue = OrganizationServiceUtil.updateOrganization(organizationId,
869                                            parentOrganizationId, name, type, regionId, countryId,
870                                            statusId, comments, site, serviceContext);
871    
872                            return com.liferay.portal.model.OrganizationSoap.toSoapModel(returnValue);
873                    }
874                    catch (Exception e) {
875                            _log.error(e, e);
876    
877                            throw new RemoteException(e.getMessage());
878                    }
879            }
880    
881            private static Log _log = LogFactoryUtil.getLog(OrganizationServiceSoap.class);
882    }