Liferay 6.0.5

com.liferay.portlet.shopping.service.persistence
Class ShoppingItemPersistenceImpl

java.lang.Object
  extended by com.liferay.portal.service.persistence.impl.BasePersistenceImpl<ShoppingItem>
      extended by com.liferay.portlet.shopping.service.persistence.ShoppingItemPersistenceImpl
All Implemented Interfaces:
SessionFactory, BasePersistence<ShoppingItem>, ShoppingItemPersistence

public class ShoppingItemPersistenceImpl
extends BasePersistenceImpl<ShoppingItem>
implements ShoppingItemPersistence

The persistence implementation for the shopping item service.

Never modify or reference this class directly. Always use ShoppingItemUtil to access the shopping item persistence. Modify service.xml and rerun ServiceBuilder to regenerate this class.

Caching information and settings can be found in portal.properties

See Also:
ShoppingItemPersistence, ShoppingItemUtil
ServiceBuilder generated this class. Modifications in this class will be overwritten the next time is generated.

Nested Class Summary
protected  class ShoppingItemPersistenceImpl.ContainsShoppingItemPrice
           
 
Field Summary
protected  ShoppingItemPersistenceImpl.ContainsShoppingItemPrice containsShoppingItemPrice
           
static String FINDER_CLASS_NAME_ENTITY
           
static String FINDER_CLASS_NAME_LIST
           
static FinderPath FINDER_PATH_CONTAINS_SHOPPINGITEMPRICE
           
static FinderPath FINDER_PATH_COUNT_ALL
           
static FinderPath FINDER_PATH_COUNT_BY_C_S
           
static FinderPath FINDER_PATH_COUNT_BY_G_C
           
static FinderPath FINDER_PATH_COUNT_BY_LARGEIMAGEID
           
static FinderPath FINDER_PATH_COUNT_BY_MEDIUMIMAGEID
           
static FinderPath FINDER_PATH_COUNT_BY_SMALLIMAGEID
           
static FinderPath FINDER_PATH_FETCH_BY_C_S
           
static FinderPath FINDER_PATH_FETCH_BY_LARGEIMAGEID
           
static FinderPath FINDER_PATH_FETCH_BY_MEDIUMIMAGEID
           
static FinderPath FINDER_PATH_FETCH_BY_SMALLIMAGEID
           
static FinderPath FINDER_PATH_FIND_ALL
           
static FinderPath FINDER_PATH_FIND_BY_G_C
           
static FinderPath FINDER_PATH_GET_SHOPPINGITEMPRICES
           
static FinderPath FINDER_PATH_GET_SHOPPINGITEMPRICES_SIZE
           
protected  ImagePersistence imagePersistence
           
protected  ResourcePersistence resourcePersistence
           
protected  ShoppingCartPersistence shoppingCartPersistence
           
protected  ShoppingCategoryPersistence shoppingCategoryPersistence
           
protected  ShoppingCouponPersistence shoppingCouponPersistence
           
protected  ShoppingItemFieldPersistence shoppingItemFieldPersistence
           
protected  ShoppingItemPersistence shoppingItemPersistence
           
protected  ShoppingItemPricePersistence shoppingItemPricePersistence
           
protected  ShoppingOrderItemPersistence shoppingOrderItemPersistence
           
protected  ShoppingOrderPersistence shoppingOrderPersistence
           
protected  UserPersistence userPersistence
           
 
Fields inherited from class com.liferay.portal.service.persistence.impl.BasePersistenceImpl
COUNT_COLUMN_NAME, listeners, ORDER_BY_ASC, ORDER_BY_ASC_HAS_NEXT, ORDER_BY_CLAUSE, ORDER_BY_DESC, ORDER_BY_DESC_HAS_NEXT, WHERE_AND, WHERE_GREATER_THAN, WHERE_GREATER_THAN_HAS_NEXT, WHERE_LESSER_THAN, WHERE_LESSER_THAN_HAS_NEXT, WHERE_OR
 
Constructor Summary
ShoppingItemPersistenceImpl()
           
 
Method Summary
 void afterPropertiesSet()
          Initializes the shopping item persistence.
 void cacheResult(List<ShoppingItem> shoppingItems)
          Caches the shopping items in the entity cache if it is enabled.
 void cacheResult(ShoppingItem shoppingItem)
          Caches the shopping item in the entity cache if it is enabled.
 void clearCache()
          Clears the cache for all shopping items.
 void clearCache(ShoppingItem shoppingItem)
          Clears the cache for the shopping item.
 boolean containsShoppingItemPrice(long pk, long shoppingItemPricePK)
          Determines whether the shopping item price is associated with the shopping item.
 boolean containsShoppingItemPrices(long pk)
          Determines whether the shopping item has any shopping item prices associated with it.
 int countAll()
          Counts all the shopping items.
 int countByC_S(long companyId, String sku)
          Counts all the shopping items where companyId = ? and sku = ?.
 int countByG_C(long groupId, long categoryId)
          Counts all the shopping items where groupId = ? and categoryId = ?.
 int countByLargeImageId(long largeImageId)
          Counts all the shopping items where largeImageId = ?.
 int countByMediumImageId(long mediumImageId)
          Counts all the shopping items where mediumImageId = ?.
 int countBySmallImageId(long smallImageId)
          Counts all the shopping items where smallImageId = ?.
 ShoppingItem create(long itemId)
          Creates a new shopping item with the primary key.
 ShoppingItem fetchByC_S(long companyId, String sku)
          Finds the shopping item where companyId = ? and sku = ? or returns null if it could not be found.
 ShoppingItem fetchByC_S(long companyId, String sku, boolean retrieveFromCache)
          Finds the shopping item where companyId = ? and sku = ? or returns null if it could not be found, optionally using the finder cache.
 ShoppingItem fetchByLargeImageId(long largeImageId)
          Finds the shopping item where largeImageId = ? or returns null if it could not be found.
 ShoppingItem fetchByLargeImageId(long largeImageId, boolean retrieveFromCache)
          Finds the shopping item where largeImageId = ? or returns null if it could not be found, optionally using the finder cache.
 ShoppingItem fetchByMediumImageId(long mediumImageId)
          Finds the shopping item where mediumImageId = ? or returns null if it could not be found.
 ShoppingItem fetchByMediumImageId(long mediumImageId, boolean retrieveFromCache)
          Finds the shopping item where mediumImageId = ? or returns null if it could not be found, optionally using the finder cache.
 ShoppingItem fetchByPrimaryKey(long itemId)
          Finds the shopping item with the primary key or returns null if it could not be found.
 ShoppingItem fetchByPrimaryKey(Serializable primaryKey)
          Finds the shopping item with the primary key or returns null if it could not be found.
 ShoppingItem fetchBySmallImageId(long smallImageId)
          Finds the shopping item where smallImageId = ? or returns null if it could not be found.
 ShoppingItem fetchBySmallImageId(long smallImageId, boolean retrieveFromCache)
          Finds the shopping item where smallImageId = ? or returns null if it could not be found, optionally using the finder cache.
 int filterCountByG_C(long groupId, long categoryId)
          Filters by the user's permissions and counts all the shopping items where groupId = ? and categoryId = ?.
 List<ShoppingItem> filterFindByG_C(long groupId, long categoryId)
          Filters by the user's permissions and finds all the shopping items where groupId = ? and categoryId = ?.
 List<ShoppingItem> filterFindByG_C(long groupId, long categoryId, int start, int end)
          Filters by the user's permissions and finds a range of all the shopping items where groupId = ? and categoryId = ?.
 List<ShoppingItem> filterFindByG_C(long groupId, long categoryId, int start, int end, OrderByComparator orderByComparator)
          Filters by the user's permissions and finds an ordered range of all the shopping items where groupId = ? and categoryId = ?.
 List<ShoppingItem> findAll()
          Finds all the shopping items.
 List<ShoppingItem> findAll(int start, int end)
          Finds a range of all the shopping items.
 List<ShoppingItem> findAll(int start, int end, OrderByComparator orderByComparator)
          Finds an ordered range of all the shopping items.
 ShoppingItem findByC_S(long companyId, String sku)
          Finds the shopping item where companyId = ? and sku = ? or throws a NoSuchItemException if it could not be found.
 ShoppingItem findByG_C_First(long groupId, long categoryId, OrderByComparator orderByComparator)
          Finds the first shopping item in the ordered set where groupId = ? and categoryId = ?.
 ShoppingItem findByG_C_Last(long groupId, long categoryId, OrderByComparator orderByComparator)
          Finds the last shopping item in the ordered set where groupId = ? and categoryId = ?.
 ShoppingItem[] findByG_C_PrevAndNext(long itemId, long groupId, long categoryId, OrderByComparator orderByComparator)
          Finds the shopping items before and after the current shopping item in the ordered set where groupId = ? and categoryId = ?.
 List<ShoppingItem> findByG_C(long groupId, long categoryId)
          Finds all the shopping items where groupId = ? and categoryId = ?.
 List<ShoppingItem> findByG_C(long groupId, long categoryId, int start, int end)
          Finds a range of all the shopping items where groupId = ? and categoryId = ?.
 List<ShoppingItem> findByG_C(long groupId, long categoryId, int start, int end, OrderByComparator orderByComparator)
          Finds an ordered range of all the shopping items where groupId = ? and categoryId = ?.
 ShoppingItem findByLargeImageId(long largeImageId)
          Finds the shopping item where largeImageId = ? or throws a NoSuchItemException if it could not be found.
 ShoppingItem findByMediumImageId(long mediumImageId)
          Finds the shopping item where mediumImageId = ? or throws a NoSuchItemException if it could not be found.
 ShoppingItem findByPrimaryKey(long itemId)
          Finds the shopping item with the primary key or throws a NoSuchItemException if it could not be found.
 ShoppingItem findByPrimaryKey(Serializable primaryKey)
          Finds the shopping item with the primary key or throws a NoSuchModelException if it could not be found.
 ShoppingItem findBySmallImageId(long smallImageId)
          Finds the shopping item where smallImageId = ? or throws a NoSuchItemException if it could not be found.
protected  ShoppingItem getByG_C_PrevAndNext(Session session, ShoppingItem shoppingItem, long groupId, long categoryId, OrderByComparator orderByComparator, boolean previous)
           
 List<ShoppingItemPrice> getShoppingItemPrices(long pk)
          Gets all the shopping item prices associated with the shopping item.
 List<ShoppingItemPrice> getShoppingItemPrices(long pk, int start, int end)
          Gets a range of all the shopping item prices associated with the shopping item.
 List<ShoppingItemPrice> getShoppingItemPrices(long pk, int start, int end, OrderByComparator orderByComparator)
          Gets an ordered range of all the shopping item prices associated with the shopping item.
 int getShoppingItemPricesSize(long pk)
          Gets the number of shopping item prices associated with the shopping item.
 ShoppingItem remove(long itemId)
          Removes the shopping item with the primary key from the database.
 ShoppingItem remove(Serializable primaryKey)
          Removes the shopping item with the primary key from the database.
 void removeAll()
          Removes all the shopping items from the database.
 void removeByC_S(long companyId, String sku)
          Removes the shopping item where companyId = ? and sku = ? from the database.
 void removeByG_C(long groupId, long categoryId)
          Removes all the shopping items where groupId = ? and categoryId = ? from the database.
 void removeByLargeImageId(long largeImageId)
          Removes the shopping item where largeImageId = ? from the database.
 void removeByMediumImageId(long mediumImageId)
          Removes the shopping item where mediumImageId = ? from the database.
 void removeBySmallImageId(long smallImageId)
          Removes the shopping item where smallImageId = ? from the database.
protected  ShoppingItem removeImpl(ShoppingItem shoppingItem)
          Removes the model instance from the database.
protected  ShoppingItem toUnwrappedModel(ShoppingItem shoppingItem)
           
 ShoppingItem updateImpl(ShoppingItem shoppingItem, boolean merge)
          Updates the model instance in the database or adds it if it does not yet exist.
 
Methods inherited from class com.liferay.portal.service.persistence.impl.BasePersistenceImpl
appendOrderByComparator, closeSession, countWithDynamicQuery, findWithDynamicQuery, findWithDynamicQuery, findWithDynamicQuery, getDataSource, getDialect, getListeners, openNewSession, openSession, processException, registerListener, remove, setDataSource, setSessionFactory, unregisterListener, update, update
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface com.liferay.portal.service.persistence.BasePersistence
countWithDynamicQuery, findWithDynamicQuery, findWithDynamicQuery, findWithDynamicQuery, getDataSource, getListeners, registerListener, remove, setDataSource, unregisterListener, update, update
 

Field Detail

FINDER_CLASS_NAME_ENTITY

public static final String FINDER_CLASS_NAME_ENTITY

FINDER_CLASS_NAME_LIST

public static final String FINDER_CLASS_NAME_LIST

FINDER_PATH_FETCH_BY_SMALLIMAGEID

public static final FinderPath FINDER_PATH_FETCH_BY_SMALLIMAGEID

FINDER_PATH_COUNT_BY_SMALLIMAGEID

public static final FinderPath FINDER_PATH_COUNT_BY_SMALLIMAGEID

FINDER_PATH_FETCH_BY_MEDIUMIMAGEID

public static final FinderPath FINDER_PATH_FETCH_BY_MEDIUMIMAGEID

FINDER_PATH_COUNT_BY_MEDIUMIMAGEID

public static final FinderPath FINDER_PATH_COUNT_BY_MEDIUMIMAGEID

FINDER_PATH_FETCH_BY_LARGEIMAGEID

public static final FinderPath FINDER_PATH_FETCH_BY_LARGEIMAGEID

FINDER_PATH_COUNT_BY_LARGEIMAGEID

public static final FinderPath FINDER_PATH_COUNT_BY_LARGEIMAGEID

FINDER_PATH_FIND_BY_G_C

public static final FinderPath FINDER_PATH_FIND_BY_G_C

FINDER_PATH_COUNT_BY_G_C

public static final FinderPath FINDER_PATH_COUNT_BY_G_C

FINDER_PATH_FETCH_BY_C_S

public static final FinderPath FINDER_PATH_FETCH_BY_C_S

FINDER_PATH_COUNT_BY_C_S

public static final FinderPath FINDER_PATH_COUNT_BY_C_S

FINDER_PATH_FIND_ALL

public static final FinderPath FINDER_PATH_FIND_ALL

FINDER_PATH_COUNT_ALL

public static final FinderPath FINDER_PATH_COUNT_ALL

FINDER_PATH_GET_SHOPPINGITEMPRICES

public static final FinderPath FINDER_PATH_GET_SHOPPINGITEMPRICES

FINDER_PATH_GET_SHOPPINGITEMPRICES_SIZE

public static final FinderPath FINDER_PATH_GET_SHOPPINGITEMPRICES_SIZE

FINDER_PATH_CONTAINS_SHOPPINGITEMPRICE

public static final FinderPath FINDER_PATH_CONTAINS_SHOPPINGITEMPRICE

shoppingCartPersistence

@BeanReference(type=ShoppingCartPersistence.class)
protected ShoppingCartPersistence shoppingCartPersistence

shoppingCategoryPersistence

@BeanReference(type=ShoppingCategoryPersistence.class)
protected ShoppingCategoryPersistence shoppingCategoryPersistence

shoppingCouponPersistence

@BeanReference(type=ShoppingCouponPersistence.class)
protected ShoppingCouponPersistence shoppingCouponPersistence

shoppingItemPersistence

@BeanReference(type=ShoppingItemPersistence.class)
protected ShoppingItemPersistence shoppingItemPersistence

shoppingItemFieldPersistence

@BeanReference(type=ShoppingItemFieldPersistence.class)
protected ShoppingItemFieldPersistence shoppingItemFieldPersistence

shoppingItemPricePersistence

@BeanReference(type=ShoppingItemPricePersistence.class)
protected ShoppingItemPricePersistence shoppingItemPricePersistence

shoppingOrderPersistence

@BeanReference(type=ShoppingOrderPersistence.class)
protected ShoppingOrderPersistence shoppingOrderPersistence

shoppingOrderItemPersistence

@BeanReference(type=ShoppingOrderItemPersistence.class)
protected ShoppingOrderItemPersistence shoppingOrderItemPersistence

imagePersistence

@BeanReference(type=ImagePersistence.class)
protected ImagePersistence imagePersistence

resourcePersistence

@BeanReference(type=ResourcePersistence.class)
protected ResourcePersistence resourcePersistence

userPersistence

@BeanReference(type=UserPersistence.class)
protected UserPersistence userPersistence

containsShoppingItemPrice

protected ShoppingItemPersistenceImpl.ContainsShoppingItemPrice containsShoppingItemPrice
Constructor Detail

ShoppingItemPersistenceImpl

public ShoppingItemPersistenceImpl()
Method Detail

cacheResult

public void cacheResult(ShoppingItem shoppingItem)
Caches the shopping item in the entity cache if it is enabled.

Specified by:
cacheResult in interface ShoppingItemPersistence
Parameters:
shoppingItem - the shopping item to cache

cacheResult

public void cacheResult(List<ShoppingItem> shoppingItems)
Caches the shopping items in the entity cache if it is enabled.

Specified by:
cacheResult in interface ShoppingItemPersistence
Parameters:
shoppingItems - the shopping items to cache

clearCache

public void clearCache()
Clears the cache for all shopping items.

The EntityCache and FinderCache are both cleared by this method.

Specified by:
clearCache in interface BasePersistence<ShoppingItem>
Overrides:
clearCache in class BasePersistenceImpl<ShoppingItem>

clearCache

public void clearCache(ShoppingItem shoppingItem)
Clears the cache for the shopping item.

The EntityCache and FinderCache are both cleared by this method.

Specified by:
clearCache in interface BasePersistence<ShoppingItem>
Overrides:
clearCache in class BasePersistenceImpl<ShoppingItem>
Parameters:
shoppingItem - the instance of this model to clear the cache for

create

public ShoppingItem create(long itemId)
Creates a new shopping item with the primary key. Does not add the shopping item to the database.

Specified by:
create in interface ShoppingItemPersistence
Parameters:
itemId - the primary key for the new shopping item
Returns:
the new shopping item

remove

public ShoppingItem remove(Serializable primaryKey)
                    throws NoSuchModelException,
                           SystemException
Removes the shopping item with the primary key from the database. Also notifies the appropriate model listeners.

Specified by:
remove in interface BasePersistence<ShoppingItem>
Overrides:
remove in class BasePersistenceImpl<ShoppingItem>
Parameters:
primaryKey - the primary key of the shopping item to remove
Returns:
the shopping item that was removed
Throws:
NoSuchModelException - if a shopping item with the primary key could not be found
SystemException - if a system exception occurred

remove

public ShoppingItem remove(long itemId)
                    throws NoSuchItemException,
                           SystemException
Removes the shopping item with the primary key from the database. Also notifies the appropriate model listeners.

Specified by:
remove in interface ShoppingItemPersistence
Parameters:
itemId - the primary key of the shopping item to remove
Returns:
the shopping item that was removed
Throws:
NoSuchItemException - if a shopping item with the primary key could not be found
SystemException - if a system exception occurred

removeImpl

protected ShoppingItem removeImpl(ShoppingItem shoppingItem)
                           throws SystemException
Description copied from class: BasePersistenceImpl
Removes the model instance from the database. BasePersistenceImpl.update(BaseModel, boolean) depends on this method to implement the remove operation; it only notifies the model listeners.

Overrides:
removeImpl in class BasePersistenceImpl<ShoppingItem>
Parameters:
shoppingItem - the model instance to remove
Returns:
the model instance that was removed
Throws:
SystemException - if a system exception occurred

updateImpl

public ShoppingItem updateImpl(ShoppingItem shoppingItem,
                               boolean merge)
                        throws SystemException
Description copied from class: BasePersistenceImpl
Updates the model instance in the database or adds it if it does not yet exist. BasePersistenceImpl.remove(BaseModel) depends on this method to implement the update operation; it only notifies the model listeners.

Specified by:
updateImpl in interface ShoppingItemPersistence
Overrides:
updateImpl in class BasePersistenceImpl<ShoppingItem>
Parameters:
shoppingItem - the model instance to update
merge - whether to merge the model instance with the current session. See BatchSession.update( com.liferay.portal.kernel.dao.orm.Session, BaseModel, boolean) for an explanation.
Returns:
the model instance that was updated
Throws:
SystemException - if a system exception occurred

toUnwrappedModel

protected ShoppingItem toUnwrappedModel(ShoppingItem shoppingItem)

findByPrimaryKey

public ShoppingItem findByPrimaryKey(Serializable primaryKey)
                              throws NoSuchModelException,
                                     SystemException
Finds the shopping item with the primary key or throws a NoSuchModelException if it could not be found.

Specified by:
findByPrimaryKey in interface BasePersistence<ShoppingItem>
Overrides:
findByPrimaryKey in class BasePersistenceImpl<ShoppingItem>
Parameters:
primaryKey - the primary key of the shopping item to find
Returns:
the shopping item
Throws:
NoSuchModelException - if a shopping item with the primary key could not be found
SystemException - if a system exception occurred

findByPrimaryKey

public ShoppingItem findByPrimaryKey(long itemId)
                              throws NoSuchItemException,
                                     SystemException
Finds the shopping item with the primary key or throws a NoSuchItemException if it could not be found.

Specified by:
findByPrimaryKey in interface ShoppingItemPersistence
Parameters:
itemId - the primary key of the shopping item to find
Returns:
the shopping item
Throws:
NoSuchItemException - if a shopping item with the primary key could not be found
SystemException - if a system exception occurred

fetchByPrimaryKey

public ShoppingItem fetchByPrimaryKey(Serializable primaryKey)
                               throws SystemException
Finds the shopping item with the primary key or returns null if it could not be found.

Specified by:
fetchByPrimaryKey in interface BasePersistence<ShoppingItem>
Overrides:
fetchByPrimaryKey in class BasePersistenceImpl<ShoppingItem>
Parameters:
primaryKey - the primary key of the shopping item to find
Returns:
the shopping item, or null if a shopping item with the primary key could not be found
Throws:
SystemException - if a system exception occurred

fetchByPrimaryKey

public ShoppingItem fetchByPrimaryKey(long itemId)
                               throws SystemException
Finds the shopping item with the primary key or returns null if it could not be found.

Specified by:
fetchByPrimaryKey in interface ShoppingItemPersistence
Parameters:
itemId - the primary key of the shopping item to find
Returns:
the shopping item, or null if a shopping item with the primary key could not be found
Throws:
SystemException - if a system exception occurred

findBySmallImageId

public ShoppingItem findBySmallImageId(long smallImageId)
                                throws NoSuchItemException,
                                       SystemException
Finds the shopping item where smallImageId = ? or throws a NoSuchItemException if it could not be found.

Specified by:
findBySmallImageId in interface ShoppingItemPersistence
Parameters:
smallImageId - the small image id to search with
Returns:
the matching shopping item
Throws:
NoSuchItemException - if a matching shopping item could not be found
SystemException - if a system exception occurred

fetchBySmallImageId

public ShoppingItem fetchBySmallImageId(long smallImageId)
                                 throws SystemException
Finds the shopping item where smallImageId = ? or returns null if it could not be found. Uses the finder cache.

Specified by:
fetchBySmallImageId in interface ShoppingItemPersistence
Parameters:
smallImageId - the small image id to search with
Returns:
the matching shopping item, or null if a matching shopping item could not be found
Throws:
SystemException - if a system exception occurred

fetchBySmallImageId

public ShoppingItem fetchBySmallImageId(long smallImageId,
                                        boolean retrieveFromCache)
                                 throws SystemException
Finds the shopping item where smallImageId = ? or returns null if it could not be found, optionally using the finder cache.

Specified by:
fetchBySmallImageId in interface ShoppingItemPersistence
Parameters:
smallImageId - the small image id to search with
Returns:
the matching shopping item, or null if a matching shopping item could not be found
Throws:
SystemException - if a system exception occurred

findByMediumImageId

public ShoppingItem findByMediumImageId(long mediumImageId)
                                 throws NoSuchItemException,
                                        SystemException
Finds the shopping item where mediumImageId = ? or throws a NoSuchItemException if it could not be found.

Specified by:
findByMediumImageId in interface ShoppingItemPersistence
Parameters:
mediumImageId - the medium image id to search with
Returns:
the matching shopping item
Throws:
NoSuchItemException - if a matching shopping item could not be found
SystemException - if a system exception occurred

fetchByMediumImageId

public ShoppingItem fetchByMediumImageId(long mediumImageId)
                                  throws SystemException
Finds the shopping item where mediumImageId = ? or returns null if it could not be found. Uses the finder cache.

Specified by:
fetchByMediumImageId in interface ShoppingItemPersistence
Parameters:
mediumImageId - the medium image id to search with
Returns:
the matching shopping item, or null if a matching shopping item could not be found
Throws:
SystemException - if a system exception occurred

fetchByMediumImageId

public ShoppingItem fetchByMediumImageId(long mediumImageId,
                                         boolean retrieveFromCache)
                                  throws SystemException
Finds the shopping item where mediumImageId = ? or returns null if it could not be found, optionally using the finder cache.

Specified by:
fetchByMediumImageId in interface ShoppingItemPersistence
Parameters:
mediumImageId - the medium image id to search with
Returns:
the matching shopping item, or null if a matching shopping item could not be found
Throws:
SystemException - if a system exception occurred

findByLargeImageId

public ShoppingItem findByLargeImageId(long largeImageId)
                                throws NoSuchItemException,
                                       SystemException
Finds the shopping item where largeImageId = ? or throws a NoSuchItemException if it could not be found.

Specified by:
findByLargeImageId in interface ShoppingItemPersistence
Parameters:
largeImageId - the large image id to search with
Returns:
the matching shopping item
Throws:
NoSuchItemException - if a matching shopping item could not be found
SystemException - if a system exception occurred

fetchByLargeImageId

public ShoppingItem fetchByLargeImageId(long largeImageId)
                                 throws SystemException
Finds the shopping item where largeImageId = ? or returns null if it could not be found. Uses the finder cache.

Specified by:
fetchByLargeImageId in interface ShoppingItemPersistence
Parameters:
largeImageId - the large image id to search with
Returns:
the matching shopping item, or null if a matching shopping item could not be found
Throws:
SystemException - if a system exception occurred

fetchByLargeImageId

public ShoppingItem fetchByLargeImageId(long largeImageId,
                                        boolean retrieveFromCache)
                                 throws SystemException
Finds the shopping item where largeImageId = ? or returns null if it could not be found, optionally using the finder cache.

Specified by:
fetchByLargeImageId in interface ShoppingItemPersistence
Parameters:
largeImageId - the large image id to search with
Returns:
the matching shopping item, or null if a matching shopping item could not be found
Throws:
SystemException - if a system exception occurred

findByG_C

public List<ShoppingItem> findByG_C(long groupId,
                                    long categoryId)
                             throws SystemException
Finds all the shopping items where groupId = ? and categoryId = ?.

Specified by:
findByG_C in interface ShoppingItemPersistence
Parameters:
groupId - the group id to search with
categoryId - the category id to search with
Returns:
the matching shopping items
Throws:
SystemException - if a system exception occurred

findByG_C

public List<ShoppingItem> findByG_C(long groupId,
                                    long categoryId,
                                    int start,
                                    int end)
                             throws SystemException
Finds a range of all the shopping items where groupId = ? and categoryId = ?.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil.ALL_POS will return the full result set.

Specified by:
findByG_C in interface ShoppingItemPersistence
Parameters:
groupId - the group id to search with
categoryId - the category id to search with
start - the lower bound of the range of shopping items to return
end - the upper bound of the range of shopping items to return (not inclusive)
Returns:
the range of matching shopping items
Throws:
SystemException - if a system exception occurred

findByG_C

public List<ShoppingItem> findByG_C(long groupId,
                                    long categoryId,
                                    int start,
                                    int end,
                                    OrderByComparator orderByComparator)
                             throws SystemException
Finds an ordered range of all the shopping items where groupId = ? and categoryId = ?.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil.ALL_POS will return the full result set.

Specified by:
findByG_C in interface ShoppingItemPersistence
Parameters:
groupId - the group id to search with
categoryId - the category id to search with
start - the lower bound of the range of shopping items to return
end - the upper bound of the range of shopping items to return (not inclusive)
orderByComparator - the comparator to order the results by
Returns:
the ordered range of matching shopping items
Throws:
SystemException - if a system exception occurred

findByG_C_First

public ShoppingItem findByG_C_First(long groupId,
                                    long categoryId,
                                    OrderByComparator orderByComparator)
                             throws NoSuchItemException,
                                    SystemException
Finds the first shopping item in the ordered set where groupId = ? and categoryId = ?.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil.ALL_POS will return the full result set.

Specified by:
findByG_C_First in interface ShoppingItemPersistence
Parameters:
groupId - the group id to search with
categoryId - the category id to search with
orderByComparator - the comparator to order the set by
Returns:
the first matching shopping item
Throws:
NoSuchItemException - if a matching shopping item could not be found
SystemException - if a system exception occurred

findByG_C_Last

public ShoppingItem findByG_C_Last(long groupId,
                                   long categoryId,
                                   OrderByComparator orderByComparator)
                            throws NoSuchItemException,
                                   SystemException
Finds the last shopping item in the ordered set where groupId = ? and categoryId = ?.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil.ALL_POS will return the full result set.

Specified by:
findByG_C_Last in interface ShoppingItemPersistence
Parameters:
groupId - the group id to search with
categoryId - the category id to search with
orderByComparator - the comparator to order the set by
Returns:
the last matching shopping item
Throws:
NoSuchItemException - if a matching shopping item could not be found
SystemException - if a system exception occurred

findByG_C_PrevAndNext

public ShoppingItem[] findByG_C_PrevAndNext(long itemId,
                                            long groupId,
                                            long categoryId,
                                            OrderByComparator orderByComparator)
                                     throws NoSuchItemException,
                                            SystemException
Finds the shopping items before and after the current shopping item in the ordered set where groupId = ? and categoryId = ?.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil.ALL_POS will return the full result set.

Specified by:
findByG_C_PrevAndNext in interface ShoppingItemPersistence
Parameters:
itemId - the primary key of the current shopping item
groupId - the group id to search with
categoryId - the category id to search with
orderByComparator - the comparator to order the set by
Returns:
the previous, current, and next shopping item
Throws:
NoSuchItemException - if a shopping item with the primary key could not be found
SystemException - if a system exception occurred

getByG_C_PrevAndNext

protected ShoppingItem getByG_C_PrevAndNext(Session session,
                                            ShoppingItem shoppingItem,
                                            long groupId,
                                            long categoryId,
                                            OrderByComparator orderByComparator,
                                            boolean previous)

filterFindByG_C

public List<ShoppingItem> filterFindByG_C(long groupId,
                                          long categoryId)
                                   throws SystemException
Filters by the user's permissions and finds all the shopping items where groupId = ? and categoryId = ?.

Specified by:
filterFindByG_C in interface ShoppingItemPersistence
Parameters:
groupId - the group id to search with
categoryId - the category id to search with
Returns:
the matching shopping items that the user has permission to view
Throws:
SystemException - if a system exception occurred

filterFindByG_C

public List<ShoppingItem> filterFindByG_C(long groupId,
                                          long categoryId,
                                          int start,
                                          int end)
                                   throws SystemException
Filters by the user's permissions and finds a range of all the shopping items where groupId = ? and categoryId = ?.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil.ALL_POS will return the full result set.

Specified by:
filterFindByG_C in interface ShoppingItemPersistence
Parameters:
groupId - the group id to search with
categoryId - the category id to search with
start - the lower bound of the range of shopping items to return
end - the upper bound of the range of shopping items to return (not inclusive)
Returns:
the range of matching shopping items that the user has permission to view
Throws:
SystemException - if a system exception occurred

filterFindByG_C

public List<ShoppingItem> filterFindByG_C(long groupId,
                                          long categoryId,
                                          int start,
                                          int end,
                                          OrderByComparator orderByComparator)
                                   throws SystemException
Filters by the user's permissions and finds an ordered range of all the shopping items where groupId = ? and categoryId = ?.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil.ALL_POS will return the full result set.

Specified by:
filterFindByG_C in interface ShoppingItemPersistence
Parameters:
groupId - the group id to search with
categoryId - the category id to search with
start - the lower bound of the range of shopping items to return
end - the upper bound of the range of shopping items to return (not inclusive)
orderByComparator - the comparator to order the results by
Returns:
the ordered range of matching shopping items that the user has permission to view
Throws:
SystemException - if a system exception occurred

findByC_S

public ShoppingItem findByC_S(long companyId,
                              String sku)
                       throws NoSuchItemException,
                              SystemException
Finds the shopping item where companyId = ? and sku = ? or throws a NoSuchItemException if it could not be found.

Specified by:
findByC_S in interface ShoppingItemPersistence
Parameters:
companyId - the company id to search with
sku - the sku to search with
Returns:
the matching shopping item
Throws:
NoSuchItemException - if a matching shopping item could not be found
SystemException - if a system exception occurred

fetchByC_S

public ShoppingItem fetchByC_S(long companyId,
                               String sku)
                        throws SystemException
Finds the shopping item where companyId = ? and sku = ? or returns null if it could not be found. Uses the finder cache.

Specified by:
fetchByC_S in interface ShoppingItemPersistence
Parameters:
companyId - the company id to search with
sku - the sku to search with
Returns:
the matching shopping item, or null if a matching shopping item could not be found
Throws:
SystemException - if a system exception occurred

fetchByC_S

public ShoppingItem fetchByC_S(long companyId,
                               String sku,
                               boolean retrieveFromCache)
                        throws SystemException
Finds the shopping item where companyId = ? and sku = ? or returns null if it could not be found, optionally using the finder cache.

Specified by:
fetchByC_S in interface ShoppingItemPersistence
Parameters:
companyId - the company id to search with
sku - the sku to search with
Returns:
the matching shopping item, or null if a matching shopping item could not be found
Throws:
SystemException - if a system exception occurred

findAll

public List<ShoppingItem> findAll()
                           throws SystemException
Finds all the shopping items.

Specified by:
findAll in interface ShoppingItemPersistence
Returns:
the shopping items
Throws:
SystemException - if a system exception occurred

findAll

public List<ShoppingItem> findAll(int start,
                                  int end)
                           throws SystemException
Finds a range of all the shopping items.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil.ALL_POS will return the full result set.

Specified by:
findAll in interface ShoppingItemPersistence
Parameters:
start - the lower bound of the range of shopping items to return
end - the upper bound of the range of shopping items to return (not inclusive)
Returns:
the range of shopping items
Throws:
SystemException - if a system exception occurred

findAll

public List<ShoppingItem> findAll(int start,
                                  int end,
                                  OrderByComparator orderByComparator)
                           throws SystemException
Finds an ordered range of all the shopping items.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil.ALL_POS will return the full result set.

Specified by:
findAll in interface ShoppingItemPersistence
Parameters:
start - the lower bound of the range of shopping items to return
end - the upper bound of the range of shopping items to return (not inclusive)
orderByComparator - the comparator to order the results by
Returns:
the ordered range of shopping items
Throws:
SystemException - if a system exception occurred

removeBySmallImageId

public void removeBySmallImageId(long smallImageId)
                          throws NoSuchItemException,
                                 SystemException
Removes the shopping item where smallImageId = ? from the database.

Specified by:
removeBySmallImageId in interface ShoppingItemPersistence
Parameters:
smallImageId - the small image id to search with
Throws:
SystemException - if a system exception occurred
NoSuchItemException

removeByMediumImageId

public void removeByMediumImageId(long mediumImageId)
                           throws NoSuchItemException,
                                  SystemException
Removes the shopping item where mediumImageId = ? from the database.

Specified by:
removeByMediumImageId in interface ShoppingItemPersistence
Parameters:
mediumImageId - the medium image id to search with
Throws:
SystemException - if a system exception occurred
NoSuchItemException

removeByLargeImageId

public void removeByLargeImageId(long largeImageId)
                          throws NoSuchItemException,
                                 SystemException
Removes the shopping item where largeImageId = ? from the database.

Specified by:
removeByLargeImageId in interface ShoppingItemPersistence
Parameters:
largeImageId - the large image id to search with
Throws:
SystemException - if a system exception occurred
NoSuchItemException

removeByG_C

public void removeByG_C(long groupId,
                        long categoryId)
                 throws SystemException
Removes all the shopping items where groupId = ? and categoryId = ? from the database.

Specified by:
removeByG_C in interface ShoppingItemPersistence
Parameters:
groupId - the group id to search with
categoryId - the category id to search with
Throws:
SystemException - if a system exception occurred

removeByC_S

public void removeByC_S(long companyId,
                        String sku)
                 throws NoSuchItemException,
                        SystemException
Removes the shopping item where companyId = ? and sku = ? from the database.

Specified by:
removeByC_S in interface ShoppingItemPersistence
Parameters:
companyId - the company id to search with
sku - the sku to search with
Throws:
SystemException - if a system exception occurred
NoSuchItemException

removeAll

public void removeAll()
               throws SystemException
Removes all the shopping items from the database.

Specified by:
removeAll in interface ShoppingItemPersistence
Throws:
SystemException - if a system exception occurred

countBySmallImageId

public int countBySmallImageId(long smallImageId)
                        throws SystemException
Counts all the shopping items where smallImageId = ?.

Specified by:
countBySmallImageId in interface ShoppingItemPersistence
Parameters:
smallImageId - the small image id to search with
Returns:
the number of matching shopping items
Throws:
SystemException - if a system exception occurred

countByMediumImageId

public int countByMediumImageId(long mediumImageId)
                         throws SystemException
Counts all the shopping items where mediumImageId = ?.

Specified by:
countByMediumImageId in interface ShoppingItemPersistence
Parameters:
mediumImageId - the medium image id to search with
Returns:
the number of matching shopping items
Throws:
SystemException - if a system exception occurred

countByLargeImageId

public int countByLargeImageId(long largeImageId)
                        throws SystemException
Counts all the shopping items where largeImageId = ?.

Specified by:
countByLargeImageId in interface ShoppingItemPersistence
Parameters:
largeImageId - the large image id to search with
Returns:
the number of matching shopping items
Throws:
SystemException - if a system exception occurred

countByG_C

public int countByG_C(long groupId,
                      long categoryId)
               throws SystemException
Counts all the shopping items where groupId = ? and categoryId = ?.

Specified by:
countByG_C in interface ShoppingItemPersistence
Parameters:
groupId - the group id to search with
categoryId - the category id to search with
Returns:
the number of matching shopping items
Throws:
SystemException - if a system exception occurred

filterCountByG_C

public int filterCountByG_C(long groupId,
                            long categoryId)
                     throws SystemException
Filters by the user's permissions and counts all the shopping items where groupId = ? and categoryId = ?.

Specified by:
filterCountByG_C in interface ShoppingItemPersistence
Parameters:
groupId - the group id to search with
categoryId - the category id to search with
Returns:
the number of matching shopping items that the user has permission to view
Throws:
SystemException - if a system exception occurred

countByC_S

public int countByC_S(long companyId,
                      String sku)
               throws SystemException
Counts all the shopping items where companyId = ? and sku = ?.

Specified by:
countByC_S in interface ShoppingItemPersistence
Parameters:
companyId - the company id to search with
sku - the sku to search with
Returns:
the number of matching shopping items
Throws:
SystemException - if a system exception occurred

countAll

public int countAll()
             throws SystemException
Counts all the shopping items.

Specified by:
countAll in interface ShoppingItemPersistence
Returns:
the number of shopping items
Throws:
SystemException - if a system exception occurred

getShoppingItemPrices

public List<ShoppingItemPrice> getShoppingItemPrices(long pk)
                                              throws SystemException
Gets all the shopping item prices associated with the shopping item.

Specified by:
getShoppingItemPrices in interface ShoppingItemPersistence
Parameters:
pk - the primary key of the shopping item to get the associated shopping item prices for
Returns:
the shopping item prices associated with the shopping item
Throws:
SystemException - if a system exception occurred

getShoppingItemPrices

public List<ShoppingItemPrice> getShoppingItemPrices(long pk,
                                                     int start,
                                                     int end)
                                              throws SystemException
Gets a range of all the shopping item prices associated with the shopping item.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil.ALL_POS will return the full result set.

Specified by:
getShoppingItemPrices in interface ShoppingItemPersistence
Parameters:
pk - the primary key of the shopping item to get the associated shopping item prices for
start - the lower bound of the range of shopping items to return
end - the upper bound of the range of shopping items to return (not inclusive)
Returns:
the range of shopping item prices associated with the shopping item
Throws:
SystemException - if a system exception occurred

getShoppingItemPrices

public List<ShoppingItemPrice> getShoppingItemPrices(long pk,
                                                     int start,
                                                     int end,
                                                     OrderByComparator orderByComparator)
                                              throws SystemException
Gets an ordered range of all the shopping item prices associated with the shopping item.

Useful when paginating results. Returns a maximum of end - start instances. start and end are not primary keys, they are indexes in the result set. Thus, 0 refers to the first result in the set. Setting both start and end to QueryUtil.ALL_POS will return the full result set.

Specified by:
getShoppingItemPrices in interface ShoppingItemPersistence
Parameters:
pk - the primary key of the shopping item to get the associated shopping item prices for
start - the lower bound of the range of shopping items to return
end - the upper bound of the range of shopping items to return (not inclusive)
orderByComparator - the comparator to order the results by
Returns:
the ordered range of shopping item prices associated with the shopping item
Throws:
SystemException - if a system exception occurred

getShoppingItemPricesSize

public int getShoppingItemPricesSize(long pk)
                              throws SystemException
Gets the number of shopping item prices associated with the shopping item.

Specified by:
getShoppingItemPricesSize in interface ShoppingItemPersistence
Parameters:
pk - the primary key of the shopping item to get the number of associated shopping item prices for
Returns:
the number of shopping item prices associated with the shopping item
Throws:
SystemException - if a system exception occurred

containsShoppingItemPrice

public boolean containsShoppingItemPrice(long pk,
                                         long shoppingItemPricePK)
                                  throws SystemException
Determines whether the shopping item price is associated with the shopping item.

Specified by:
containsShoppingItemPrice in interface ShoppingItemPersistence
Parameters:
pk - the primary key of the shopping item
shoppingItemPricePK - the primary key of the shopping item price
Returns:
whether the shopping item price is associated with the shopping item
Throws:
SystemException - if a system exception occurred

containsShoppingItemPrices

public boolean containsShoppingItemPrices(long pk)
                                   throws SystemException
Determines whether the shopping item has any shopping item prices associated with it.

Specified by:
containsShoppingItemPrices in interface ShoppingItemPersistence
Parameters:
pk - the primary key of the shopping item to check for associations with shopping item prices
Returns:
whether the shopping item has any shopping item prices associated with it
Throws:
SystemException - if a system exception occurred

afterPropertiesSet

public void afterPropertiesSet()
Initializes the shopping item persistence.


Liferay 6.0.5