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.portlet.shopping.service; 016 017 import aQute.bnd.annotation.ProviderType; 018 019 import com.liferay.portal.service.ServiceWrapper; 020 021 /** 022 * Provides a wrapper for {@link ShoppingCartLocalService}. 023 * 024 * @author Brian Wing Shun Chan 025 * @see ShoppingCartLocalService 026 * @generated 027 */ 028 @ProviderType 029 public class ShoppingCartLocalServiceWrapper implements ShoppingCartLocalService, 030 ServiceWrapper<ShoppingCartLocalService> { 031 public ShoppingCartLocalServiceWrapper( 032 ShoppingCartLocalService shoppingCartLocalService) { 033 _shoppingCartLocalService = shoppingCartLocalService; 034 } 035 036 /** 037 * Adds the shopping cart to the database. Also notifies the appropriate model listeners. 038 * 039 * @param shoppingCart the shopping cart 040 * @return the shopping cart that was added 041 */ 042 @Override 043 public com.liferay.portlet.shopping.model.ShoppingCart addShoppingCart( 044 com.liferay.portlet.shopping.model.ShoppingCart shoppingCart) { 045 return _shoppingCartLocalService.addShoppingCart(shoppingCart); 046 } 047 048 /** 049 * Creates a new shopping cart with the primary key. Does not add the shopping cart to the database. 050 * 051 * @param cartId the primary key for the new shopping cart 052 * @return the new shopping cart 053 */ 054 @Override 055 public com.liferay.portlet.shopping.model.ShoppingCart createShoppingCart( 056 long cartId) { 057 return _shoppingCartLocalService.createShoppingCart(cartId); 058 } 059 060 @Override 061 public void deleteGroupCarts(long groupId) { 062 _shoppingCartLocalService.deleteGroupCarts(groupId); 063 } 064 065 /** 066 * @throws PortalException 067 */ 068 @Override 069 public com.liferay.portal.model.PersistedModel deletePersistedModel( 070 com.liferay.portal.model.PersistedModel persistedModel) 071 throws com.liferay.portal.kernel.exception.PortalException { 072 return _shoppingCartLocalService.deletePersistedModel(persistedModel); 073 } 074 075 /** 076 * Deletes the shopping cart with the primary key from the database. Also notifies the appropriate model listeners. 077 * 078 * @param cartId the primary key of the shopping cart 079 * @return the shopping cart that was removed 080 * @throws PortalException if a shopping cart with the primary key could not be found 081 */ 082 @Override 083 public com.liferay.portlet.shopping.model.ShoppingCart deleteShoppingCart( 084 long cartId) throws com.liferay.portal.kernel.exception.PortalException { 085 return _shoppingCartLocalService.deleteShoppingCart(cartId); 086 } 087 088 /** 089 * Deletes the shopping cart from the database. Also notifies the appropriate model listeners. 090 * 091 * @param shoppingCart the shopping cart 092 * @return the shopping cart that was removed 093 */ 094 @Override 095 public com.liferay.portlet.shopping.model.ShoppingCart deleteShoppingCart( 096 com.liferay.portlet.shopping.model.ShoppingCart shoppingCart) { 097 return _shoppingCartLocalService.deleteShoppingCart(shoppingCart); 098 } 099 100 @Override 101 public void deleteUserCarts(long userId) { 102 _shoppingCartLocalService.deleteUserCarts(userId); 103 } 104 105 @Override 106 public com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery() { 107 return _shoppingCartLocalService.dynamicQuery(); 108 } 109 110 /** 111 * Performs a dynamic query on the database and returns the matching rows. 112 * 113 * @param dynamicQuery the dynamic query 114 * @return the matching rows 115 */ 116 @Override 117 public <T> java.util.List<T> dynamicQuery( 118 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery) { 119 return _shoppingCartLocalService.dynamicQuery(dynamicQuery); 120 } 121 122 /** 123 * Performs a dynamic query on the database and returns a range of the matching rows. 124 * 125 * <p> 126 * 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.portlet.shopping.model.impl.ShoppingCartModelImpl}. 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. 127 * </p> 128 * 129 * @param dynamicQuery the dynamic query 130 * @param start the lower bound of the range of model instances 131 * @param end the upper bound of the range of model instances (not inclusive) 132 * @return the range of matching rows 133 */ 134 @Override 135 public <T> java.util.List<T> dynamicQuery( 136 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start, 137 int end) { 138 return _shoppingCartLocalService.dynamicQuery(dynamicQuery, start, end); 139 } 140 141 /** 142 * Performs a dynamic query on the database and returns an ordered range of the matching rows. 143 * 144 * <p> 145 * 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.portlet.shopping.model.impl.ShoppingCartModelImpl}. 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. 146 * </p> 147 * 148 * @param dynamicQuery the dynamic query 149 * @param start the lower bound of the range of model instances 150 * @param end the upper bound of the range of model instances (not inclusive) 151 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 152 * @return the ordered range of matching rows 153 */ 154 @Override 155 public <T> java.util.List<T> dynamicQuery( 156 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, int start, 157 int end, 158 com.liferay.portal.kernel.util.OrderByComparator<T> orderByComparator) { 159 return _shoppingCartLocalService.dynamicQuery(dynamicQuery, start, end, 160 orderByComparator); 161 } 162 163 /** 164 * Returns the number of rows matching the dynamic query. 165 * 166 * @param dynamicQuery the dynamic query 167 * @return the number of rows matching the dynamic query 168 */ 169 @Override 170 public long dynamicQueryCount( 171 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery) { 172 return _shoppingCartLocalService.dynamicQueryCount(dynamicQuery); 173 } 174 175 /** 176 * Returns the number of rows matching the dynamic query. 177 * 178 * @param dynamicQuery the dynamic query 179 * @param projection the projection to apply to the query 180 * @return the number of rows matching the dynamic query 181 */ 182 @Override 183 public long dynamicQueryCount( 184 com.liferay.portal.kernel.dao.orm.DynamicQuery dynamicQuery, 185 com.liferay.portal.kernel.dao.orm.Projection projection) { 186 return _shoppingCartLocalService.dynamicQueryCount(dynamicQuery, 187 projection); 188 } 189 190 @Override 191 public com.liferay.portlet.shopping.model.ShoppingCart fetchShoppingCart( 192 long cartId) { 193 return _shoppingCartLocalService.fetchShoppingCart(cartId); 194 } 195 196 @Override 197 public com.liferay.portal.kernel.dao.orm.ActionableDynamicQuery getActionableDynamicQuery() { 198 return _shoppingCartLocalService.getActionableDynamicQuery(); 199 } 200 201 /** 202 * Returns the Spring bean ID for this bean. 203 * 204 * @return the Spring bean ID for this bean 205 */ 206 @Override 207 public java.lang.String getBeanIdentifier() { 208 return _shoppingCartLocalService.getBeanIdentifier(); 209 } 210 211 @Override 212 public com.liferay.portlet.shopping.model.ShoppingCart getCart( 213 long userId, long groupId) 214 throws com.liferay.portal.kernel.exception.PortalException { 215 return _shoppingCartLocalService.getCart(userId, groupId); 216 } 217 218 @Override 219 public java.util.Map<com.liferay.portlet.shopping.model.ShoppingCartItem, java.lang.Integer> getItems( 220 long groupId, java.lang.String itemIds) { 221 return _shoppingCartLocalService.getItems(groupId, itemIds); 222 } 223 224 @Override 225 public com.liferay.portal.model.PersistedModel getPersistedModel( 226 java.io.Serializable primaryKeyObj) 227 throws com.liferay.portal.kernel.exception.PortalException { 228 return _shoppingCartLocalService.getPersistedModel(primaryKeyObj); 229 } 230 231 /** 232 * Returns the shopping cart with the primary key. 233 * 234 * @param cartId the primary key of the shopping cart 235 * @return the shopping cart 236 * @throws PortalException if a shopping cart with the primary key could not be found 237 */ 238 @Override 239 public com.liferay.portlet.shopping.model.ShoppingCart getShoppingCart( 240 long cartId) throws com.liferay.portal.kernel.exception.PortalException { 241 return _shoppingCartLocalService.getShoppingCart(cartId); 242 } 243 244 /** 245 * Returns a range of all the shopping carts. 246 * 247 * <p> 248 * 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.portlet.shopping.model.impl.ShoppingCartModelImpl}. 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. 249 * </p> 250 * 251 * @param start the lower bound of the range of shopping carts 252 * @param end the upper bound of the range of shopping carts (not inclusive) 253 * @return the range of shopping carts 254 */ 255 @Override 256 public java.util.List<com.liferay.portlet.shopping.model.ShoppingCart> getShoppingCarts( 257 int start, int end) { 258 return _shoppingCartLocalService.getShoppingCarts(start, end); 259 } 260 261 /** 262 * Returns the number of shopping carts. 263 * 264 * @return the number of shopping carts 265 */ 266 @Override 267 public int getShoppingCartsCount() { 268 return _shoppingCartLocalService.getShoppingCartsCount(); 269 } 270 271 /** 272 * Sets the Spring bean ID for this bean. 273 * 274 * @param beanIdentifier the Spring bean ID for this bean 275 */ 276 @Override 277 public void setBeanIdentifier(java.lang.String beanIdentifier) { 278 _shoppingCartLocalService.setBeanIdentifier(beanIdentifier); 279 } 280 281 @Override 282 public com.liferay.portlet.shopping.model.ShoppingCart updateCart( 283 long userId, long groupId, java.lang.String itemIds, 284 java.lang.String couponCodes, int altShipping, boolean insure) 285 throws com.liferay.portal.kernel.exception.PortalException { 286 return _shoppingCartLocalService.updateCart(userId, groupId, itemIds, 287 couponCodes, altShipping, insure); 288 } 289 290 /** 291 * Updates the shopping cart in the database or adds it if it does not yet exist. Also notifies the appropriate model listeners. 292 * 293 * @param shoppingCart the shopping cart 294 * @return the shopping cart that was updated 295 */ 296 @Override 297 public com.liferay.portlet.shopping.model.ShoppingCart updateShoppingCart( 298 com.liferay.portlet.shopping.model.ShoppingCart shoppingCart) { 299 return _shoppingCartLocalService.updateShoppingCart(shoppingCart); 300 } 301 302 /** 303 * @deprecated As of 6.1.0, replaced by {@link #getWrappedService} 304 */ 305 @Deprecated 306 public ShoppingCartLocalService getWrappedShoppingCartLocalService() { 307 return _shoppingCartLocalService; 308 } 309 310 /** 311 * @deprecated As of 6.1.0, replaced by {@link #setWrappedService} 312 */ 313 @Deprecated 314 public void setWrappedShoppingCartLocalService( 315 ShoppingCartLocalService shoppingCartLocalService) { 316 _shoppingCartLocalService = shoppingCartLocalService; 317 } 318 319 @Override 320 public ShoppingCartLocalService getWrappedService() { 321 return _shoppingCartLocalService; 322 } 323 324 @Override 325 public void setWrappedService( 326 ShoppingCartLocalService shoppingCartLocalService) { 327 _shoppingCartLocalService = shoppingCartLocalService; 328 } 329 330 private ShoppingCartLocalService _shoppingCartLocalService; 331 }