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;
016    
017    import com.liferay.portal.kernel.bean.PortalBeanLocatorUtil;
018    import com.liferay.portal.kernel.util.ReferenceRegistry;
019    
020    /**
021     * The utility for the company local service. This utility wraps {@link com.liferay.portal.service.impl.CompanyLocalServiceImpl} and is the primary access point for service operations in application layer code running on the local server.
022     *
023     * <p>
024     * This is a local service. Methods of this service will not have security checks based on the propagated JAAS credentials because this service can only be accessed from within the same VM.
025     * </p>
026     *
027     * @author Brian Wing Shun Chan
028     * @see CompanyLocalService
029     * @see com.liferay.portal.service.base.CompanyLocalServiceBaseImpl
030     * @see com.liferay.portal.service.impl.CompanyLocalServiceImpl
031     * @generated
032     */
033    public class CompanyLocalServiceUtil {
034            /*
035             * NOTE FOR DEVELOPERS:
036             *
037             * Never modify this class directly. Add custom service methods to {@link com.liferay.portal.service.impl.CompanyLocalServiceImpl} and rerun ServiceBuilder to regenerate this class.
038             */
039    
040            /**
041            * Adds the company to the database. Also notifies the appropriate model listeners.
042            *
043            * @param company the company
044            * @return the company that was added
045            * @throws SystemException if a system exception occurred
046            */
047            public static com.liferay.portal.model.Company addCompany(
048                    com.liferay.portal.model.Company company)
049                    throws com.liferay.portal.kernel.exception.SystemException {
050                    return getService().addCompany(company);
051            }
052    
053            /**
054            * Creates a new company with the primary key. Does not add the company to the database.
055            *
056            * @param companyId the primary key for the new company
057            * @return the new company
058            */
059            public static com.liferay.portal.model.Company createCompany(long companyId) {
060                    return getService().createCompany(companyId);
061            }
062    
063            /**
064            * Deletes the company with the primary key from the database. Also notifies the appropriate model listeners.
065            *
066            * @param companyId the primary key of the company
067            * @return the company that was removed
068            * @throws PortalException if a company with the primary key could not be found
069            * @throws SystemException if a system exception occurred
070            */
071            public static com.liferay.portal.model.Company deleteCompany(long companyId)
072                    throws com.liferay.portal.kernel.exception.PortalException,
073                            com.liferay.portal.kernel.exception.SystemException {
074                    return getService().deleteCompany(companyId);
075            }
076    
077            /**
078            * Deletes the company from the database. Also notifies the appropriate model listeners.
079            *
080            * @param company the company
081            * @return the company that was removed
082            * @throws SystemException if a system exception occurred
083            */
084            public static com.liferay.portal.model.Company deleteCompany(
085                    com.liferay.portal.model.Company company)
086                    throws com.liferay.portal.kernel.exception.SystemException {
087                    return getService().deleteCompany(company);
088            }
089    
090            public static com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery() {
091                    return getService().dynamicQuery();
092            }
093    
094            /**
095            * Performs a dynamic query on the database and returns the matching rows.
096            *
097            * @param dynamicQuery the dynamic query
098            * @return the matching rows
099            * @throws SystemException if a system exception occurred
100            */
101            @SuppressWarnings("rawtypes")
102            public static java.util.List dynamicQuery(
103                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
104                    throws com.liferay.portal.kernel.exception.SystemException {
105                    return getService().dynamicQuery(dynamicQuery);
106            }
107    
108            /**
109            * Performs a dynamic query on the database and returns a range of the matching rows.
110            *
111            * <p>
112            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
113            * </p>
114            *
115            * @param dynamicQuery the dynamic query
116            * @param start the lower bound of the range of model instances
117            * @param end the upper bound of the range of model instances (not inclusive)
118            * @return the range of matching rows
119            * @throws SystemException if a system exception occurred
120            */
121            @SuppressWarnings("rawtypes")
122            public static java.util.List dynamicQuery(
123                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
124                    int end) throws com.liferay.portal.kernel.exception.SystemException {
125                    return getService().dynamicQuery(dynamicQuery, start, end);
126            }
127    
128            /**
129            * Performs a dynamic query on the database and returns an ordered range of the matching rows.
130            *
131            * <p>
132            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
133            * </p>
134            *
135            * @param dynamicQuery the dynamic query
136            * @param start the lower bound of the range of model instances
137            * @param end the upper bound of the range of model instances (not inclusive)
138            * @param orderByComparator the comparator to order the results by (optionally <code>null</code>)
139            * @return the ordered range of matching rows
140            * @throws SystemException if a system exception occurred
141            */
142            @SuppressWarnings("rawtypes")
143            public static java.util.List dynamicQuery(
144                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start,
145                    int end,
146                    com.liferay.portal.kernel.util.OrderByComparator orderByComparator)
147                    throws com.liferay.portal.kernel.exception.SystemException {
148                    return getService()
149                                       .dynamicQuery(dynamicQuery, start, end, orderByComparator);
150            }
151    
152            /**
153            * Returns the number of rows that match the dynamic query.
154            *
155            * @param dynamicQuery the dynamic query
156            * @return the number of rows that match the dynamic query
157            * @throws SystemException if a system exception occurred
158            */
159            public static long dynamicQueryCount(
160                    com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery)
161                    throws com.liferay.portal.kernel.exception.SystemException {
162                    return getService().dynamicQueryCount(dynamicQuery);
163            }
164    
165            public static com.liferay.portal.model.Company fetchCompany(long companyId)
166                    throws com.liferay.portal.kernel.exception.SystemException {
167                    return getService().fetchCompany(companyId);
168            }
169    
170            /**
171            * Returns the company with the primary key.
172            *
173            * @param companyId the primary key of the company
174            * @return the company
175            * @throws PortalException if a company with the primary key could not be found
176            * @throws SystemException if a system exception occurred
177            */
178            public static com.liferay.portal.model.Company getCompany(long companyId)
179                    throws com.liferay.portal.kernel.exception.PortalException,
180                            com.liferay.portal.kernel.exception.SystemException {
181                    return getService().getCompany(companyId);
182            }
183    
184            public static com.liferay.portal.model.PersistedModel getPersistedModel(
185                    java.io.Serializable primaryKeyObj)
186                    throws com.liferay.portal.kernel.exception.PortalException,
187                            com.liferay.portal.kernel.exception.SystemException {
188                    return getService().getPersistedModel(primaryKeyObj);
189            }
190    
191            /**
192            * Returns a range of all the companies.
193            *
194            * <p>
195            * Useful when paginating results. Returns a maximum of <code>end - start</code> instances. <code>start</code> and <code>end</code> are not primary keys, they are indexes in the result set. Thus, <code>0</code> refers to the first result in the set. Setting both <code>start</code> and <code>end</code> to {@link com.liferay.portal.kernel.dao.orm.QueryUtil#ALL_POS} will return the full result set.
196            * </p>
197            *
198            * @param start the lower bound of the range of companies
199            * @param end the upper bound of the range of companies (not inclusive)
200            * @return the range of companies
201            * @throws SystemException if a system exception occurred
202            */
203            public static java.util.List<com.liferay.portal.model.Company> getCompanies(
204                    int start, int end)
205                    throws com.liferay.portal.kernel.exception.SystemException {
206                    return getService().getCompanies(start, end);
207            }
208    
209            /**
210            * Returns the number of companies.
211            *
212            * @return the number of companies
213            * @throws SystemException if a system exception occurred
214            */
215            public static int getCompaniesCount()
216                    throws com.liferay.portal.kernel.exception.SystemException {
217                    return getService().getCompaniesCount();
218            }
219    
220            /**
221            * Updates the company in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.
222            *
223            * @param company the company
224            * @return the company that was updated
225            * @throws SystemException if a system exception occurred
226            */
227            public static com.liferay.portal.model.Company updateCompany(
228                    com.liferay.portal.model.Company company)
229                    throws com.liferay.portal.kernel.exception.SystemException {
230                    return getService().updateCompany(company);
231            }
232    
233            /**
234            * Updates the company in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners.
235            *
236            * @param company the company
237            * @param merge whether to merge the company with the current session. See {@link com.liferay.portal.service.persistence.BatchSession#update(com.liferay.portal.kernel.dao.orm.Session, com.liferay.portal.model.BaseModel, boolean)} for an explanation.
238            * @return the company that was updated
239            * @throws SystemException if a system exception occurred
240            */
241            public static com.liferay.portal.model.Company updateCompany(
242                    com.liferay.portal.model.Company company, boolean merge)
243                    throws com.liferay.portal.kernel.exception.SystemException {
244                    return getService().updateCompany(company, merge);
245            }
246    
247            /**
248            * Returns the Spring bean ID for this bean.
249            *
250            * @return the Spring bean ID for this bean
251            */
252            public static java.lang.String getBeanIdentifier() {
253                    return getService().getBeanIdentifier();
254            }
255    
256            /**
257            * Sets the Spring bean ID for this bean.
258            *
259            * @param beanIdentifier the Spring bean ID for this bean
260            */
261            public static void setBeanIdentifier(java.lang.String beanIdentifier) {
262                    getService().setBeanIdentifier(beanIdentifier);
263            }
264    
265            /**
266            * Adds a company.
267            *
268            * @param webId the the company's web domain
269            * @param virtualHostname the company's virtual host name
270            * @param mx the company's mail domain
271            * @param shardName the company's shard
272            * @param system whether the company is the very first company (i.e., the
273            super company)
274            * @param maxUsers the max number of company users (optionally
275            <code>0</code>)
276            * @param active whether the company is active
277            * @return the company
278            * @throws PortalException if the web domain, virtual host name, or mail
279            domain was invalid
280            * @throws SystemException if a system exception occurred
281            */
282            public static com.liferay.portal.model.Company addCompany(
283                    java.lang.String webId, java.lang.String virtualHostname,
284                    java.lang.String mx, java.lang.String shardName, boolean system,
285                    int maxUsers, boolean active)
286                    throws com.liferay.portal.kernel.exception.PortalException,
287                            com.liferay.portal.kernel.exception.SystemException {
288                    return getService()
289                                       .addCompany(webId, virtualHostname, mx, shardName, system,
290                            maxUsers, active);
291            }
292    
293            /**
294            * Returns the company with the web domain.
295            *
296            * The method sets mail domain to the web domain, and the shard name to
297            * the default name set in portal.properties
298            *
299            * @param webId the company's web domain
300            * @return the company with the web domain
301            * @throws PortalException if a portal exception occurred
302            * @throws SystemException if a system exception occurred
303            */
304            public static com.liferay.portal.model.Company checkCompany(
305                    java.lang.String webId)
306                    throws com.liferay.portal.kernel.exception.PortalException,
307                            com.liferay.portal.kernel.exception.SystemException {
308                    return getService().checkCompany(webId);
309            }
310    
311            /**
312            * Returns the company with the web domain, mail domain, and shard. If no
313            * such company exits, the method will create a new company.
314            *
315            * The method goes through a series of checks to ensure that the company
316            * contains default users, groups, etc.
317            *
318            * @param webId the company's web domain
319            * @param mx the company's mail domain
320            * @param shardName the company's shard
321            * @return the company with the web domain, mail domain, and shard
322            * @throws PortalException if a portal exception occurred
323            * @throws SystemException if a system exception occurred
324            */
325            public static com.liferay.portal.model.Company checkCompany(
326                    java.lang.String webId, java.lang.String mx, java.lang.String shardName)
327                    throws com.liferay.portal.kernel.exception.PortalException,
328                            com.liferay.portal.kernel.exception.SystemException {
329                    return getService().checkCompany(webId, mx, shardName);
330            }
331    
332            /**
333            * Checks if the company has an encryption key. It will create a key if one
334            * does not exist.
335            *
336            * @param companyId the primary key of the company
337            * @throws PortalException if a company with the primary key could not be
338            found
339            * @throws SystemException if a system exception occurred
340            */
341            public static void checkCompanyKey(long companyId)
342                    throws com.liferay.portal.kernel.exception.PortalException,
343                            com.liferay.portal.kernel.exception.SystemException {
344                    getService().checkCompanyKey(companyId);
345            }
346    
347            /**
348            * Deletes the company's logo.
349            *
350            * @param companyId the primary key of the company
351            * @throws PortalException if the company with the primary key could not be
352            found or if the company's logo could not be found
353            * @throws SystemException if a system exception occurred
354            */
355            public static void deleteLogo(long companyId)
356                    throws com.liferay.portal.kernel.exception.PortalException,
357                            com.liferay.portal.kernel.exception.SystemException {
358                    getService().deleteLogo(companyId);
359            }
360    
361            /**
362            * Returns the company with the primary key.
363            *
364            * @param companyId the primary key of the company
365            * @return the company with the primary key, <code>null</code> if a company
366            with the primary key could not be found
367            * @throws SystemException if a system exception occurred
368            */
369            public static com.liferay.portal.model.Company fetchCompanyById(
370                    long companyId)
371                    throws com.liferay.portal.kernel.exception.SystemException {
372                    return getService().fetchCompanyById(companyId);
373            }
374    
375            /**
376            * Returns the company with the virtual host name.
377            *
378            * @param virtualHostname the virtual host name
379            * @return the company with the virtual host name, <code>null</code> if a
380            company with the virtual host could not be found
381            * @throws SystemException if a system exception occurred
382            */
383            public static com.liferay.portal.model.Company fetchCompanyByVirtualHost(
384                    java.lang.String virtualHostname)
385                    throws com.liferay.portal.kernel.exception.SystemException {
386                    return getService().fetchCompanyByVirtualHost(virtualHostname);
387            }
388    
389            /**
390            * Returns all the companies.
391            *
392            * @return the companies
393            * @throws SystemException if a system exception occurred
394            */
395            public static java.util.List<com.liferay.portal.model.Company> getCompanies()
396                    throws com.liferay.portal.kernel.exception.SystemException {
397                    return getService().getCompanies();
398            }
399    
400            /**
401            * Returns all the companies used by WSRP.
402            *
403            * @param system whether the company is the very first company (i.e., the
404            super company)
405            * @return the companies used by WSRP
406            * @throws SystemException if a system exception occurred
407            */
408            public static java.util.List<com.liferay.portal.model.Company> getCompanies(
409                    boolean system)
410                    throws com.liferay.portal.kernel.exception.SystemException {
411                    return getService().getCompanies(system);
412            }
413    
414            /**
415            * Returns the number of companies used by WSRP.
416            *
417            * @param system whether the company is the very first company (i.e., the
418            super company)
419            * @return the number of companies used by WSRP
420            * @throws SystemException if a system exception occurred
421            */
422            public static int getCompaniesCount(boolean system)
423                    throws com.liferay.portal.kernel.exception.SystemException {
424                    return getService().getCompaniesCount(system);
425            }
426    
427            /**
428            * Returns the company with the primary key.
429            *
430            * @param companyId the primary key of the company
431            * @return the company with the primary key
432            * @throws PortalException if a company with the primary key could not be
433            found
434            * @throws SystemException if a system exception occurred
435            */
436            public static com.liferay.portal.model.Company getCompanyById(
437                    long companyId)
438                    throws com.liferay.portal.kernel.exception.PortalException,
439                            com.liferay.portal.kernel.exception.SystemException {
440                    return getService().getCompanyById(companyId);
441            }
442    
443            /**
444            * Returns the company with the logo.
445            *
446            * @param logoId the ID of the company's logo
447            * @return the company with the logo
448            * @throws PortalException if the company with the logo could not be found
449            * @throws SystemException if a system exception occurred
450            */
451            public static com.liferay.portal.model.Company getCompanyByLogoId(
452                    long logoId)
453                    throws com.liferay.portal.kernel.exception.PortalException,
454                            com.liferay.portal.kernel.exception.SystemException {
455                    return getService().getCompanyByLogoId(logoId);
456            }
457    
458            /**
459            * Returns the company with the mail domain.
460            *
461            * @param mx the company's mail domain
462            * @return the company with the mail domain
463            * @throws PortalException if the company with the mail domain could not be
464            found
465            * @throws SystemException if a system exception occurred
466            */
467            public static com.liferay.portal.model.Company getCompanyByMx(
468                    java.lang.String mx)
469                    throws com.liferay.portal.kernel.exception.PortalException,
470                            com.liferay.portal.kernel.exception.SystemException {
471                    return getService().getCompanyByMx(mx);
472            }
473    
474            /**
475            * Returns the company with the virtual host name.
476            *
477            * @param virtualHostname the company's virtual host name
478            * @return the company with the virtual host name
479            * @throws PortalException if the company with the virtual host name could
480            not be found or if the virtual host was not associated with a
481            company
482            * @throws SystemException if a system exception occurred
483            */
484            public static com.liferay.portal.model.Company getCompanyByVirtualHost(
485                    java.lang.String virtualHostname)
486                    throws com.liferay.portal.kernel.exception.PortalException,
487                            com.liferay.portal.kernel.exception.SystemException {
488                    return getService().getCompanyByVirtualHost(virtualHostname);
489            }
490    
491            /**
492            * Returns the company with the web domain.
493            *
494            * @param webId the company's web domain
495            * @return the company with the web domain
496            * @throws PortalException if the company with the web domain could not be
497            found
498            * @throws SystemException if a system exception occurred
499            */
500            public static com.liferay.portal.model.Company getCompanyByWebId(
501                    java.lang.String webId)
502                    throws com.liferay.portal.kernel.exception.PortalException,
503                            com.liferay.portal.kernel.exception.SystemException {
504                    return getService().getCompanyByWebId(webId);
505            }
506    
507            /**
508            * Returns the user's company.
509            *
510            * @param userId the primary key of the user
511            * @return Returns the first company if there is only one company or the
512            user's company if there are more than one company; <code>0</code>
513            otherwise
514            * @throws Exception if a user with the primary key could not be found
515            */
516            public static long getCompanyIdByUserId(long userId)
517                    throws java.lang.Exception {
518                    return getService().getCompanyIdByUserId(userId);
519            }
520    
521            /**
522            * Removes the values that match the keys of the company's preferences.
523            *
524            * This method is called by {@link
525            * com.liferay.portlet.portalsettings.action.EditLDAPServerAction} remotely
526            * through {@link com.liferay.portal.service.CompanyService}.
527            *
528            * @param companyId the primary key of the company
529            * @param keys the company's preferences keys to be remove
530            * @throws SystemException if a system exception occurred
531            */
532            public static void removePreferences(long companyId, java.lang.String[] keys)
533                    throws com.liferay.portal.kernel.exception.SystemException {
534                    getService().removePreferences(companyId, keys);
535            }
536    
537            /**
538            * Returns an ordered range of all assets that match the keywords in the
539            * company.
540            *
541            * The method is called in {@link
542            * com.liferay.portal.search.PortalOpenSearchImpl} which is not longer used
543            * by the Search portlet.
544            *
545            * @param companyId the primary key of the company
546            * @param userId the primary key of the user
547            * @param keywords the keywords (space separated),which may occur in assets
548            in the company (optionally <code>null</code>)
549            * @param start the lower bound of the range of assets to return
550            * @param end the upper bound of the range of assets to return (not
551            inclusive)
552            * @return the matching assets in the company
553            * @throws SystemException if a system exception occurred
554            */
555            public static com.liferay.portal.kernel.search.Hits search(long companyId,
556                    long userId, java.lang.String keywords, int start, int end)
557                    throws com.liferay.portal.kernel.exception.SystemException {
558                    return getService().search(companyId, userId, keywords, start, end);
559            }
560    
561            /**
562            * Returns an ordered range of all assets that match the keywords in the
563            * portlet within the company.
564            *
565            * @param companyId the primary key of the company
566            * @param userId the primary key of the user
567            * @param portletId the primary key of the portlet (optionally
568            <code>null</code>)
569            * @param groupId the primary key of the group (optionally <code>0</code>)
570            * @param type the mime type of assets to return(optionally
571            <code>null</code>)
572            * @param keywords the keywords (space separated), which may occur in any
573            assets in the portlet (optionally <code>null</code>)
574            * @param start the lower bound of the range of assets to return
575            * @param end the upper bound of the range of assets to return (not
576            inclusive)
577            * @return the matching assets in the portlet within the company
578            * @throws SystemException if a system exception occurred
579            */
580            public static com.liferay.portal.kernel.search.Hits search(long companyId,
581                    long userId, java.lang.String portletId, long groupId,
582                    java.lang.String type, java.lang.String keywords, int start, int end)
583                    throws com.liferay.portal.kernel.exception.SystemException {
584                    return getService()
585                                       .search(companyId, userId, portletId, groupId, type,
586                            keywords, start, end);
587            }
588    
589            /**
590            * Updates the company.
591            *
592            * @param companyId the primary key of the company
593            * @param virtualHostname the company's virtual host name
594            * @param mx the company's mail domain
595            * @param maxUsers the max number of company users (optionally
596            <code>0</code>)
597            * @param active whether the company is active
598            * @return the company with the primary key
599            * @throws PortalException if a company with primary key could not be found
600            or if the new information was invalid
601            * @throws SystemException if a system exception occurred
602            */
603            public static com.liferay.portal.model.Company updateCompany(
604                    long companyId, java.lang.String virtualHostname, java.lang.String mx,
605                    int maxUsers, boolean active)
606                    throws com.liferay.portal.kernel.exception.PortalException,
607                            com.liferay.portal.kernel.exception.SystemException {
608                    return getService()
609                                       .updateCompany(companyId, virtualHostname, mx, maxUsers,
610                            active);
611            }
612    
613            /**
614            * Update the company with additional account information.
615            *
616            * @param companyId the primary key of the company
617            * @param virtualHostname the company's virtual host name
618            * @param mx the company's mail domain
619            * @param homeURL the company's home URL (optionally <code>null</code>)
620            * @param name the company's account name(optionally <code>null</code>)
621            * @param legalName the company's account legal name (optionally
622            <code>null</code>)
623            * @param legalId the company's account legal ID (optionally
624            <code>null</code>)
625            * @param legalType the company's account legal type (optionally
626            <code>null</code>)
627            * @param sicCode the company's account SIC code (optionally
628            <code>null</code>)
629            * @param tickerSymbol the company's account ticker symbol (optionally
630            <code>null</code>)
631            * @param industry the company's account industry (optionally
632            <code>null</code>)
633            * @param type the company's account type (optionally <code>null</code>)
634            * @param size the company's account size (optionally <code>null</code>)
635            * @return the company with the primary key
636            * @throws PortalException if a company with the primary key could not be
637            found or if the new information was invalid
638            * @throws SystemException if a system exception occurred
639            */
640            public static com.liferay.portal.model.Company updateCompany(
641                    long companyId, java.lang.String virtualHostname, java.lang.String mx,
642                    java.lang.String homeURL, java.lang.String name,
643                    java.lang.String legalName, java.lang.String legalId,
644                    java.lang.String legalType, java.lang.String sicCode,
645                    java.lang.String tickerSymbol, java.lang.String industry,
646                    java.lang.String type, java.lang.String size)
647                    throws com.liferay.portal.kernel.exception.PortalException,
648                            com.liferay.portal.kernel.exception.SystemException {
649                    return getService()
650                                       .updateCompany(companyId, virtualHostname, mx, homeURL,
651                            name, legalName, legalId, legalType, sicCode, tickerSymbol,
652                            industry, type, size);
653            }
654    
655            /**
656            * Update the company's display.
657            *
658            * @param companyId the primary key of the company
659            * @param languageId the ID of the company's default user's language
660            * @param timeZoneId the ID of the company's default user's time zone
661            * @throws PortalException if the company's default user could not be found
662            * @throws SystemException if a system exception occurred
663            */
664            public static void updateDisplay(long companyId,
665                    java.lang.String languageId, java.lang.String timeZoneId)
666                    throws com.liferay.portal.kernel.exception.PortalException,
667                            com.liferay.portal.kernel.exception.SystemException {
668                    getService().updateDisplay(companyId, languageId, timeZoneId);
669            }
670    
671            /**
672            * Updates the company's logo.
673            *
674            * @param companyId the primary key of the company
675            * @param bytes the bytes of the company's logo image
676            * @return the company with the primary key
677            * @throws PortalException if the company's logo ID could not be found or if
678            the logo's image was corrupted
679            * @throws SystemException if a system exception occurred
680            */
681            public static com.liferay.portal.model.Company updateLogo(long companyId,
682                    byte[] bytes)
683                    throws com.liferay.portal.kernel.exception.PortalException,
684                            com.liferay.portal.kernel.exception.SystemException {
685                    return getService().updateLogo(companyId, bytes);
686            }
687    
688            /**
689            * Updates the company's logo.
690            *
691            * @param companyId the primary key of the company
692            * @param file the file of the company's logo image
693            * @return the company with the primary key
694            * @throws PortalException the company's logo ID could not be found or if
695            the logo's image was corrupted
696            * @throws SystemException if a system exception occurred
697            */
698            public static com.liferay.portal.model.Company updateLogo(long companyId,
699                    java.io.File file)
700                    throws com.liferay.portal.kernel.exception.PortalException,
701                            com.liferay.portal.kernel.exception.SystemException {
702                    return getService().updateLogo(companyId, file);
703            }
704    
705            /**
706            * Update the company's logo.
707            *
708            * @param companyId the primary key of the company
709            * @param is the input stream of the company's logo image
710            * @return the company with the primary key
711            * @throws PortalException if the company's logo ID could not be found or if
712            the company's logo image was corrupted
713            * @throws SystemException if a system exception occurred
714            */
715            public static com.liferay.portal.model.Company updateLogo(long companyId,
716                    java.io.InputStream is)
717                    throws com.liferay.portal.kernel.exception.PortalException,
718                            com.liferay.portal.kernel.exception.SystemException {
719                    return getService().updateLogo(companyId, is);
720            }
721    
722            /**
723            * Updates the company's preferences. The company's default properties are
724            * found in portal.properties.
725            *
726            * @param companyId the primary key of the company
727            * @param properties the company's properties. See {@link
728            com.liferay.portal.kernel.util.UnicodeProperties}
729            * @throws PortalException if the properties contained new locales that were
730            not supported
731            * @throws SystemException if a system exception occurred
732            */
733            public static void updatePreferences(long companyId,
734                    com.liferay.portal.kernel.util.UnicodeProperties properties)
735                    throws com.liferay.portal.kernel.exception.PortalException,
736                            com.liferay.portal.kernel.exception.SystemException {
737                    getService().updatePreferences(companyId, properties);
738            }
739    
740            /**
741            * Updates the company's security properties.
742            *
743            * @param companyId the primary key of the company
744            * @param authType the company's method of authenticating users
745            * @param autoLogin whether to allow users to select the "remember me"
746            feature
747            * @param sendPassword whether to allow users to ask the company to send
748            their password
749            * @param strangers whether to allow strangers to create accounts register
750            themselves in the company
751            * @param strangersWithMx whether to allow strangers to create accounts
752            with email addresses that match the company mail suffix
753            * @param strangersVerify whether to require strangers who create accounts
754            to be verified via email
755            * @param siteLogo whether to allow site administrators to use their own
756            logo instead of the enterprise logo
757            * @throws SystemException if a system exception occurred
758            */
759            public static void updateSecurity(long companyId,
760                    java.lang.String authType, boolean autoLogin, boolean sendPassword,
761                    boolean strangers, boolean strangersWithMx, boolean strangersVerify,
762                    boolean siteLogo)
763                    throws com.liferay.portal.kernel.exception.SystemException {
764                    getService()
765                            .updateSecurity(companyId, authType, autoLogin, sendPassword,
766                            strangers, strangersWithMx, strangersVerify, siteLogo);
767            }
768    
769            public static CompanyLocalService getService() {
770                    if (_service == null) {
771                            _service = (CompanyLocalService)PortalBeanLocatorUtil.locate(CompanyLocalService.class.getName());
772    
773                            ReferenceRegistry.registerReference(CompanyLocalServiceUtil.class,
774                                    "_service");
775                    }
776    
777                    return _service;
778            }
779    
780            /**
781             * @deprecated
782             */
783            public void setService(CompanyLocalService service) {
784            }
785    
786            private static CompanyLocalService _service;
787    }