001 /** 002 * Copyright (c) 2000-2010 Liferay, Inc. All rights reserved. 003 * 004 * The contents of this file are subject to the terms of the Liferay Enterprise 005 * Subscription License ("License"). You may not use this file except in 006 * compliance with the License. You can obtain a copy of the License by 007 * contacting Liferay, Inc. See the License for the specific language governing 008 * permissions and limitations under the License, including but not limited to 009 * distribution rights of the Software. 010 * 011 * 012 * 013 */ 014 015 package com.liferay.portal.service; 016 017 /** 018 * <p> 019 * This class is a wrapper for {@link AddressLocalService}. 020 * </p> 021 * 022 * @author Brian Wing Shun Chan 023 * @see AddressLocalService 024 * @generated 025 */ 026 public class AddressLocalServiceWrapper implements AddressLocalService { 027 public AddressLocalServiceWrapper(AddressLocalService addressLocalService) { 028 _addressLocalService = addressLocalService; 029 } 030 031 /** 032 * Adds the address to the database. Also notifies the appropriate model listeners. 033 * 034 * @param address the address to add 035 * @return the address that was added 036 * @throws SystemException if a system exception occurred 037 */ 038 public com.liferay.portal.model.Address addAddress( 039 com.liferay.portal.model.Address address) 040 throws com.liferay.portal.kernel.exception.SystemException { 041 return _addressLocalService.addAddress(address); 042 } 043 044 /** 045 * Creates a new address with the primary key. Does not add the address to the database. 046 * 047 * @param addressId the primary key for the new address 048 * @return the new address 049 */ 050 public com.liferay.portal.model.Address createAddress(long addressId) { 051 return _addressLocalService.createAddress(addressId); 052 } 053 054 /** 055 * Deletes the address with the primary key from the database. Also notifies the appropriate model listeners. 056 * 057 * @param addressId the primary key of the address to delete 058 * @throws PortalException if a address with the primary key could not be found 059 * @throws SystemException if a system exception occurred 060 */ 061 public void deleteAddress(long addressId) 062 throws com.liferay.portal.kernel.exception.PortalException, 063 com.liferay.portal.kernel.exception.SystemException { 064 _addressLocalService.deleteAddress(addressId); 065 } 066 067 /** 068 * Deletes the address from the database. Also notifies the appropriate model listeners. 069 * 070 * @param address the address to delete 071 * @throws SystemException if a system exception occurred 072 */ 073 public void deleteAddress(com.liferay.portal.model.Address address) 074 throws com.liferay.portal.kernel.exception.SystemException { 075 _addressLocalService.deleteAddress(address); 076 } 077 078 /** 079 * Performs a dynamic query on the database and returns the matching rows. 080 * 081 * @param dynamicQuery the dynamic query to search with 082 * @return the matching rows 083 * @throws SystemException if a system exception occurred 084 */ 085 @SuppressWarnings("rawtypes") 086 public java.util.List dynamicQuery( 087 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery) 088 throws com.liferay.portal.kernel.exception.SystemException { 089 return _addressLocalService.dynamicQuery(dynamicQuery); 090 } 091 092 /** 093 * Performs a dynamic query on the database and returns a range of the matching rows. 094 * 095 * <p> 096 * 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. 097 * </p> 098 * 099 * @param dynamicQuery the dynamic query to search with 100 * @param start the lower bound of the range of model instances to return 101 * @param end the upper bound of the range of model instances to return (not inclusive) 102 * @return the range of matching rows 103 * @throws SystemException if a system exception occurred 104 */ 105 @SuppressWarnings("rawtypes") 106 public java.util.List dynamicQuery( 107 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start, 108 int end) throws com.liferay.portal.kernel.exception.SystemException { 109 return _addressLocalService.dynamicQuery(dynamicQuery, start, end); 110 } 111 112 /** 113 * Performs a dynamic query on the database and returns an ordered range of the matching rows. 114 * 115 * <p> 116 * 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. 117 * </p> 118 * 119 * @param dynamicQuery the dynamic query to search with 120 * @param start the lower bound of the range of model instances to return 121 * @param end the upper bound of the range of model instances to return (not inclusive) 122 * @param orderByComparator the comparator to order the results by 123 * @return the ordered range of matching rows 124 * @throws SystemException if a system exception occurred 125 */ 126 @SuppressWarnings("rawtypes") 127 public java.util.List dynamicQuery( 128 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start, 129 int end, 130 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 131 throws com.liferay.portal.kernel.exception.SystemException { 132 return _addressLocalService.dynamicQuery(dynamicQuery, start, end, 133 orderByComparator); 134 } 135 136 /** 137 * Counts the number of rows that match the dynamic query. 138 * 139 * @param dynamicQuery the dynamic query to search with 140 * @return the number of rows that match the dynamic query 141 * @throws SystemException if a system exception occurred 142 */ 143 public long dynamicQueryCount( 144 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery) 145 throws com.liferay.portal.kernel.exception.SystemException { 146 return _addressLocalService.dynamicQueryCount(dynamicQuery); 147 } 148 149 /** 150 * Gets the address with the primary key. 151 * 152 * @param addressId the primary key of the address to get 153 * @return the address 154 * @throws PortalException if a address with the primary key could not be found 155 * @throws SystemException if a system exception occurred 156 */ 157 public com.liferay.portal.model.Address getAddress(long addressId) 158 throws com.liferay.portal.kernel.exception.PortalException, 159 com.liferay.portal.kernel.exception.SystemException { 160 return _addressLocalService.getAddress(addressId); 161 } 162 163 /** 164 * Gets a range of all the addresses. 165 * 166 * <p> 167 * 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. 168 * </p> 169 * 170 * @param start the lower bound of the range of addresses to return 171 * @param end the upper bound of the range of addresses to return (not inclusive) 172 * @return the range of addresses 173 * @throws SystemException if a system exception occurred 174 */ 175 public java.util.List<com.liferay.portal.model.Address> getAddresses( 176 int start, int end) 177 throws com.liferay.portal.kernel.exception.SystemException { 178 return _addressLocalService.getAddresses(start, end); 179 } 180 181 /** 182 * Gets the number of addresses. 183 * 184 * @return the number of addresses 185 * @throws SystemException if a system exception occurred 186 */ 187 public int getAddressesCount() 188 throws com.liferay.portal.kernel.exception.SystemException { 189 return _addressLocalService.getAddressesCount(); 190 } 191 192 /** 193 * Updates the address in the database. Also notifies the appropriate model listeners. 194 * 195 * @param address the address to update 196 * @return the address that was updated 197 * @throws SystemException if a system exception occurred 198 */ 199 public com.liferay.portal.model.Address updateAddress( 200 com.liferay.portal.model.Address address) 201 throws com.liferay.portal.kernel.exception.SystemException { 202 return _addressLocalService.updateAddress(address); 203 } 204 205 /** 206 * Updates the address in the database. Also notifies the appropriate model listeners. 207 * 208 * @param address the address to update 209 * @param merge whether to merge the address 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. 210 * @return the address that was updated 211 * @throws SystemException if a system exception occurred 212 */ 213 public com.liferay.portal.model.Address updateAddress( 214 com.liferay.portal.model.Address address, boolean merge) 215 throws com.liferay.portal.kernel.exception.SystemException { 216 return _addressLocalService.updateAddress(address, merge); 217 } 218 219 public com.liferay.portal.model.Address addAddress(long userId, 220 java.lang.String className, long classPK, java.lang.String street1, 221 java.lang.String street2, java.lang.String street3, 222 java.lang.String city, java.lang.String zip, long regionId, 223 long countryId, int typeId, boolean mailing, boolean primary) 224 throws com.liferay.portal.kernel.exception.PortalException, 225 com.liferay.portal.kernel.exception.SystemException { 226 return _addressLocalService.addAddress(userId, className, classPK, 227 street1, street2, street3, city, zip, regionId, countryId, typeId, 228 mailing, primary); 229 } 230 231 public void deleteAddresses(long companyId, java.lang.String className, 232 long classPK) 233 throws com.liferay.portal.kernel.exception.SystemException { 234 _addressLocalService.deleteAddresses(companyId, className, classPK); 235 } 236 237 public java.util.List<com.liferay.portal.model.Address> getAddresses() 238 throws com.liferay.portal.kernel.exception.SystemException { 239 return _addressLocalService.getAddresses(); 240 } 241 242 public java.util.List<com.liferay.portal.model.Address> getAddresses( 243 long companyId, java.lang.String className, long classPK) 244 throws com.liferay.portal.kernel.exception.SystemException { 245 return _addressLocalService.getAddresses(companyId, className, classPK); 246 } 247 248 public com.liferay.portal.model.Address updateAddress(long addressId, 249 java.lang.String street1, java.lang.String street2, 250 java.lang.String street3, java.lang.String city, java.lang.String zip, 251 long regionId, long countryId, int typeId, boolean mailing, 252 boolean primary) 253 throws com.liferay.portal.kernel.exception.PortalException, 254 com.liferay.portal.kernel.exception.SystemException { 255 return _addressLocalService.updateAddress(addressId, street1, street2, 256 street3, city, zip, regionId, countryId, typeId, mailing, primary); 257 } 258 259 public AddressLocalService getWrappedAddressLocalService() { 260 return _addressLocalService; 261 } 262 263 private AddressLocalService _addressLocalService; 264 }