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