Liferay 6.0.5

com.liferay.portlet.ratings.service.persistence
Interface RatingsEntryPersistence

All Superinterfaces:
BasePersistence<RatingsEntry>
All Known Implementing Classes:
RatingsEntryPersistenceImpl

public interface RatingsEntryPersistence
extends BasePersistence<RatingsEntry>

The persistence interface for the ratings entry service.

Never modify or reference this interface directly. Always use RatingsEntryUtil to access the ratings entry persistence. Modify service.xml and rerun ServiceBuilder to regenerate this interface.

Caching information and settings can be found in portal.properties

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

Method Summary
 void cacheResult(List<RatingsEntry> ratingsEntries)
          Caches the ratings entries in the entity cache if it is enabled.
 void cacheResult(RatingsEntry ratingsEntry)
          Caches the ratings entry in the entity cache if it is enabled.
 int countAll()
          Counts all the ratings entries.
 int countByC_C(long classNameId, long classPK)
          Counts all the ratings entries where classNameId = ? and classPK = ?.
 int countByU_C_C(long userId, long classNameId, long classPK)
          Counts all the ratings entries where userId = ? and classNameId = ? and classPK = ?.
 RatingsEntry create(long entryId)
          Creates a new ratings entry with the primary key.
 RatingsEntry fetchByPrimaryKey(long entryId)
          Finds the ratings entry with the primary key or returns null if it could not be found.
 RatingsEntry fetchByU_C_C(long userId, long classNameId, long classPK)
          Finds the ratings entry where userId = ? and classNameId = ? and classPK = ? or returns null if it could not be found.
 RatingsEntry fetchByU_C_C(long userId, long classNameId, long classPK, boolean retrieveFromCache)
          Finds the ratings entry where userId = ? and classNameId = ? and classPK = ? or returns null if it could not be found, optionally using the finder cache.
 List<RatingsEntry> findAll()
          Finds all the ratings entries.
 List<RatingsEntry> findAll(int start, int end)
          Finds a range of all the ratings entries.
 List<RatingsEntry> findAll(int start, int end, OrderByComparator orderByComparator)
          Finds an ordered range of all the ratings entries.
 RatingsEntry findByC_C_First(long classNameId, long classPK, OrderByComparator orderByComparator)
          Finds the first ratings entry in the ordered set where classNameId = ? and classPK = ?.
 RatingsEntry findByC_C_Last(long classNameId, long classPK, OrderByComparator orderByComparator)
          Finds the last ratings entry in the ordered set where classNameId = ? and classPK = ?.
 RatingsEntry[] findByC_C_PrevAndNext(long entryId, long classNameId, long classPK, OrderByComparator orderByComparator)
          Finds the ratings entries before and after the current ratings entry in the ordered set where classNameId = ? and classPK = ?.
 List<RatingsEntry> findByC_C(long classNameId, long classPK)
          Finds all the ratings entries where classNameId = ? and classPK = ?.
 List<RatingsEntry> findByC_C(long classNameId, long classPK, int start, int end)
          Finds a range of all the ratings entries where classNameId = ? and classPK = ?.
 List<RatingsEntry> findByC_C(long classNameId, long classPK, int start, int end, OrderByComparator orderByComparator)
          Finds an ordered range of all the ratings entries where classNameId = ? and classPK = ?.
 RatingsEntry findByPrimaryKey(long entryId)
          Finds the ratings entry with the primary key or throws a NoSuchEntryException if it could not be found.
 RatingsEntry findByU_C_C(long userId, long classNameId, long classPK)
          Finds the ratings entry where userId = ? and classNameId = ? and classPK = ? or throws a NoSuchEntryException if it could not be found.
 RatingsEntry remove(long entryId)
          Removes the ratings entry with the primary key from the database.
 void removeAll()
          Removes all the ratings entries from the database.
 void removeByC_C(long classNameId, long classPK)
          Removes all the ratings entries where classNameId = ? and classPK = ? from the database.
 void removeByU_C_C(long userId, long classNameId, long classPK)
          Removes the ratings entry where userId = ? and classNameId = ? and classPK = ? from the database.
 RatingsEntry updateImpl(RatingsEntry ratingsEntry, 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(RatingsEntry ratingsEntry)
Caches the ratings entry in the entity cache if it is enabled.

Parameters:
ratingsEntry - the ratings entry to cache

cacheResult

void cacheResult(List<RatingsEntry> ratingsEntries)
Caches the ratings entries in the entity cache if it is enabled.

Parameters:
ratingsEntries - the ratings entries to cache

create

RatingsEntry create(long entryId)
Creates a new ratings entry with the primary key. Does not add the ratings entry to the database.

Parameters:
entryId - the primary key for the new ratings entry
Returns:
the new ratings entry

remove

RatingsEntry remove(long entryId)
                    throws SystemException,
                           NoSuchEntryException
Removes the ratings entry with the primary key from the database. Also notifies the appropriate model listeners.

Parameters:
entryId - the primary key of the ratings entry to remove
Returns:
the ratings entry that was removed
Throws:
NoSuchEntryException - if a ratings entry with the primary key could not be found
SystemException - if a system exception occurred

updateImpl

RatingsEntry updateImpl(RatingsEntry ratingsEntry,
                        boolean merge)
                        throws SystemException
Throws:
SystemException

findByPrimaryKey

RatingsEntry findByPrimaryKey(long entryId)
                              throws SystemException,
                                     NoSuchEntryException
Finds the ratings entry with the primary key or throws a NoSuchEntryException if it could not be found.

Parameters:
entryId - the primary key of the ratings entry to find
Returns:
the ratings entry
Throws:
NoSuchEntryException - if a ratings entry with the primary key could not be found
SystemException - if a system exception occurred

fetchByPrimaryKey

RatingsEntry fetchByPrimaryKey(long entryId)
                               throws SystemException
Finds the ratings entry with the primary key or returns null if it could not be found.

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

findByC_C

List<RatingsEntry> findByC_C(long classNameId,
                             long classPK)
                             throws SystemException
Finds all the ratings entries where classNameId = ? and classPK = ?.

Parameters:
classNameId - the class name id to search with
classPK - the class p k to search with
Returns:
the matching ratings entries
Throws:
SystemException - if a system exception occurred

findByC_C

List<RatingsEntry> findByC_C(long classNameId,
                             long classPK,
                             int start,
                             int end)
                             throws SystemException
Finds a range of all the ratings entries where classNameId = ? and classPK = ?.

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:
classNameId - the class name id to search with
classPK - the class p k to search with
start - the lower bound of the range of ratings entries to return
end - the upper bound of the range of ratings entries to return (not inclusive)
Returns:
the range of matching ratings entries
Throws:
SystemException - if a system exception occurred

findByC_C

List<RatingsEntry> findByC_C(long classNameId,
                             long classPK,
                             int start,
                             int end,
                             OrderByComparator orderByComparator)
                             throws SystemException
Finds an ordered range of all the ratings entries where classNameId = ? and classPK = ?.

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:
classNameId - the class name id to search with
classPK - the class p k to search with
start - the lower bound of the range of ratings entries to return
end - the upper bound of the range of ratings entries to return (not inclusive)
orderByComparator - the comparator to order the results by
Returns:
the ordered range of matching ratings entries
Throws:
SystemException - if a system exception occurred

findByC_C_First

RatingsEntry findByC_C_First(long classNameId,
                             long classPK,
                             OrderByComparator orderByComparator)
                             throws SystemException,
                                    NoSuchEntryException
Finds the first ratings entry in the ordered set where classNameId = ? and classPK = ?.

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:
classNameId - the class name id to search with
classPK - the class p k to search with
orderByComparator - the comparator to order the set by
Returns:
the first matching ratings entry
Throws:
NoSuchEntryException - if a matching ratings entry could not be found
SystemException - if a system exception occurred

findByC_C_Last

RatingsEntry findByC_C_Last(long classNameId,
                            long classPK,
                            OrderByComparator orderByComparator)
                            throws SystemException,
                                   NoSuchEntryException
Finds the last ratings entry in the ordered set where classNameId = ? and classPK = ?.

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:
classNameId - the class name id to search with
classPK - the class p k to search with
orderByComparator - the comparator to order the set by
Returns:
the last matching ratings entry
Throws:
NoSuchEntryException - if a matching ratings entry could not be found
SystemException - if a system exception occurred

findByC_C_PrevAndNext

RatingsEntry[] findByC_C_PrevAndNext(long entryId,
                                     long classNameId,
                                     long classPK,
                                     OrderByComparator orderByComparator)
                                     throws SystemException,
                                            NoSuchEntryException
Finds the ratings entries before and after the current ratings entry in the ordered set where classNameId = ? and classPK = ?.

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:
entryId - the primary key of the current ratings entry
classNameId - the class name id to search with
classPK - the class p k to search with
orderByComparator - the comparator to order the set by
Returns:
the previous, current, and next ratings entry
Throws:
NoSuchEntryException - if a ratings entry with the primary key could not be found
SystemException - if a system exception occurred

findByU_C_C

RatingsEntry findByU_C_C(long userId,
                         long classNameId,
                         long classPK)
                         throws SystemException,
                                NoSuchEntryException
Finds the ratings entry where userId = ? and classNameId = ? and classPK = ? or throws a NoSuchEntryException if it could not be found.

Parameters:
userId - the user id to search with
classNameId - the class name id to search with
classPK - the class p k to search with
Returns:
the matching ratings entry
Throws:
NoSuchEntryException - if a matching ratings entry could not be found
SystemException - if a system exception occurred

fetchByU_C_C

RatingsEntry fetchByU_C_C(long userId,
                          long classNameId,
                          long classPK)
                          throws SystemException
Finds the ratings entry where userId = ? and classNameId = ? and classPK = ? or returns null if it could not be found. Uses the finder cache.

Parameters:
userId - the user id to search with
classNameId - the class name id to search with
classPK - the class p k to search with
Returns:
the matching ratings entry, or null if a matching ratings entry could not be found
Throws:
SystemException - if a system exception occurred

fetchByU_C_C

RatingsEntry fetchByU_C_C(long userId,
                          long classNameId,
                          long classPK,
                          boolean retrieveFromCache)
                          throws SystemException
Finds the ratings entry where userId = ? and classNameId = ? and classPK = ? or returns null if it could not be found, optionally using the finder cache.

Parameters:
userId - the user id to search with
classNameId - the class name id to search with
classPK - the class p k to search with
Returns:
the matching ratings entry, or null if a matching ratings entry could not be found
Throws:
SystemException - if a system exception occurred

findAll

List<RatingsEntry> findAll()
                           throws SystemException
Finds all the ratings entries.

Returns:
the ratings entries
Throws:
SystemException - if a system exception occurred

findAll

List<RatingsEntry> findAll(int start,
                           int end)
                           throws SystemException
Finds a range of all the ratings entries.

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 ratings entries to return
end - the upper bound of the range of ratings entries to return (not inclusive)
Returns:
the range of ratings entries
Throws:
SystemException - if a system exception occurred

findAll

List<RatingsEntry> findAll(int start,
                           int end,
                           OrderByComparator orderByComparator)
                           throws SystemException
Finds an ordered range of all the ratings entries.

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 ratings entries to return
end - the upper bound of the range of ratings entries to return (not inclusive)
orderByComparator - the comparator to order the results by
Returns:
the ordered range of ratings entries
Throws:
SystemException - if a system exception occurred

removeByC_C

void removeByC_C(long classNameId,
                 long classPK)
                 throws SystemException
Removes all the ratings entries where classNameId = ? and classPK = ? from the database.

Parameters:
classNameId - the class name id to search with
classPK - the class p k to search with
Throws:
SystemException - if a system exception occurred

removeByU_C_C

void removeByU_C_C(long userId,
                   long classNameId,
                   long classPK)
                   throws SystemException,
                          NoSuchEntryException
Removes the ratings entry where userId = ? and classNameId = ? and classPK = ? from the database.

Parameters:
userId - the user id to search with
classNameId - the class name id to search with
classPK - the class p k to search with
Throws:
SystemException - if a system exception occurred
NoSuchEntryException

removeAll

void removeAll()
               throws SystemException
Removes all the ratings entries from the database.

Throws:
SystemException - if a system exception occurred

countByC_C

int countByC_C(long classNameId,
               long classPK)
               throws SystemException
Counts all the ratings entries where classNameId = ? and classPK = ?.

Parameters:
classNameId - the class name id to search with
classPK - the class p k to search with
Returns:
the number of matching ratings entries
Throws:
SystemException - if a system exception occurred

countByU_C_C

int countByU_C_C(long userId,
                 long classNameId,
                 long classPK)
                 throws SystemException
Counts all the ratings entries where userId = ? and classNameId = ? and classPK = ?.

Parameters:
userId - the user id to search with
classNameId - the class name id to search with
classPK - the class p k to search with
Returns:
the number of matching ratings entries
Throws:
SystemException - if a system exception occurred

countAll

int countAll()
             throws SystemException
Counts all the ratings entries.

Returns:
the number of ratings entries
Throws:
SystemException - if a system exception occurred

Liferay 6.0.5