Liferay 6.0.5

com.liferay.portlet.shopping.service.persistence
Interface ShoppingCategoryPersistence

All Superinterfaces:
BasePersistence<ShoppingCategory>
All Known Implementing Classes:
ShoppingCategoryPersistenceImpl

public interface ShoppingCategoryPersistence
extends BasePersistence<ShoppingCategory>

The persistence interface for the shopping category service.

Never modify or reference this interface directly. Always use ShoppingCategoryUtil to access the shopping category persistence. Modify service.xml and rerun ServiceBuilder to regenerate this interface.

Caching information and settings can be found in portal.properties

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

Method Summary
 void cacheResult(List<ShoppingCategory> shoppingCategories)
          Caches the shopping categories in the entity cache if it is enabled.
 void cacheResult(ShoppingCategory shoppingCategory)
          Caches the shopping category in the entity cache if it is enabled.
 int countAll()
          Counts all the shopping categories.
 int countByG_P(long groupId, long parentCategoryId)
          Counts all the shopping categories where groupId = ? and parentCategoryId = ?.
 int countByGroupId(long groupId)
          Counts all the shopping categories where groupId = ?.
 ShoppingCategory create(long categoryId)
          Creates a new shopping category with the primary key.
 ShoppingCategory fetchByPrimaryKey(long categoryId)
          Finds the shopping category with the primary key or returns null if it could not be found.
 int filterCountByG_P(long groupId, long parentCategoryId)
          Filters by the user's permissions and counts all the shopping categories where groupId = ? and parentCategoryId = ?.
 int filterCountByGroupId(long groupId)
          Filters by the user's permissions and counts all the shopping categories where groupId = ?.
 List<ShoppingCategory> filterFindByG_P(long groupId, long parentCategoryId)
          Filters by the user's permissions and finds all the shopping categories where groupId = ? and parentCategoryId = ?.
 List<ShoppingCategory> filterFindByG_P(long groupId, long parentCategoryId, int start, int end)
          Filters by the user's permissions and finds a range of all the shopping categories where groupId = ? and parentCategoryId = ?.
 List<ShoppingCategory> filterFindByG_P(long groupId, long parentCategoryId, int start, int end, OrderByComparator orderByComparator)
          Filters by the user's permissions and finds an ordered range of all the shopping categories where groupId = ? and parentCategoryId = ?.
 List<ShoppingCategory> filterFindByGroupId(long groupId)
          Filters by the user's permissions and finds all the shopping categories where groupId = ?.
 List<ShoppingCategory> filterFindByGroupId(long groupId, int start, int end)
          Filters by the user's permissions and finds a range of all the shopping categories where groupId = ?.
 List<ShoppingCategory> filterFindByGroupId(long groupId, int start, int end, OrderByComparator orderByComparator)
          Filters by the user's permissions and finds an ordered range of all the shopping categories where groupId = ?.
 List<ShoppingCategory> findAll()
          Finds all the shopping categories.
 List<ShoppingCategory> findAll(int start, int end)
          Finds a range of all the shopping categories.
 List<ShoppingCategory> findAll(int start, int end, OrderByComparator orderByComparator)
          Finds an ordered range of all the shopping categories.
 ShoppingCategory findByG_P_First(long groupId, long parentCategoryId, OrderByComparator orderByComparator)
          Finds the first shopping category in the ordered set where groupId = ? and parentCategoryId = ?.
 ShoppingCategory findByG_P_Last(long groupId, long parentCategoryId, OrderByComparator orderByComparator)
          Finds the last shopping category in the ordered set where groupId = ? and parentCategoryId = ?.
 ShoppingCategory[] findByG_P_PrevAndNext(long categoryId, long groupId, long parentCategoryId, OrderByComparator orderByComparator)
          Finds the shopping categories before and after the current shopping category in the ordered set where groupId = ? and parentCategoryId = ?.
 List<ShoppingCategory> findByG_P(long groupId, long parentCategoryId)
          Finds all the shopping categories where groupId = ? and parentCategoryId = ?.
 List<ShoppingCategory> findByG_P(long groupId, long parentCategoryId, int start, int end)
          Finds a range of all the shopping categories where groupId = ? and parentCategoryId = ?.
 List<ShoppingCategory> findByG_P(long groupId, long parentCategoryId, int start, int end, OrderByComparator orderByComparator)
          Finds an ordered range of all the shopping categories where groupId = ? and parentCategoryId = ?.
 ShoppingCategory findByGroupId_First(long groupId, OrderByComparator orderByComparator)
          Finds the first shopping category in the ordered set where groupId = ?.
 ShoppingCategory findByGroupId_Last(long groupId, OrderByComparator orderByComparator)
          Finds the last shopping category in the ordered set where groupId = ?.
 ShoppingCategory[] findByGroupId_PrevAndNext(long categoryId, long groupId, OrderByComparator orderByComparator)
          Finds the shopping categories before and after the current shopping category in the ordered set where groupId = ?.
 List<ShoppingCategory> findByGroupId(long groupId)
          Finds all the shopping categories where groupId = ?.
 List<ShoppingCategory> findByGroupId(long groupId, int start, int end)
          Finds a range of all the shopping categories where groupId = ?.
 List<ShoppingCategory> findByGroupId(long groupId, int start, int end, OrderByComparator orderByComparator)
          Finds an ordered range of all the shopping categories where groupId = ?.
 ShoppingCategory findByPrimaryKey(long categoryId)
          Finds the shopping category with the primary key or throws a NoSuchCategoryException if it could not be found.
 ShoppingCategory remove(long categoryId)
          Removes the shopping category with the primary key from the database.
 void removeAll()
          Removes all the shopping categories from the database.
 void removeByG_P(long groupId, long parentCategoryId)
          Removes all the shopping categories where groupId = ? and parentCategoryId = ? from the database.
 void removeByGroupId(long groupId)
          Removes all the shopping categories where groupId = ? from the database.
 ShoppingCategory updateImpl(ShoppingCategory shoppingCategory, boolean merge)
           
 
Methods inherited from interface com.liferay.portal.service.persistence.BasePersistence
clearCache, clearCache, countWithDynamicQuery, fetchByPrimaryKey, findByPrimaryKey, findWithDynamicQuery, findWithDynamicQuery, findWithDynamicQuery, getDataSource, getListeners, registerListener, remove, remove, setDataSource, unregisterListener, update, update
 

Method Detail

cacheResult

void cacheResult(ShoppingCategory shoppingCategory)
Caches the shopping category in the entity cache if it is enabled.

Parameters:
shoppingCategory - the shopping category to cache

cacheResult

void cacheResult(List<ShoppingCategory> shoppingCategories)
Caches the shopping categories in the entity cache if it is enabled.

Parameters:
shoppingCategories - the shopping categories to cache

create

ShoppingCategory create(long categoryId)
Creates a new shopping category with the primary key. Does not add the shopping category to the database.

Parameters:
categoryId - the primary key for the new shopping category
Returns:
the new shopping category

remove

ShoppingCategory remove(long categoryId)
                        throws SystemException,
                               NoSuchCategoryException
Removes the shopping category with the primary key from the database. Also notifies the appropriate model listeners.

Parameters:
categoryId - the primary key of the shopping category to remove
Returns:
the shopping category that was removed
Throws:
NoSuchCategoryException - if a shopping category with the primary key could not be found
SystemException - if a system exception occurred

updateImpl

ShoppingCategory updateImpl(ShoppingCategory shoppingCategory,
                            boolean merge)
                            throws SystemException
Throws:
SystemException

findByPrimaryKey

ShoppingCategory findByPrimaryKey(long categoryId)
                                  throws SystemException,
                                         NoSuchCategoryException
Finds the shopping category with the primary key or throws a NoSuchCategoryException if it could not be found.

Parameters:
categoryId - the primary key of the shopping category to find
Returns:
the shopping category
Throws:
NoSuchCategoryException - if a shopping category with the primary key could not be found
SystemException - if a system exception occurred

fetchByPrimaryKey

ShoppingCategory fetchByPrimaryKey(long categoryId)
                                   throws SystemException
Finds the shopping category with the primary key or returns null if it could not be found.

Parameters:
categoryId - the primary key of the shopping category to find
Returns:
the shopping category, or null if a shopping category with the primary key could not be found
Throws:
SystemException - if a system exception occurred

findByGroupId

List<ShoppingCategory> findByGroupId(long groupId)
                                     throws SystemException
Finds all the shopping categories where groupId = ?.

Parameters:
groupId - the group id to search with
Returns:
the matching shopping categories
Throws:
SystemException - if a system exception occurred

findByGroupId

List<ShoppingCategory> findByGroupId(long groupId,
                                     int start,
                                     int end)
                                     throws SystemException
Finds a range of all the shopping categories where groupId = ?.

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.

Parameters:
groupId - the group id to search with
start - the lower bound of the range of shopping categories to return
end - the upper bound of the range of shopping categories to return (not inclusive)
Returns:
the range of matching shopping categories
Throws:
SystemException - if a system exception occurred

findByGroupId

List<ShoppingCategory> findByGroupId(long groupId,
                                     int start,
                                     int end,
                                     OrderByComparator orderByComparator)
                                     throws SystemException
Finds an ordered range of all the shopping categories where groupId = ?.

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.

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

findByGroupId_First

ShoppingCategory findByGroupId_First(long groupId,
                                     OrderByComparator orderByComparator)
                                     throws SystemException,
                                            NoSuchCategoryException
Finds the first shopping category in the ordered set where groupId = ?.

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.

Parameters:
groupId - the group id to search with
orderByComparator - the comparator to order the set by
Returns:
the first matching shopping category
Throws:
NoSuchCategoryException - if a matching shopping category could not be found
SystemException - if a system exception occurred

findByGroupId_Last

ShoppingCategory findByGroupId_Last(long groupId,
                                    OrderByComparator orderByComparator)
                                    throws SystemException,
                                           NoSuchCategoryException
Finds the last shopping category in the ordered set where groupId = ?.

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.

Parameters:
groupId - the group id to search with
orderByComparator - the comparator to order the set by
Returns:
the last matching shopping category
Throws:
NoSuchCategoryException - if a matching shopping category could not be found
SystemException - if a system exception occurred

findByGroupId_PrevAndNext

ShoppingCategory[] findByGroupId_PrevAndNext(long categoryId,
                                             long groupId,
                                             OrderByComparator orderByComparator)
                                             throws SystemException,
                                                    NoSuchCategoryException
Finds the shopping categories before and after the current shopping category in the ordered set where groupId = ?.

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.

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

filterFindByGroupId

List<ShoppingCategory> filterFindByGroupId(long groupId)
                                           throws SystemException
Filters by the user's permissions and finds all the shopping categories where groupId = ?.

Parameters:
groupId - the group id to search with
Returns:
the matching shopping categories that the user has permission to view
Throws:
SystemException - if a system exception occurred

filterFindByGroupId

List<ShoppingCategory> filterFindByGroupId(long groupId,
                                           int start,
                                           int end)
                                           throws SystemException
Filters by the user's permissions and finds a range of all the shopping categories where groupId = ?.

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.

Parameters:
groupId - the group id to search with
start - the lower bound of the range of shopping categories to return
end - the upper bound of the range of shopping categories to return (not inclusive)
Returns:
the range of matching shopping categories that the user has permission to view
Throws:
SystemException - if a system exception occurred

filterFindByGroupId

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

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.

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

findByG_P

List<ShoppingCategory> findByG_P(long groupId,
                                 long parentCategoryId)
                                 throws SystemException
Finds all the shopping categories where groupId = ? and parentCategoryId = ?.

Parameters:
groupId - the group id to search with
parentCategoryId - the parent category id to search with
Returns:
the matching shopping categories
Throws:
SystemException - if a system exception occurred

findByG_P

List<ShoppingCategory> findByG_P(long groupId,
                                 long parentCategoryId,
                                 int start,
                                 int end)
                                 throws SystemException
Finds a range of all the shopping categories where groupId = ? and parentCategoryId = ?.

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.

Parameters:
groupId - the group id to search with
parentCategoryId - the parent category id to search with
start - the lower bound of the range of shopping categories to return
end - the upper bound of the range of shopping categories to return (not inclusive)
Returns:
the range of matching shopping categories
Throws:
SystemException - if a system exception occurred

findByG_P

List<ShoppingCategory> findByG_P(long groupId,
                                 long parentCategoryId,
                                 int start,
                                 int end,
                                 OrderByComparator orderByComparator)
                                 throws SystemException
Finds an ordered range of all the shopping categories where groupId = ? and parentCategoryId = ?.

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.

Parameters:
groupId - the group id to search with
parentCategoryId - the parent category id to search with
start - the lower bound of the range of shopping categories to return
end - the upper bound of the range of shopping categories to return (not inclusive)
orderByComparator - the comparator to order the results by
Returns:
the ordered range of matching shopping categories
Throws:
SystemException - if a system exception occurred

findByG_P_First

ShoppingCategory findByG_P_First(long groupId,
                                 long parentCategoryId,
                                 OrderByComparator orderByComparator)
                                 throws SystemException,
                                        NoSuchCategoryException
Finds the first shopping category in the ordered set where groupId = ? and parentCategoryId = ?.

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.

Parameters:
groupId - the group id to search with
parentCategoryId - the parent category id to search with
orderByComparator - the comparator to order the set by
Returns:
the first matching shopping category
Throws:
NoSuchCategoryException - if a matching shopping category could not be found
SystemException - if a system exception occurred

findByG_P_Last

ShoppingCategory findByG_P_Last(long groupId,
                                long parentCategoryId,
                                OrderByComparator orderByComparator)
                                throws SystemException,
                                       NoSuchCategoryException
Finds the last shopping category in the ordered set where groupId = ? and parentCategoryId = ?.

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.

Parameters:
groupId - the group id to search with
parentCategoryId - the parent category id to search with
orderByComparator - the comparator to order the set by
Returns:
the last matching shopping category
Throws:
NoSuchCategoryException - if a matching shopping category could not be found
SystemException - if a system exception occurred

findByG_P_PrevAndNext

ShoppingCategory[] findByG_P_PrevAndNext(long categoryId,
                                         long groupId,
                                         long parentCategoryId,
                                         OrderByComparator orderByComparator)
                                         throws SystemException,
                                                NoSuchCategoryException
Finds the shopping categories before and after the current shopping category in the ordered set where groupId = ? and parentCategoryId = ?.

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.

Parameters:
categoryId - the primary key of the current shopping category
groupId - the group id to search with
parentCategoryId - the parent category id to search with
orderByComparator - the comparator to order the set by
Returns:
the previous, current, and next shopping category
Throws:
NoSuchCategoryException - if a shopping category with the primary key could not be found
SystemException - if a system exception occurred

filterFindByG_P

List<ShoppingCategory> filterFindByG_P(long groupId,
                                       long parentCategoryId)
                                       throws SystemException
Filters by the user's permissions and finds all the shopping categories where groupId = ? and parentCategoryId = ?.

Parameters:
groupId - the group id to search with
parentCategoryId - the parent category id to search with
Returns:
the matching shopping categories that the user has permission to view
Throws:
SystemException - if a system exception occurred

filterFindByG_P

List<ShoppingCategory> filterFindByG_P(long groupId,
                                       long parentCategoryId,
                                       int start,
                                       int end)
                                       throws SystemException
Filters by the user's permissions and finds a range of all the shopping categories where groupId = ? and parentCategoryId = ?.

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.

Parameters:
groupId - the group id to search with
parentCategoryId - the parent category id to search with
start - the lower bound of the range of shopping categories to return
end - the upper bound of the range of shopping categories to return (not inclusive)
Returns:
the range of matching shopping categories that the user has permission to view
Throws:
SystemException - if a system exception occurred

filterFindByG_P

List<ShoppingCategory> filterFindByG_P(long groupId,
                                       long parentCategoryId,
                                       int start,
                                       int end,
                                       OrderByComparator orderByComparator)
                                       throws SystemException
Filters by the user's permissions and finds an ordered range of all the shopping categories where groupId = ? and parentCategoryId = ?.

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.

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

findAll

List<ShoppingCategory> findAll()
                               throws SystemException
Finds all the shopping categories.

Returns:
the shopping categories
Throws:
SystemException - if a system exception occurred

findAll

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

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.

Parameters:
start - the lower bound of the range of shopping categories to return
end - the upper bound of the range of shopping categories to return (not inclusive)
Returns:
the range of shopping categories
Throws:
SystemException - if a system exception occurred

findAll

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

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.

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

removeByGroupId

void removeByGroupId(long groupId)
                     throws SystemException
Removes all the shopping categories where groupId = ? from the database.

Parameters:
groupId - the group id to search with
Throws:
SystemException - if a system exception occurred

removeByG_P

void removeByG_P(long groupId,
                 long parentCategoryId)
                 throws SystemException
Removes all the shopping categories where groupId = ? and parentCategoryId = ? from the database.

Parameters:
groupId - the group id to search with
parentCategoryId - the parent category id to search with
Throws:
SystemException - if a system exception occurred

removeAll

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

Throws:
SystemException - if a system exception occurred

countByGroupId

int countByGroupId(long groupId)
                   throws SystemException
Counts all the shopping categories where groupId = ?.

Parameters:
groupId - the group id to search with
Returns:
the number of matching shopping categories
Throws:
SystemException - if a system exception occurred

filterCountByGroupId

int filterCountByGroupId(long groupId)
                         throws SystemException
Filters by the user's permissions and counts all the shopping categories where groupId = ?.

Parameters:
groupId - the group id to search with
Returns:
the number of matching shopping categories that the user has permission to view
Throws:
SystemException - if a system exception occurred

countByG_P

int countByG_P(long groupId,
               long parentCategoryId)
               throws SystemException
Counts all the shopping categories where groupId = ? and parentCategoryId = ?.

Parameters:
groupId - the group id to search with
parentCategoryId - the parent category id to search with
Returns:
the number of matching shopping categories
Throws:
SystemException - if a system exception occurred

filterCountByG_P

int filterCountByG_P(long groupId,
                     long parentCategoryId)
                     throws SystemException
Filters by the user's permissions and counts all the shopping categories where groupId = ? and parentCategoryId = ?.

Parameters:
groupId - the group id to search with
parentCategoryId - the parent category id to search with
Returns:
the number of matching shopping categories that the user has permission to view
Throws:
SystemException - if a system exception occurred

countAll

int countAll()
             throws SystemException
Counts all the shopping categories.

Returns:
the number of shopping categories
Throws:
SystemException - if a system exception occurred

Liferay 6.0.5