001 /** 002 * Copyright (c) 2000-2012 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 /** 018 * <p> 019 * This class is a wrapper for {@link CompanyService}. 020 * </p> 021 * 022 * @author Brian Wing Shun Chan 023 * @see CompanyService 024 * @generated 025 */ 026 public class CompanyServiceWrapper implements CompanyService, 027 ServiceWrapper<CompanyService> { 028 public CompanyServiceWrapper(CompanyService companyService) { 029 _companyService = companyService; 030 } 031 032 /** 033 * Adds a company. 034 * 035 * @param webId the company's web domain 036 * @param virtualHost the company's virtual host name 037 * @param mx the company's mail domain 038 * @param shardName the company's shard 039 * @param system whether the company is the very first company (i.e., the 040 * @param maxUsers the max number of company users (optionally 041 <code>0</code>) 042 * @param active whether the company is active 043 * @return the company 044 * @throws PortalException if the web domain, virtual host name, or mail 045 domain was invalid or if the user was not a universal 046 administrator 047 * @throws SystemException if a system exception occurred 048 */ 049 public com.liferay.portal.model.Company addCompany(java.lang.String webId, 050 java.lang.String virtualHost, java.lang.String mx, 051 java.lang.String shardName, boolean system, int maxUsers, boolean active) 052 throws com.liferay.portal.kernel.exception.PortalException, 053 com.liferay.portal.kernel.exception.SystemException { 054 return _companyService.addCompany(webId, virtualHost, mx, shardName, 055 system, maxUsers, active); 056 } 057 058 /** 059 * Deletes the company's logo. 060 * 061 * @param companyId the primary key of the company 062 * @throws PortalException if the company with the primary key could not be 063 found or if the company's logo could not be found or if the user 064 was not an administrator 065 * @throws SystemException if a system exception occurred 066 */ 067 public void deleteLogo(long companyId) 068 throws com.liferay.portal.kernel.exception.PortalException, 069 com.liferay.portal.kernel.exception.SystemException { 070 _companyService.deleteLogo(companyId); 071 } 072 073 /** 074 * Returns the company with the primary key. 075 * 076 * @param companyId the primary key of the company 077 * @return Returns the company with the primary key 078 * @throws PortalException if a company with the primary key could not be 079 found 080 * @throws SystemException if a system exception occurred 081 */ 082 public com.liferay.portal.model.Company getCompanyById(long companyId) 083 throws com.liferay.portal.kernel.exception.PortalException, 084 com.liferay.portal.kernel.exception.SystemException { 085 return _companyService.getCompanyById(companyId); 086 } 087 088 /** 089 * Returns the company with the logo. 090 * 091 * @param logoId the ID of the company's logo 092 * @return Returns the company with the logo 093 * @throws PortalException if the company with the logo could not be found 094 * @throws SystemException if a system exception occurred 095 */ 096 public com.liferay.portal.model.Company getCompanyByLogoId(long logoId) 097 throws com.liferay.portal.kernel.exception.PortalException, 098 com.liferay.portal.kernel.exception.SystemException { 099 return _companyService.getCompanyByLogoId(logoId); 100 } 101 102 /** 103 * Returns the company with the mail domian. 104 * 105 * @param mx the company's mail domain 106 * @return Returns the company with the mail domain 107 * @throws PortalException if the company with the mail domain could not be 108 found 109 * @throws SystemException if a system exception occurred 110 */ 111 public com.liferay.portal.model.Company getCompanyByMx(java.lang.String mx) 112 throws com.liferay.portal.kernel.exception.PortalException, 113 com.liferay.portal.kernel.exception.SystemException { 114 return _companyService.getCompanyByMx(mx); 115 } 116 117 /** 118 * Returns the company with the virtual host name. 119 * 120 * @param virtualHost the company's virtual host name 121 * @return Returns the company with the virtual host name 122 * @throws PortalException if the company with the virtual host name could 123 not be found or if the virtual host was not associated with a 124 company 125 * @throws SystemException if a system exception occurred 126 */ 127 public com.liferay.portal.model.Company getCompanyByVirtualHost( 128 java.lang.String virtualHost) 129 throws com.liferay.portal.kernel.exception.PortalException, 130 com.liferay.portal.kernel.exception.SystemException { 131 return _companyService.getCompanyByVirtualHost(virtualHost); 132 } 133 134 /** 135 * Returns the company with the web domain. 136 * 137 * @param webId the company's web domain 138 * @return Returns the company with the web domain 139 * @throws PortalException if the company with the web domain could not be 140 found 141 * @throws SystemException if a system exception occurred 142 */ 143 public com.liferay.portal.model.Company getCompanyByWebId( 144 java.lang.String webId) 145 throws com.liferay.portal.kernel.exception.PortalException, 146 com.liferay.portal.kernel.exception.SystemException { 147 return _companyService.getCompanyByWebId(webId); 148 } 149 150 /** 151 * Removes the values that match the keys of the company's preferences. 152 * 153 * This method is called by {@link 154 * com.liferay.portlet.portalsettings.action.EditLDAPServerAction} remotely 155 * through {@link com.liferay.portal.service.CompanyService}. 156 * 157 * @param companyId the primary key of the company 158 * @param keys the company's preferences keys to be remove 159 * @throws PortalException if the user was not an administrator 160 * @throws SystemException if a system exception occurred 161 */ 162 public void removePreferences(long companyId, java.lang.String[] keys) 163 throws com.liferay.portal.kernel.exception.PortalException, 164 com.liferay.portal.kernel.exception.SystemException { 165 _companyService.removePreferences(companyId, keys); 166 } 167 168 /** 169 * Updates the company 170 * 171 * @param companyId the primary key of the company 172 * @param virtualHost the company's virtual host name 173 * @param mx the company's mail domain 174 * @param maxUsers the max number of company users (optionally 175 <code>0</code>) 176 * @param active whether the company is active 177 * @return the company with the primary key 178 * @throws PortalException if a company with the primary key could not be 179 found or if the new information was invalid or if the user was 180 not a universal administrator 181 * @throws SystemException if a system exception occurred 182 */ 183 public com.liferay.portal.model.Company updateCompany(long companyId, 184 java.lang.String virtualHost, java.lang.String mx, int maxUsers, 185 boolean active) 186 throws com.liferay.portal.kernel.exception.PortalException, 187 com.liferay.portal.kernel.exception.SystemException { 188 return _companyService.updateCompany(companyId, virtualHost, mx, 189 maxUsers, active); 190 } 191 192 /** 193 * Updates the company with additional account information. 194 * 195 * @param companyId the primary key of the company 196 * @param virtualHost the company's virtual host name 197 * @param mx the company's mail domain 198 * @param homeURL the company's home URL (optionally <code>null</code>) 199 * @param name the company's account name (optionally <code>null</code>) 200 * @param legalName the company's account legal name (optionally 201 <code>null</code>) 202 * @param legalId the company's account legal ID (optionally 203 <code>null</code>) 204 * @param legalType the company's account legal type (optionally 205 <code>null</code>) 206 * @param sicCode the company's account SIC code (optionally 207 <code>null</code>) 208 * @param tickerSymbol the company's account ticker symbol (optionally 209 <code>null</code>) 210 * @param industry the the company's account industry (optionally 211 <code>null</code>) 212 * @param type the company's account type (optionally <code>null</code>) 213 * @param size the company's account size (optionally <code>null</code>) 214 * @return the the company with the primary key 215 * @throws PortalException if a company with the primary key could not be 216 found or if the new information was invalid or if the user was 217 not an administrator 218 * @throws SystemException if a system exception occurred 219 */ 220 public com.liferay.portal.model.Company updateCompany(long companyId, 221 java.lang.String virtualHost, java.lang.String mx, 222 java.lang.String homeURL, java.lang.String name, 223 java.lang.String legalName, java.lang.String legalId, 224 java.lang.String legalType, java.lang.String sicCode, 225 java.lang.String tickerSymbol, java.lang.String industry, 226 java.lang.String type, java.lang.String size) 227 throws com.liferay.portal.kernel.exception.PortalException, 228 com.liferay.portal.kernel.exception.SystemException { 229 return _companyService.updateCompany(companyId, virtualHost, mx, 230 homeURL, name, legalName, legalId, legalType, sicCode, 231 tickerSymbol, industry, type, size); 232 } 233 234 /** 235 * Updates the company with addition information. 236 * 237 * @param companyId the primary key of the company 238 * @param virtualHost the company's virtual host name 239 * @param mx the company's mail domain 240 * @param homeURL the company's home URL (optionally <code>null</code>) 241 * @param name the company's account name (optionally <code>null</code>) 242 * @param legalName the company's account legal name (optionally 243 <code>null</code>) 244 * @param legalId the company's accout legal ID (optionally 245 <code>null</code>) 246 * @param legalType the company's account legal type (optionally 247 <code>null</code>) 248 * @param sicCode the company's account SIC code (optionally 249 <code>null</code>) 250 * @param tickerSymbol the company's account ticker symbol (optionally 251 <code>null</code>) 252 * @param industry the the company's account industry (optionally 253 <code>null</code>) 254 * @param type the company's account type (optionally <code>null</code>) 255 * @param size the company's account size (optionally <code>null</code>) 256 * @param languageId the ID of the company's default user's language 257 * @param timeZoneId the ID of the company's default user's time zone 258 * @param addresses the company's addresses 259 * @param emailAddresses the company's email addresses 260 * @param phones the company's phone numbers 261 * @param websites the company's websites 262 * @param properties the company's properties 263 * @return the company with the primary key 264 * @throws PortalException the company with the primary key could not be 265 found or if the new information was invalid or if the user was 266 not an administrator 267 * @throws SystemException if a system exception occurred 268 */ 269 public com.liferay.portal.model.Company updateCompany(long companyId, 270 java.lang.String virtualHost, java.lang.String mx, 271 java.lang.String homeURL, java.lang.String name, 272 java.lang.String legalName, java.lang.String legalId, 273 java.lang.String legalType, java.lang.String sicCode, 274 java.lang.String tickerSymbol, java.lang.String industry, 275 java.lang.String type, java.lang.String size, 276 java.lang.String languageId, java.lang.String timeZoneId, 277 java.util.List<com.liferay.portal.model.Address> addresses, 278 java.util.List<com.liferay.portal.model.EmailAddress> emailAddresses, 279 java.util.List<com.liferay.portal.model.Phone> phones, 280 java.util.List<com.liferay.portal.model.Website> websites, 281 com.liferay.portal.kernel.util.UnicodeProperties properties) 282 throws com.liferay.portal.kernel.exception.PortalException, 283 com.liferay.portal.kernel.exception.SystemException { 284 return _companyService.updateCompany(companyId, virtualHost, mx, 285 homeURL, name, legalName, legalId, legalType, sicCode, 286 tickerSymbol, industry, type, size, languageId, timeZoneId, 287 addresses, emailAddresses, phones, websites, properties); 288 } 289 290 /** 291 * Update the company's display. 292 * 293 * @param companyId the primary key of the company 294 * @param languageId the ID of the company's default user's language 295 * @param timeZoneId the ID of the company's default user's time zone 296 * @throws PortalException if the company's default user could not be found 297 or if the user was not an administrator 298 * @throws SystemException if a system exception occurred 299 */ 300 public void updateDisplay(long companyId, java.lang.String languageId, 301 java.lang.String timeZoneId) 302 throws com.liferay.portal.kernel.exception.PortalException, 303 com.liferay.portal.kernel.exception.SystemException { 304 _companyService.updateDisplay(companyId, languageId, timeZoneId); 305 } 306 307 /** 308 * Updates the company's logo. 309 * 310 * @param companyId the primary key of the company 311 * @param inputStream the input stream of the company's logo image 312 * @return the company with the primary key 313 * @throws PortalException if the company's logo ID could not be found or if 314 the logo's image was corrupted or if the user was an 315 administrator 316 * @throws SystemException if a system exception occurred 317 */ 318 public com.liferay.portal.model.Company updateLogo(long companyId, 319 java.io.InputStream inputStream) 320 throws com.liferay.portal.kernel.exception.PortalException, 321 com.liferay.portal.kernel.exception.SystemException { 322 return _companyService.updateLogo(companyId, inputStream); 323 } 324 325 /** 326 * Updates the company's preferences. The company's default properties are 327 * found in portal.properties. 328 * 329 * @param companyId the primary key of the company 330 * @param properties the company's properties. See {@link 331 com.liferay.portal.kernel.util.UnicodeProperties} 332 * @throws PortalException if the user was not an administrator 333 * @throws SystemException if a system exception occurred 334 */ 335 public void updatePreferences(long companyId, 336 com.liferay.portal.kernel.util.UnicodeProperties properties) 337 throws com.liferay.portal.kernel.exception.PortalException, 338 com.liferay.portal.kernel.exception.SystemException { 339 _companyService.updatePreferences(companyId, properties); 340 } 341 342 /** 343 * Updates the company's security properties. 344 * 345 * @param companyId the primary key of the company 346 * @param authType the company's method of authenticating users 347 * @param autoLogin whether to allow users to select the "remember me" 348 feature 349 * @param sendPassword whether to allow users to ask the company to send 350 their passwords 351 * @param strangers whether to allow strangers to create accounts to 352 register themselves in the company 353 * @param strangersWithMx whether to allow strangers to create accounts 354 with email addresses that match the company mail suffix 355 * @param strangersVerify whether to require strangers who create accounts 356 to be verified via email 357 * @param siteLogo whether to to allow site administrators to use their own 358 logo instead of the enterprise logo 359 * @throws PortalException if the user was not an administrator 360 * @throws SystemException if a system exception occurred 361 */ 362 public void updateSecurity(long companyId, java.lang.String authType, 363 boolean autoLogin, boolean sendPassword, boolean strangers, 364 boolean strangersWithMx, boolean strangersVerify, boolean siteLogo) 365 throws com.liferay.portal.kernel.exception.PortalException, 366 com.liferay.portal.kernel.exception.SystemException { 367 _companyService.updateSecurity(companyId, authType, autoLogin, 368 sendPassword, strangers, strangersWithMx, strangersVerify, siteLogo); 369 } 370 371 /** 372 * @deprecated Renamed to {@link #getWrappedService} 373 */ 374 public CompanyService getWrappedCompanyService() { 375 return _companyService; 376 } 377 378 /** 379 * @deprecated Renamed to {@link #setWrappedService} 380 */ 381 public void setWrappedCompanyService(CompanyService companyService) { 382 _companyService = companyService; 383 } 384 385 public CompanyService getWrappedService() { 386 return _companyService; 387 } 388 389 public void setWrappedService(CompanyService companyService) { 390 _companyService = companyService; 391 } 392 393 private CompanyService _companyService; 394 }