Liferay 6.0.5

com.liferay.portal.service.persistence
Class PortletPreferencesUtil

java.lang.Object
  extended by com.liferay.portal.service.persistence.PortletPreferencesUtil

public class PortletPreferencesUtil
extends Object

The persistence utility for the portlet preferences service. This utility wraps PortletPreferencesPersistenceImpl and provides direct access to the database for CRUD operations. This utility should only be used by the service layer, as it must operate within a transaction. Never access this utility in a JSP, controller, model, or other front-end class.

Never modify this class directly. Modify service.xml and rerun ServiceBuilder to regenerate this class.

Caching information and settings can be found in portal.properties

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

Constructor Summary
PortletPreferencesUtil()
           
 
Method Summary
static void cacheResult(List<PortletPreferences> portletPreferenceses)
          Caches the portlet preferenceses in the entity cache if it is enabled.
static void cacheResult(PortletPreferences portletPreferences)
          Caches the portlet preferences in the entity cache if it is enabled.
static void clearCache()
           
static void clearCache(PortletPreferences portletPreferences)
           
static int countAll()
          Counts all the portlet preferenceses.
static int countByO_O_P_P(long ownerId, int ownerType, long plid, String portletId)
          Counts all the portlet preferenceses where ownerId = ? and ownerType = ? and plid = ? and portletId = ?.
static int countByO_O_P(long ownerId, int ownerType, long plid)
          Counts all the portlet preferenceses where ownerId = ? and ownerType = ? and plid = ?.
static int countByP_P(long plid, String portletId)
          Counts all the portlet preferenceses where plid = ? and portletId = ?.
static int countByPlid(long plid)
          Counts all the portlet preferenceses where plid = ?.
 long countWithDynamicQuery(DynamicQuery dynamicQuery)
           
static PortletPreferences create(long portletPreferencesId)
          Creates a new portlet preferences with the primary key.
static PortletPreferences fetchByO_O_P_P(long ownerId, int ownerType, long plid, String portletId)
          Finds the portlet preferences where ownerId = ? and ownerType = ? and plid = ? and portletId = ? or returns null if it could not be found.
static PortletPreferences fetchByO_O_P_P(long ownerId, int ownerType, long plid, String portletId, boolean retrieveFromCache)
          Finds the portlet preferences where ownerId = ? and ownerType = ? and plid = ? and portletId = ? or returns null if it could not be found, optionally using the finder cache.
static PortletPreferences fetchByPrimaryKey(long portletPreferencesId)
          Finds the portlet preferences with the primary key or returns null if it could not be found.
static List<PortletPreferences> findAll()
          Finds all the portlet preferenceses.
static List<PortletPreferences> findAll(int start, int end)
          Finds a range of all the portlet preferenceses.
static List<PortletPreferences> findAll(int start, int end, OrderByComparator orderByComparator)
          Finds an ordered range of all the portlet preferenceses.
static PortletPreferences findByO_O_P_First(long ownerId, int ownerType, long plid, OrderByComparator orderByComparator)
          Finds the first portlet preferences in the ordered set where ownerId = ? and ownerType = ? and plid = ?.
static PortletPreferences findByO_O_P_Last(long ownerId, int ownerType, long plid, OrderByComparator orderByComparator)
          Finds the last portlet preferences in the ordered set where ownerId = ? and ownerType = ? and plid = ?.
static PortletPreferences findByO_O_P_P(long ownerId, int ownerType, long plid, String portletId)
          Finds the portlet preferences where ownerId = ? and ownerType = ? and plid = ? and portletId = ? or throws a NoSuchPortletPreferencesException if it could not be found.
static PortletPreferences[] findByO_O_P_PrevAndNext(long portletPreferencesId, long ownerId, int ownerType, long plid, OrderByComparator orderByComparator)
          Finds the portlet preferenceses before and after the current portlet preferences in the ordered set where ownerId = ? and ownerType = ? and plid = ?.
static List<PortletPreferences> findByO_O_P(long ownerId, int ownerType, long plid)
          Finds all the portlet preferenceses where ownerId = ? and ownerType = ? and plid = ?.
static List<PortletPreferences> findByO_O_P(long ownerId, int ownerType, long plid, int start, int end)
          Finds a range of all the portlet preferenceses where ownerId = ? and ownerType = ? and plid = ?.
static List<PortletPreferences> findByO_O_P(long ownerId, int ownerType, long plid, int start, int end, OrderByComparator orderByComparator)
          Finds an ordered range of all the portlet preferenceses where ownerId = ? and ownerType = ? and plid = ?.
static PortletPreferences findByP_P_First(long plid, String portletId, OrderByComparator orderByComparator)
          Finds the first portlet preferences in the ordered set where plid = ? and portletId = ?.
static PortletPreferences findByP_P_Last(long plid, String portletId, OrderByComparator orderByComparator)
          Finds the last portlet preferences in the ordered set where plid = ? and portletId = ?.
static PortletPreferences[] findByP_P_PrevAndNext(long portletPreferencesId, long plid, String portletId, OrderByComparator orderByComparator)
          Finds the portlet preferenceses before and after the current portlet preferences in the ordered set where plid = ? and portletId = ?.
static List<PortletPreferences> findByP_P(long plid, String portletId)
          Finds all the portlet preferenceses where plid = ? and portletId = ?.
static List<PortletPreferences> findByP_P(long plid, String portletId, int start, int end)
          Finds a range of all the portlet preferenceses where plid = ? and portletId = ?.
static List<PortletPreferences> findByP_P(long plid, String portletId, int start, int end, OrderByComparator orderByComparator)
          Finds an ordered range of all the portlet preferenceses where plid = ? and portletId = ?.
static PortletPreferences findByPlid_First(long plid, OrderByComparator orderByComparator)
          Finds the first portlet preferences in the ordered set where plid = ?.
static PortletPreferences findByPlid_Last(long plid, OrderByComparator orderByComparator)
          Finds the last portlet preferences in the ordered set where plid = ?.
static PortletPreferences[] findByPlid_PrevAndNext(long portletPreferencesId, long plid, OrderByComparator orderByComparator)
          Finds the portlet preferenceses before and after the current portlet preferences in the ordered set where plid = ?.
static List<PortletPreferences> findByPlid(long plid)
          Finds all the portlet preferenceses where plid = ?.
static List<PortletPreferences> findByPlid(long plid, int start, int end)
          Finds a range of all the portlet preferenceses where plid = ?.
static List<PortletPreferences> findByPlid(long plid, int start, int end, OrderByComparator orderByComparator)
          Finds an ordered range of all the portlet preferenceses where plid = ?.
static PortletPreferences findByPrimaryKey(long portletPreferencesId)
          Finds the portlet preferences with the primary key or throws a NoSuchPortletPreferencesException if it could not be found.
static List<PortletPreferences> findWithDynamicQuery(DynamicQuery dynamicQuery)
           
static List<PortletPreferences> findWithDynamicQuery(DynamicQuery dynamicQuery, int start, int end)
           
static List<PortletPreferences> findWithDynamicQuery(DynamicQuery dynamicQuery, int start, int end, OrderByComparator orderByComparator)
           
static PortletPreferencesPersistence getPersistence()
           
static PortletPreferences remove(long portletPreferencesId)
          Removes the portlet preferences with the primary key from the database.
static PortletPreferences remove(PortletPreferences portletPreferences)
           
static void removeAll()
          Removes all the portlet preferenceses from the database.
static void removeByO_O_P_P(long ownerId, int ownerType, long plid, String portletId)
          Removes the portlet preferences where ownerId = ? and ownerType = ? and plid = ? and portletId = ? from the database.
static void removeByO_O_P(long ownerId, int ownerType, long plid)
          Removes all the portlet preferenceses where ownerId = ? and ownerType = ? and plid = ? from the database.
static void removeByP_P(long plid, String portletId)
          Removes all the portlet preferenceses where plid = ? and portletId = ? from the database.
static void removeByPlid(long plid)
          Removes all the portlet preferenceses where plid = ? from the database.
 void setPersistence(PortletPreferencesPersistence persistence)
           
static PortletPreferences update(PortletPreferences portletPreferences, boolean merge)
           
static PortletPreferences update(PortletPreferences portletPreferences, boolean merge, ServiceContext serviceContext)
           
static PortletPreferences updateImpl(PortletPreferences portletPreferences, boolean merge)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PortletPreferencesUtil

public PortletPreferencesUtil()
Method Detail

clearCache

public static void clearCache()
See Also:
BasePersistence.clearCache()

clearCache

public static void clearCache(PortletPreferences portletPreferences)
See Also:
BasePersistence.clearCache(com.liferay.portal.model.BaseModel)

countWithDynamicQuery

public long countWithDynamicQuery(DynamicQuery dynamicQuery)
                           throws SystemException
Throws:
SystemException
See Also:
BasePersistence.countWithDynamicQuery(DynamicQuery)

findWithDynamicQuery

public static List<PortletPreferences> findWithDynamicQuery(DynamicQuery dynamicQuery)
                                                     throws SystemException
Throws:
SystemException
See Also:
BasePersistence.findWithDynamicQuery(DynamicQuery)

findWithDynamicQuery

public static List<PortletPreferences> findWithDynamicQuery(DynamicQuery dynamicQuery,
                                                            int start,
                                                            int end)
                                                     throws SystemException
Throws:
SystemException
See Also:
BasePersistence.findWithDynamicQuery(DynamicQuery, int, int)

findWithDynamicQuery

public static List<PortletPreferences> findWithDynamicQuery(DynamicQuery dynamicQuery,
                                                            int start,
                                                            int end,
                                                            OrderByComparator orderByComparator)
                                                     throws SystemException
Throws:
SystemException
See Also:
BasePersistence.findWithDynamicQuery(DynamicQuery, int, int, OrderByComparator)

remove

public static PortletPreferences remove(PortletPreferences portletPreferences)
                                 throws SystemException
Throws:
SystemException
See Also:
BasePersistence.remove(com.liferay.portal.model.BaseModel)

update

public static PortletPreferences update(PortletPreferences portletPreferences,
                                        boolean merge)
                                 throws SystemException
Throws:
SystemException
See Also:
BasePersistence.update(com.liferay.portal.model.BaseModel, boolean)

update

public static PortletPreferences update(PortletPreferences portletPreferences,
                                        boolean merge,
                                        ServiceContext serviceContext)
                                 throws SystemException
Throws:
SystemException
See Also:
BasePersistence.update(com.liferay.portal.model.BaseModel, boolean, ServiceContext)

cacheResult

public static void cacheResult(PortletPreferences portletPreferences)
Caches the portlet preferences in the entity cache if it is enabled.

Parameters:
portletPreferences - the portlet preferences to cache

cacheResult

public static void cacheResult(List<PortletPreferences> portletPreferenceses)
Caches the portlet preferenceses in the entity cache if it is enabled.

Parameters:
portletPreferenceses - the portlet preferenceses to cache

create

public static PortletPreferences create(long portletPreferencesId)
Creates a new portlet preferences with the primary key. Does not add the portlet preferences to the database.

Parameters:
portletPreferencesId - the primary key for the new portlet preferences
Returns:
the new portlet preferences

remove

public static PortletPreferences remove(long portletPreferencesId)
                                 throws NoSuchPortletPreferencesException,
                                        SystemException
Removes the portlet preferences with the primary key from the database. Also notifies the appropriate model listeners.

Parameters:
portletPreferencesId - the primary key of the portlet preferences to remove
Returns:
the portlet preferences that was removed
Throws:
NoSuchPortletPreferencesException - if a portlet preferences with the primary key could not be found
SystemException - if a system exception occurred

updateImpl

public static PortletPreferences updateImpl(PortletPreferences portletPreferences,
                                            boolean merge)
                                     throws SystemException
Throws:
SystemException

findByPrimaryKey

public static PortletPreferences findByPrimaryKey(long portletPreferencesId)
                                           throws NoSuchPortletPreferencesException,
                                                  SystemException
Finds the portlet preferences with the primary key or throws a NoSuchPortletPreferencesException if it could not be found.

Parameters:
portletPreferencesId - the primary key of the portlet preferences to find
Returns:
the portlet preferences
Throws:
NoSuchPortletPreferencesException - if a portlet preferences with the primary key could not be found
SystemException - if a system exception occurred

fetchByPrimaryKey

public static PortletPreferences fetchByPrimaryKey(long portletPreferencesId)
                                            throws SystemException
Finds the portlet preferences with the primary key or returns null if it could not be found.

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

findByPlid

public static List<PortletPreferences> findByPlid(long plid)
                                           throws SystemException
Finds all the portlet preferenceses where plid = ?.

Parameters:
plid - the plid to search with
Returns:
the matching portlet preferenceses
Throws:
SystemException - if a system exception occurred

findByPlid

public static List<PortletPreferences> findByPlid(long plid,
                                                  int start,
                                                  int end)
                                           throws SystemException
Finds a range of all the portlet preferenceses where plid = ?.

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:
plid - the plid to search with
start - the lower bound of the range of portlet preferenceses to return
end - the upper bound of the range of portlet preferenceses to return (not inclusive)
Returns:
the range of matching portlet preferenceses
Throws:
SystemException - if a system exception occurred

findByPlid

public static List<PortletPreferences> findByPlid(long plid,
                                                  int start,
                                                  int end,
                                                  OrderByComparator orderByComparator)
                                           throws SystemException
Finds an ordered range of all the portlet preferenceses where plid = ?.

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:
plid - the plid to search with
start - the lower bound of the range of portlet preferenceses to return
end - the upper bound of the range of portlet preferenceses to return (not inclusive)
orderByComparator - the comparator to order the results by
Returns:
the ordered range of matching portlet preferenceses
Throws:
SystemException - if a system exception occurred

findByPlid_First

public static PortletPreferences findByPlid_First(long plid,
                                                  OrderByComparator orderByComparator)
                                           throws NoSuchPortletPreferencesException,
                                                  SystemException
Finds the first portlet preferences in the ordered set where plid = ?.

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:
plid - the plid to search with
orderByComparator - the comparator to order the set by
Returns:
the first matching portlet preferences
Throws:
NoSuchPortletPreferencesException - if a matching portlet preferences could not be found
SystemException - if a system exception occurred

findByPlid_Last

public static PortletPreferences findByPlid_Last(long plid,
                                                 OrderByComparator orderByComparator)
                                          throws NoSuchPortletPreferencesException,
                                                 SystemException
Finds the last portlet preferences in the ordered set where plid = ?.

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:
plid - the plid to search with
orderByComparator - the comparator to order the set by
Returns:
the last matching portlet preferences
Throws:
NoSuchPortletPreferencesException - if a matching portlet preferences could not be found
SystemException - if a system exception occurred

findByPlid_PrevAndNext

public static PortletPreferences[] findByPlid_PrevAndNext(long portletPreferencesId,
                                                          long plid,
                                                          OrderByComparator orderByComparator)
                                                   throws NoSuchPortletPreferencesException,
                                                          SystemException
Finds the portlet preferenceses before and after the current portlet preferences in the ordered set where plid = ?.

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:
portletPreferencesId - the primary key of the current portlet preferences
plid - the plid to search with
orderByComparator - the comparator to order the set by
Returns:
the previous, current, and next portlet preferences
Throws:
NoSuchPortletPreferencesException - if a portlet preferences with the primary key could not be found
SystemException - if a system exception occurred

findByP_P

public static List<PortletPreferences> findByP_P(long plid,
                                                 String portletId)
                                          throws SystemException
Finds all the portlet preferenceses where plid = ? and portletId = ?.

Parameters:
plid - the plid to search with
portletId - the portlet id to search with
Returns:
the matching portlet preferenceses
Throws:
SystemException - if a system exception occurred

findByP_P

public static List<PortletPreferences> findByP_P(long plid,
                                                 String portletId,
                                                 int start,
                                                 int end)
                                          throws SystemException
Finds a range of all the portlet preferenceses where plid = ? and portletId = ?.

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:
plid - the plid to search with
portletId - the portlet id to search with
start - the lower bound of the range of portlet preferenceses to return
end - the upper bound of the range of portlet preferenceses to return (not inclusive)
Returns:
the range of matching portlet preferenceses
Throws:
SystemException - if a system exception occurred

findByP_P

public static List<PortletPreferences> findByP_P(long plid,
                                                 String portletId,
                                                 int start,
                                                 int end,
                                                 OrderByComparator orderByComparator)
                                          throws SystemException
Finds an ordered range of all the portlet preferenceses where plid = ? and portletId = ?.

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:
plid - the plid to search with
portletId - the portlet id to search with
start - the lower bound of the range of portlet preferenceses to return
end - the upper bound of the range of portlet preferenceses to return (not inclusive)
orderByComparator - the comparator to order the results by
Returns:
the ordered range of matching portlet preferenceses
Throws:
SystemException - if a system exception occurred

findByP_P_First

public static PortletPreferences findByP_P_First(long plid,
                                                 String portletId,
                                                 OrderByComparator orderByComparator)
                                          throws NoSuchPortletPreferencesException,
                                                 SystemException
Finds the first portlet preferences in the ordered set where plid = ? and portletId = ?.

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:
plid - the plid to search with
portletId - the portlet id to search with
orderByComparator - the comparator to order the set by
Returns:
the first matching portlet preferences
Throws:
NoSuchPortletPreferencesException - if a matching portlet preferences could not be found
SystemException - if a system exception occurred

findByP_P_Last

public static PortletPreferences findByP_P_Last(long plid,
                                                String portletId,
                                                OrderByComparator orderByComparator)
                                         throws NoSuchPortletPreferencesException,
                                                SystemException
Finds the last portlet preferences in the ordered set where plid = ? and portletId = ?.

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:
plid - the plid to search with
portletId - the portlet id to search with
orderByComparator - the comparator to order the set by
Returns:
the last matching portlet preferences
Throws:
NoSuchPortletPreferencesException - if a matching portlet preferences could not be found
SystemException - if a system exception occurred

findByP_P_PrevAndNext

public static PortletPreferences[] findByP_P_PrevAndNext(long portletPreferencesId,
                                                         long plid,
                                                         String portletId,
                                                         OrderByComparator orderByComparator)
                                                  throws NoSuchPortletPreferencesException,
                                                         SystemException
Finds the portlet preferenceses before and after the current portlet preferences in the ordered set where plid = ? and portletId = ?.

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:
portletPreferencesId - the primary key of the current portlet preferences
plid - the plid to search with
portletId - the portlet id to search with
orderByComparator - the comparator to order the set by
Returns:
the previous, current, and next portlet preferences
Throws:
NoSuchPortletPreferencesException - if a portlet preferences with the primary key could not be found
SystemException - if a system exception occurred

findByO_O_P

public static List<PortletPreferences> findByO_O_P(long ownerId,
                                                   int ownerType,
                                                   long plid)
                                            throws SystemException
Finds all the portlet preferenceses where ownerId = ? and ownerType = ? and plid = ?.

Parameters:
ownerId - the owner id to search with
ownerType - the owner type to search with
plid - the plid to search with
Returns:
the matching portlet preferenceses
Throws:
SystemException - if a system exception occurred

findByO_O_P

public static List<PortletPreferences> findByO_O_P(long ownerId,
                                                   int ownerType,
                                                   long plid,
                                                   int start,
                                                   int end)
                                            throws SystemException
Finds a range of all the portlet preferenceses where ownerId = ? and ownerType = ? and plid = ?.

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:
ownerId - the owner id to search with
ownerType - the owner type to search with
plid - the plid to search with
start - the lower bound of the range of portlet preferenceses to return
end - the upper bound of the range of portlet preferenceses to return (not inclusive)
Returns:
the range of matching portlet preferenceses
Throws:
SystemException - if a system exception occurred

findByO_O_P

public static List<PortletPreferences> findByO_O_P(long ownerId,
                                                   int ownerType,
                                                   long plid,
                                                   int start,
                                                   int end,
                                                   OrderByComparator orderByComparator)
                                            throws SystemException
Finds an ordered range of all the portlet preferenceses where ownerId = ? and ownerType = ? and plid = ?.

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:
ownerId - the owner id to search with
ownerType - the owner type to search with
plid - the plid to search with
start - the lower bound of the range of portlet preferenceses to return
end - the upper bound of the range of portlet preferenceses to return (not inclusive)
orderByComparator - the comparator to order the results by
Returns:
the ordered range of matching portlet preferenceses
Throws:
SystemException - if a system exception occurred

findByO_O_P_First

public static PortletPreferences findByO_O_P_First(long ownerId,
                                                   int ownerType,
                                                   long plid,
                                                   OrderByComparator orderByComparator)
                                            throws NoSuchPortletPreferencesException,
                                                   SystemException
Finds the first portlet preferences in the ordered set where ownerId = ? and ownerType = ? and plid = ?.

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:
ownerId - the owner id to search with
ownerType - the owner type to search with
plid - the plid to search with
orderByComparator - the comparator to order the set by
Returns:
the first matching portlet preferences
Throws:
NoSuchPortletPreferencesException - if a matching portlet preferences could not be found
SystemException - if a system exception occurred

findByO_O_P_Last

public static PortletPreferences findByO_O_P_Last(long ownerId,
                                                  int ownerType,
                                                  long plid,
                                                  OrderByComparator orderByComparator)
                                           throws NoSuchPortletPreferencesException,
                                                  SystemException
Finds the last portlet preferences in the ordered set where ownerId = ? and ownerType = ? and plid = ?.

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:
ownerId - the owner id to search with
ownerType - the owner type to search with
plid - the plid to search with
orderByComparator - the comparator to order the set by
Returns:
the last matching portlet preferences
Throws:
NoSuchPortletPreferencesException - if a matching portlet preferences could not be found
SystemException - if a system exception occurred

findByO_O_P_PrevAndNext

public static PortletPreferences[] findByO_O_P_PrevAndNext(long portletPreferencesId,
                                                           long ownerId,
                                                           int ownerType,
                                                           long plid,
                                                           OrderByComparator orderByComparator)
                                                    throws NoSuchPortletPreferencesException,
                                                           SystemException
Finds the portlet preferenceses before and after the current portlet preferences in the ordered set where ownerId = ? and ownerType = ? and plid = ?.

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:
portletPreferencesId - the primary key of the current portlet preferences
ownerId - the owner id to search with
ownerType - the owner type to search with
plid - the plid to search with
orderByComparator - the comparator to order the set by
Returns:
the previous, current, and next portlet preferences
Throws:
NoSuchPortletPreferencesException - if a portlet preferences with the primary key could not be found
SystemException - if a system exception occurred

findByO_O_P_P

public static PortletPreferences findByO_O_P_P(long ownerId,
                                               int ownerType,
                                               long plid,
                                               String portletId)
                                        throws NoSuchPortletPreferencesException,
                                               SystemException
Finds the portlet preferences where ownerId = ? and ownerType = ? and plid = ? and portletId = ? or throws a NoSuchPortletPreferencesException if it could not be found.

Parameters:
ownerId - the owner id to search with
ownerType - the owner type to search with
plid - the plid to search with
portletId - the portlet id to search with
Returns:
the matching portlet preferences
Throws:
NoSuchPortletPreferencesException - if a matching portlet preferences could not be found
SystemException - if a system exception occurred

fetchByO_O_P_P

public static PortletPreferences fetchByO_O_P_P(long ownerId,
                                                int ownerType,
                                                long plid,
                                                String portletId)
                                         throws SystemException
Finds the portlet preferences where ownerId = ? and ownerType = ? and plid = ? and portletId = ? or returns null if it could not be found. Uses the finder cache.

Parameters:
ownerId - the owner id to search with
ownerType - the owner type to search with
plid - the plid to search with
portletId - the portlet id to search with
Returns:
the matching portlet preferences, or null if a matching portlet preferences could not be found
Throws:
SystemException - if a system exception occurred

fetchByO_O_P_P

public static PortletPreferences fetchByO_O_P_P(long ownerId,
                                                int ownerType,
                                                long plid,
                                                String portletId,
                                                boolean retrieveFromCache)
                                         throws SystemException
Finds the portlet preferences where ownerId = ? and ownerType = ? and plid = ? and portletId = ? or returns null if it could not be found, optionally using the finder cache.

Parameters:
ownerId - the owner id to search with
ownerType - the owner type to search with
plid - the plid to search with
portletId - the portlet id to search with
Returns:
the matching portlet preferences, or null if a matching portlet preferences could not be found
Throws:
SystemException - if a system exception occurred

findAll

public static List<PortletPreferences> findAll()
                                        throws SystemException
Finds all the portlet preferenceses.

Returns:
the portlet preferenceses
Throws:
SystemException - if a system exception occurred

findAll

public static List<PortletPreferences> findAll(int start,
                                               int end)
                                        throws SystemException
Finds a range of all the portlet preferenceses.

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

findAll

public static List<PortletPreferences> findAll(int start,
                                               int end,
                                               OrderByComparator orderByComparator)
                                        throws SystemException
Finds an ordered range of all the portlet preferenceses.

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

removeByPlid

public static void removeByPlid(long plid)
                         throws SystemException
Removes all the portlet preferenceses where plid = ? from the database.

Parameters:
plid - the plid to search with
Throws:
SystemException - if a system exception occurred

removeByP_P

public static void removeByP_P(long plid,
                               String portletId)
                        throws SystemException
Removes all the portlet preferenceses where plid = ? and portletId = ? from the database.

Parameters:
plid - the plid to search with
portletId - the portlet id to search with
Throws:
SystemException - if a system exception occurred

removeByO_O_P

public static void removeByO_O_P(long ownerId,
                                 int ownerType,
                                 long plid)
                          throws SystemException
Removes all the portlet preferenceses where ownerId = ? and ownerType = ? and plid = ? from the database.

Parameters:
ownerId - the owner id to search with
ownerType - the owner type to search with
plid - the plid to search with
Throws:
SystemException - if a system exception occurred

removeByO_O_P_P

public static void removeByO_O_P_P(long ownerId,
                                   int ownerType,
                                   long plid,
                                   String portletId)
                            throws NoSuchPortletPreferencesException,
                                   SystemException
Removes the portlet preferences where ownerId = ? and ownerType = ? and plid = ? and portletId = ? from the database.

Parameters:
ownerId - the owner id to search with
ownerType - the owner type to search with
plid - the plid to search with
portletId - the portlet id to search with
Throws:
SystemException - if a system exception occurred
NoSuchPortletPreferencesException

removeAll

public static void removeAll()
                      throws SystemException
Removes all the portlet preferenceses from the database.

Throws:
SystemException - if a system exception occurred

countByPlid

public static int countByPlid(long plid)
                       throws SystemException
Counts all the portlet preferenceses where plid = ?.

Parameters:
plid - the plid to search with
Returns:
the number of matching portlet preferenceses
Throws:
SystemException - if a system exception occurred

countByP_P

public static int countByP_P(long plid,
                             String portletId)
                      throws SystemException
Counts all the portlet preferenceses where plid = ? and portletId = ?.

Parameters:
plid - the plid to search with
portletId - the portlet id to search with
Returns:
the number of matching portlet preferenceses
Throws:
SystemException - if a system exception occurred

countByO_O_P

public static int countByO_O_P(long ownerId,
                               int ownerType,
                               long plid)
                        throws SystemException
Counts all the portlet preferenceses where ownerId = ? and ownerType = ? and plid = ?.

Parameters:
ownerId - the owner id to search with
ownerType - the owner type to search with
plid - the plid to search with
Returns:
the number of matching portlet preferenceses
Throws:
SystemException - if a system exception occurred

countByO_O_P_P

public static int countByO_O_P_P(long ownerId,
                                 int ownerType,
                                 long plid,
                                 String portletId)
                          throws SystemException
Counts all the portlet preferenceses where ownerId = ? and ownerType = ? and plid = ? and portletId = ?.

Parameters:
ownerId - the owner id to search with
ownerType - the owner type to search with
plid - the plid to search with
portletId - the portlet id to search with
Returns:
the number of matching portlet preferenceses
Throws:
SystemException - if a system exception occurred

countAll

public static int countAll()
                    throws SystemException
Counts all the portlet preferenceses.

Returns:
the number of portlet preferenceses
Throws:
SystemException - if a system exception occurred

getPersistence

public static PortletPreferencesPersistence getPersistence()

setPersistence

public void setPersistence(PortletPreferencesPersistence persistence)

Liferay 6.0.5