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