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.portlet.shopping.service.persistence; 016 017 import aQute.bnd.annotation.ProviderType; 018 019 import com.liferay.portal.service.persistence.BasePersistence; 020 021 import com.liferay.portlet.shopping.model.ShoppingItemPrice; 022 023 /** 024 * The persistence interface for the shopping item price service. 025 * 026 * <p> 027 * Caching information and settings can be found in <code>portal.properties</code> 028 * </p> 029 * 030 * @author Brian Wing Shun Chan 031 * @see ShoppingItemPricePersistenceImpl 032 * @see ShoppingItemPriceUtil 033 * @generated 034 */ 035 @ProviderType 036 public interface ShoppingItemPricePersistence extends BasePersistence<ShoppingItemPrice> { 037 /* 038 * NOTE FOR DEVELOPERS: 039 * 040 * Never modify or reference this interface directly. Always use {@link ShoppingItemPriceUtil} to access the shopping item price persistence. Modify <code>service.xml</code> and rerun ServiceBuilder to regenerate this interface. 041 */ 042 043 /** 044 * Returns all the shopping item prices where itemId = ?. 045 * 046 * @param itemId the item ID 047 * @return the matching shopping item prices 048 * @throws SystemException if a system exception occurred 049 */ 050 public java.util.List<com.liferay.portlet.shopping.model.ShoppingItemPrice> findByItemId( 051 long itemId) throws com.liferay.portal.kernel.exception.SystemException; 052 053 /** 054 * Returns a range of all the shopping item prices where itemId = ?. 055 * 056 * <p> 057 * 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.ShoppingItemPriceModelImpl}. 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. 058 * </p> 059 * 060 * @param itemId the item ID 061 * @param start the lower bound of the range of shopping item prices 062 * @param end the upper bound of the range of shopping item prices (not inclusive) 063 * @return the range of matching shopping item prices 064 * @throws SystemException if a system exception occurred 065 */ 066 public java.util.List<com.liferay.portlet.shopping.model.ShoppingItemPrice> findByItemId( 067 long itemId, int start, int end) 068 throws com.liferay.portal.kernel.exception.SystemException; 069 070 /** 071 * Returns an ordered range of all the shopping item prices where itemId = ?. 072 * 073 * <p> 074 * 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.ShoppingItemPriceModelImpl}. 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. 075 * </p> 076 * 077 * @param itemId the item ID 078 * @param start the lower bound of the range of shopping item prices 079 * @param end the upper bound of the range of shopping item prices (not inclusive) 080 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 081 * @return the ordered range of matching shopping item prices 082 * @throws SystemException if a system exception occurred 083 */ 084 public java.util.List<com.liferay.portlet.shopping.model.ShoppingItemPrice> findByItemId( 085 long itemId, int start, int end, 086 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 087 throws com.liferay.portal.kernel.exception.SystemException; 088 089 /** 090 * Returns the first shopping item price in the ordered set where itemId = ?. 091 * 092 * @param itemId the item ID 093 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 094 * @return the first matching shopping item price 095 * @throws com.liferay.portlet.shopping.NoSuchItemPriceException if a matching shopping item price could not be found 096 * @throws SystemException if a system exception occurred 097 */ 098 public com.liferay.portlet.shopping.model.ShoppingItemPrice findByItemId_First( 099 long itemId, 100 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 101 throws com.liferay.portal.kernel.exception.SystemException, 102 com.liferay.portlet.shopping.NoSuchItemPriceException; 103 104 /** 105 * Returns the first shopping item price in the ordered set where itemId = ?. 106 * 107 * @param itemId the item ID 108 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 109 * @return the first matching shopping item price, or <code>null</code> if a matching shopping item price could not be found 110 * @throws SystemException if a system exception occurred 111 */ 112 public com.liferay.portlet.shopping.model.ShoppingItemPrice fetchByItemId_First( 113 long itemId, 114 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 115 throws com.liferay.portal.kernel.exception.SystemException; 116 117 /** 118 * Returns the last shopping item price in the ordered set where itemId = ?. 119 * 120 * @param itemId the item ID 121 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 122 * @return the last matching shopping item price 123 * @throws com.liferay.portlet.shopping.NoSuchItemPriceException if a matching shopping item price could not be found 124 * @throws SystemException if a system exception occurred 125 */ 126 public com.liferay.portlet.shopping.model.ShoppingItemPrice findByItemId_Last( 127 long itemId, 128 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 129 throws com.liferay.portal.kernel.exception.SystemException, 130 com.liferay.portlet.shopping.NoSuchItemPriceException; 131 132 /** 133 * Returns the last shopping item price in the ordered set where itemId = ?. 134 * 135 * @param itemId the item ID 136 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 137 * @return the last matching shopping item price, or <code>null</code> if a matching shopping item price could not be found 138 * @throws SystemException if a system exception occurred 139 */ 140 public com.liferay.portlet.shopping.model.ShoppingItemPrice fetchByItemId_Last( 141 long itemId, 142 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 143 throws com.liferay.portal.kernel.exception.SystemException; 144 145 /** 146 * Returns the shopping item prices before and after the current shopping item price in the ordered set where itemId = ?. 147 * 148 * @param itemPriceId the primary key of the current shopping item price 149 * @param itemId the item ID 150 * @param orderByComparator the comparator to order the set by (optionally <code>null</code>) 151 * @return the previous, current, and next shopping item price 152 * @throws com.liferay.portlet.shopping.NoSuchItemPriceException if a shopping item price with the primary key could not be found 153 * @throws SystemException if a system exception occurred 154 */ 155 public com.liferay.portlet.shopping.model.ShoppingItemPrice[] findByItemId_PrevAndNext( 156 long itemPriceId, long itemId, 157 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 158 throws com.liferay.portal.kernel.exception.SystemException, 159 com.liferay.portlet.shopping.NoSuchItemPriceException; 160 161 /** 162 * Removes all the shopping item prices where itemId = ? from the database. 163 * 164 * @param itemId the item ID 165 * @throws SystemException if a system exception occurred 166 */ 167 public void removeByItemId(long itemId) 168 throws com.liferay.portal.kernel.exception.SystemException; 169 170 /** 171 * Returns the number of shopping item prices where itemId = ?. 172 * 173 * @param itemId the item ID 174 * @return the number of matching shopping item prices 175 * @throws SystemException if a system exception occurred 176 */ 177 public int countByItemId(long itemId) 178 throws com.liferay.portal.kernel.exception.SystemException; 179 180 /** 181 * Caches the shopping item price in the entity cache if it is enabled. 182 * 183 * @param shoppingItemPrice the shopping item price 184 */ 185 public void cacheResult( 186 com.liferay.portlet.shopping.model.ShoppingItemPrice shoppingItemPrice); 187 188 /** 189 * Caches the shopping item prices in the entity cache if it is enabled. 190 * 191 * @param shoppingItemPrices the shopping item prices 192 */ 193 public void cacheResult( 194 java.util.List<com.liferay.portlet.shopping.model.ShoppingItemPrice> shoppingItemPrices); 195 196 /** 197 * Creates a new shopping item price with the primary key. Does not add the shopping item price to the database. 198 * 199 * @param itemPriceId the primary key for the new shopping item price 200 * @return the new shopping item price 201 */ 202 public com.liferay.portlet.shopping.model.ShoppingItemPrice create( 203 long itemPriceId); 204 205 /** 206 * Removes the shopping item price with the primary key from the database. Also notifies the appropriate model listeners. 207 * 208 * @param itemPriceId the primary key of the shopping item price 209 * @return the shopping item price that was removed 210 * @throws com.liferay.portlet.shopping.NoSuchItemPriceException if a shopping item price with the primary key could not be found 211 * @throws SystemException if a system exception occurred 212 */ 213 public com.liferay.portlet.shopping.model.ShoppingItemPrice remove( 214 long itemPriceId) 215 throws com.liferay.portal.kernel.exception.SystemException, 216 com.liferay.portlet.shopping.NoSuchItemPriceException; 217 218 public com.liferay.portlet.shopping.model.ShoppingItemPrice updateImpl( 219 com.liferay.portlet.shopping.model.ShoppingItemPrice shoppingItemPrice) 220 throws com.liferay.portal.kernel.exception.SystemException; 221 222 /** 223 * Returns the shopping item price with the primary key or throws a {@link com.liferay.portlet.shopping.NoSuchItemPriceException} if it could not be found. 224 * 225 * @param itemPriceId the primary key of the shopping item price 226 * @return the shopping item price 227 * @throws com.liferay.portlet.shopping.NoSuchItemPriceException if a shopping item price with the primary key could not be found 228 * @throws SystemException if a system exception occurred 229 */ 230 public com.liferay.portlet.shopping.model.ShoppingItemPrice findByPrimaryKey( 231 long itemPriceId) 232 throws com.liferay.portal.kernel.exception.SystemException, 233 com.liferay.portlet.shopping.NoSuchItemPriceException; 234 235 /** 236 * Returns the shopping item price with the primary key or returns <code>null</code> if it could not be found. 237 * 238 * @param itemPriceId the primary key of the shopping item price 239 * @return the shopping item price, or <code>null</code> if a shopping item price with the primary key could not be found 240 * @throws SystemException if a system exception occurred 241 */ 242 public com.liferay.portlet.shopping.model.ShoppingItemPrice fetchByPrimaryKey( 243 long itemPriceId) 244 throws com.liferay.portal.kernel.exception.SystemException; 245 246 /** 247 * Returns all the shopping item prices. 248 * 249 * @return the shopping item prices 250 * @throws SystemException if a system exception occurred 251 */ 252 public java.util.List<com.liferay.portlet.shopping.model.ShoppingItemPrice> findAll() 253 throws com.liferay.portal.kernel.exception.SystemException; 254 255 /** 256 * Returns a range of all the shopping item prices. 257 * 258 * <p> 259 * 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.ShoppingItemPriceModelImpl}. 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. 260 * </p> 261 * 262 * @param start the lower bound of the range of shopping item prices 263 * @param end the upper bound of the range of shopping item prices (not inclusive) 264 * @return the range of shopping item prices 265 * @throws SystemException if a system exception occurred 266 */ 267 public java.util.List<com.liferay.portlet.shopping.model.ShoppingItemPrice> findAll( 268 int start, int end) 269 throws com.liferay.portal.kernel.exception.SystemException; 270 271 /** 272 * Returns an ordered range of all the shopping item prices. 273 * 274 * <p> 275 * 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.ShoppingItemPriceModelImpl}. 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. 276 * </p> 277 * 278 * @param start the lower bound of the range of shopping item prices 279 * @param end the upper bound of the range of shopping item prices (not inclusive) 280 * @param orderByComparator the comparator to order the results by (optionally <code>null</code>) 281 * @return the ordered range of shopping item prices 282 * @throws SystemException if a system exception occurred 283 */ 284 public java.util.List<com.liferay.portlet.shopping.model.ShoppingItemPrice> findAll( 285 int start, int end, 286 com.liferay.portal.kernel.util.OrderByComparator orderByComparator) 287 throws com.liferay.portal.kernel.exception.SystemException; 288 289 /** 290 * Removes all the shopping item prices from the database. 291 * 292 * @throws SystemException if a system exception occurred 293 */ 294 public void removeAll() 295 throws com.liferay.portal.kernel.exception.SystemException; 296 297 /** 298 * Returns the number of shopping item prices. 299 * 300 * @return the number of shopping item prices 301 * @throws SystemException if a system exception occurred 302 */ 303 public int countAll() 304 throws com.liferay.portal.kernel.exception.SystemException; 305 }