@ProviderType
public class SubscriptionUtil
extends Object
SubscriptionPersistenceImpl
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.
Caching information and settings can be found in portal.properties
SubscriptionPersistence
,
SubscriptionPersistenceImpl
Constructor and Description |
---|
SubscriptionUtil() |
Modifier and Type | Method and Description |
---|---|
static void |
cacheResult(List<Subscription> subscriptions)
Caches the subscriptions in the entity cache if it is enabled.
|
static void |
cacheResult(Subscription subscription)
Caches the subscription in the entity cache if it is enabled.
|
static void |
clearCache() |
static void |
clearCache(Subscription subscription) |
static int |
countAll()
Returns the number of subscriptions.
|
static int |
countByC_C_C(long companyId,
long classNameId,
long classPK)
Returns the number of subscriptions where companyId = ? and classNameId = ? and classPK = ?.
|
static int |
countByC_U_C_C(long companyId,
long userId,
long classNameId,
long classPK)
Returns the number of subscriptions where companyId = ? and userId = ? and classNameId = ? and classPK = ?.
|
static int |
countByC_U_C_C(long companyId,
long userId,
long classNameId,
long[] classPKs)
Returns the number of subscriptions where companyId = ? and userId = ? and classNameId = ? and classPK = any ?.
|
static int |
countByG_U(long groupId,
long userId)
Returns the number of subscriptions where groupId = ? and userId = ?.
|
static int |
countByU_C(long userId,
long classNameId)
Returns the number of subscriptions where userId = ? and classNameId = ?.
|
static int |
countByUserId(long userId)
Returns the number of subscriptions where userId = ?.
|
static long |
countWithDynamicQuery(DynamicQuery dynamicQuery) |
static Subscription |
create(long subscriptionId)
Creates a new subscription with the primary key.
|
static Subscription |
fetchByC_C_C_First(long companyId,
long classNameId,
long classPK,
OrderByComparator<Subscription> orderByComparator)
Returns the first subscription in the ordered set where companyId = ? and classNameId = ? and classPK = ?.
|
static Subscription |
fetchByC_C_C_Last(long companyId,
long classNameId,
long classPK,
OrderByComparator<Subscription> orderByComparator)
Returns the last subscription in the ordered set where companyId = ? and classNameId = ? and classPK = ?.
|
static Subscription |
fetchByC_U_C_C(long companyId,
long userId,
long classNameId,
long classPK)
Returns the subscription where companyId = ? and userId = ? and classNameId = ? and classPK = ? or returns
null if it could not be found. |
static Subscription |
fetchByC_U_C_C(long companyId,
long userId,
long classNameId,
long classPK,
boolean retrieveFromCache)
Returns the subscription where companyId = ? and userId = ? and classNameId = ? and classPK = ? or returns
null if it could not be found, optionally using the finder cache. |
static Subscription |
fetchByG_U_First(long groupId,
long userId,
OrderByComparator<Subscription> orderByComparator)
Returns the first subscription in the ordered set where groupId = ? and userId = ?.
|
static Subscription |
fetchByG_U_Last(long groupId,
long userId,
OrderByComparator<Subscription> orderByComparator)
Returns the last subscription in the ordered set where groupId = ? and userId = ?.
|
static Subscription |
fetchByPrimaryKey(long subscriptionId)
Returns the subscription with the primary key or returns
null if it could not be found. |
static Map<Serializable,Subscription> |
fetchByPrimaryKeys(Set<Serializable> primaryKeys) |
static Subscription |
fetchByU_C_First(long userId,
long classNameId,
OrderByComparator<Subscription> orderByComparator)
Returns the first subscription in the ordered set where userId = ? and classNameId = ?.
|
static Subscription |
fetchByU_C_Last(long userId,
long classNameId,
OrderByComparator<Subscription> orderByComparator)
Returns the last subscription in the ordered set where userId = ? and classNameId = ?.
|
static Subscription |
fetchByUserId_First(long userId,
OrderByComparator<Subscription> orderByComparator)
Returns the first subscription in the ordered set where userId = ?.
|
static Subscription |
fetchByUserId_Last(long userId,
OrderByComparator<Subscription> orderByComparator)
Returns the last subscription in the ordered set where userId = ?.
|
static List<Subscription> |
findAll()
Returns all the subscriptions.
|
static List<Subscription> |
findAll(int start,
int end)
Returns a range of all the subscriptions.
|
static List<Subscription> |
findAll(int start,
int end,
OrderByComparator<Subscription> orderByComparator)
Returns an ordered range of all the subscriptions.
|
static List<Subscription> |
findAll(int start,
int end,
OrderByComparator<Subscription> orderByComparator,
boolean retrieveFromCache)
Returns an ordered range of all the subscriptions.
|
static Subscription |
findByC_C_C_First(long companyId,
long classNameId,
long classPK,
OrderByComparator<Subscription> orderByComparator)
Returns the first subscription in the ordered set where companyId = ? and classNameId = ? and classPK = ?.
|
static Subscription |
findByC_C_C_Last(long companyId,
long classNameId,
long classPK,
OrderByComparator<Subscription> orderByComparator)
Returns the last subscription in the ordered set where companyId = ? and classNameId = ? and classPK = ?.
|
static Subscription[] |
findByC_C_C_PrevAndNext(long subscriptionId,
long companyId,
long classNameId,
long classPK,
OrderByComparator<Subscription> orderByComparator)
Returns the subscriptions before and after the current subscription in the ordered set where companyId = ? and classNameId = ? and classPK = ?.
|
static List<Subscription> |
findByC_C_C(long companyId,
long classNameId,
long classPK)
Returns all the subscriptions where companyId = ? and classNameId = ? and classPK = ?.
|
static List<Subscription> |
findByC_C_C(long companyId,
long classNameId,
long classPK,
int start,
int end)
Returns a range of all the subscriptions where companyId = ? and classNameId = ? and classPK = ?.
|
static List<Subscription> |
findByC_C_C(long companyId,
long classNameId,
long classPK,
int start,
int end,
OrderByComparator<Subscription> orderByComparator)
Returns an ordered range of all the subscriptions where companyId = ? and classNameId = ? and classPK = ?.
|
static List<Subscription> |
findByC_C_C(long companyId,
long classNameId,
long classPK,
int start,
int end,
OrderByComparator<Subscription> orderByComparator,
boolean retrieveFromCache)
Returns an ordered range of all the subscriptions where companyId = ? and classNameId = ? and classPK = ?.
|
static Subscription |
findByC_U_C_C(long companyId,
long userId,
long classNameId,
long classPK)
Returns the subscription where companyId = ? and userId = ? and classNameId = ? and classPK = ? or throws a
NoSuchSubscriptionException if it could not be found. |
static List<Subscription> |
findByC_U_C_C(long companyId,
long userId,
long classNameId,
long[] classPKs)
Returns all the subscriptions where companyId = ? and userId = ? and classNameId = ? and classPK = any ?.
|
static List<Subscription> |
findByC_U_C_C(long companyId,
long userId,
long classNameId,
long[] classPKs,
int start,
int end)
Returns a range of all the subscriptions where companyId = ? and userId = ? and classNameId = ? and classPK = any ?.
|
static List<Subscription> |
findByC_U_C_C(long companyId,
long userId,
long classNameId,
long[] classPKs,
int start,
int end,
OrderByComparator<Subscription> orderByComparator)
Returns an ordered range of all the subscriptions where companyId = ? and userId = ? and classNameId = ? and classPK = any ?.
|
static List<Subscription> |
findByC_U_C_C(long companyId,
long userId,
long classNameId,
long[] classPKs,
int start,
int end,
OrderByComparator<Subscription> orderByComparator,
boolean retrieveFromCache)
Returns an ordered range of all the subscriptions where companyId = ? and userId = ? and classNameId = ? and classPK = ?, optionally using the finder cache.
|
static Subscription |
findByG_U_First(long groupId,
long userId,
OrderByComparator<Subscription> orderByComparator)
Returns the first subscription in the ordered set where groupId = ? and userId = ?.
|
static Subscription |
findByG_U_Last(long groupId,
long userId,
OrderByComparator<Subscription> orderByComparator)
Returns the last subscription in the ordered set where groupId = ? and userId = ?.
|
static Subscription[] |
findByG_U_PrevAndNext(long subscriptionId,
long groupId,
long userId,
OrderByComparator<Subscription> orderByComparator)
Returns the subscriptions before and after the current subscription in the ordered set where groupId = ? and userId = ?.
|
static List<Subscription> |
findByG_U(long groupId,
long userId)
Returns all the subscriptions where groupId = ? and userId = ?.
|
static List<Subscription> |
findByG_U(long groupId,
long userId,
int start,
int end)
Returns a range of all the subscriptions where groupId = ? and userId = ?.
|
static List<Subscription> |
findByG_U(long groupId,
long userId,
int start,
int end,
OrderByComparator<Subscription> orderByComparator)
Returns an ordered range of all the subscriptions where groupId = ? and userId = ?.
|
static List<Subscription> |
findByG_U(long groupId,
long userId,
int start,
int end,
OrderByComparator<Subscription> orderByComparator,
boolean retrieveFromCache)
Returns an ordered range of all the subscriptions where groupId = ? and userId = ?.
|
static Subscription |
findByPrimaryKey(long subscriptionId)
Returns the subscription with the primary key or throws a
NoSuchSubscriptionException if it could not be found. |
static Subscription |
findByU_C_First(long userId,
long classNameId,
OrderByComparator<Subscription> orderByComparator)
Returns the first subscription in the ordered set where userId = ? and classNameId = ?.
|
static Subscription |
findByU_C_Last(long userId,
long classNameId,
OrderByComparator<Subscription> orderByComparator)
Returns the last subscription in the ordered set where userId = ? and classNameId = ?.
|
static Subscription[] |
findByU_C_PrevAndNext(long subscriptionId,
long userId,
long classNameId,
OrderByComparator<Subscription> orderByComparator)
Returns the subscriptions before and after the current subscription in the ordered set where userId = ? and classNameId = ?.
|
static List<Subscription> |
findByU_C(long userId,
long classNameId)
Returns all the subscriptions where userId = ? and classNameId = ?.
|
static List<Subscription> |
findByU_C(long userId,
long classNameId,
int start,
int end)
Returns a range of all the subscriptions where userId = ? and classNameId = ?.
|
static List<Subscription> |
findByU_C(long userId,
long classNameId,
int start,
int end,
OrderByComparator<Subscription> orderByComparator)
Returns an ordered range of all the subscriptions where userId = ? and classNameId = ?.
|
static List<Subscription> |
findByU_C(long userId,
long classNameId,
int start,
int end,
OrderByComparator<Subscription> orderByComparator,
boolean retrieveFromCache)
Returns an ordered range of all the subscriptions where userId = ? and classNameId = ?.
|
static Subscription |
findByUserId_First(long userId,
OrderByComparator<Subscription> orderByComparator)
Returns the first subscription in the ordered set where userId = ?.
|
static Subscription |
findByUserId_Last(long userId,
OrderByComparator<Subscription> orderByComparator)
Returns the last subscription in the ordered set where userId = ?.
|
static Subscription[] |
findByUserId_PrevAndNext(long subscriptionId,
long userId,
OrderByComparator<Subscription> orderByComparator)
Returns the subscriptions before and after the current subscription in the ordered set where userId = ?.
|
static List<Subscription> |
findByUserId(long userId)
Returns all the subscriptions where userId = ?.
|
static List<Subscription> |
findByUserId(long userId,
int start,
int end)
Returns a range of all the subscriptions where userId = ?.
|
static List<Subscription> |
findByUserId(long userId,
int start,
int end,
OrderByComparator<Subscription> orderByComparator)
Returns an ordered range of all the subscriptions where userId = ?.
|
static List<Subscription> |
findByUserId(long userId,
int start,
int end,
OrderByComparator<Subscription> orderByComparator,
boolean retrieveFromCache)
Returns an ordered range of all the subscriptions where userId = ?.
|
static List<Subscription> |
findWithDynamicQuery(DynamicQuery dynamicQuery) |
static List<Subscription> |
findWithDynamicQuery(DynamicQuery dynamicQuery,
int start,
int end) |
static List<Subscription> |
findWithDynamicQuery(DynamicQuery dynamicQuery,
int start,
int end,
OrderByComparator<Subscription> orderByComparator) |
static SubscriptionPersistence |
getPersistence() |
static Subscription |
remove(long subscriptionId)
Removes the subscription with the primary key from the database.
|
static void |
removeAll()
Removes all the subscriptions from the database.
|
static void |
removeByC_C_C(long companyId,
long classNameId,
long classPK)
Removes all the subscriptions where companyId = ? and classNameId = ? and classPK = ? from the database.
|
static Subscription |
removeByC_U_C_C(long companyId,
long userId,
long classNameId,
long classPK)
Removes the subscription where companyId = ? and userId = ? and classNameId = ? and classPK = ? from the database.
|
static void |
removeByG_U(long groupId,
long userId)
Removes all the subscriptions where groupId = ? and userId = ? from the database.
|
static void |
removeByU_C(long userId,
long classNameId)
Removes all the subscriptions where userId = ? and classNameId = ? from the database.
|
static void |
removeByUserId(long userId)
Removes all the subscriptions where userId = ? from the database.
|
static Subscription |
update(Subscription subscription) |
static Subscription |
update(Subscription subscription,
ServiceContext serviceContext) |
static Subscription |
updateImpl(Subscription subscription) |
public static void clearCache()
BasePersistence.clearCache()
public static void clearCache(Subscription subscription)
public static long countWithDynamicQuery(DynamicQuery dynamicQuery)
public static List<Subscription> findWithDynamicQuery(DynamicQuery dynamicQuery)
public static List<Subscription> findWithDynamicQuery(DynamicQuery dynamicQuery, int start, int end)
public static List<Subscription> findWithDynamicQuery(DynamicQuery dynamicQuery, int start, int end, OrderByComparator<Subscription> orderByComparator)
public static Subscription update(Subscription subscription)
public static Subscription update(Subscription subscription, ServiceContext serviceContext)
public static List<Subscription> findByUserId(long userId)
userId
- the user IDpublic static List<Subscription> findByUserId(long userId, int start, int end)
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. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent and pagination is required (start
and end
are not QueryUtil#ALL_POS
), then the query will include the default ORDER BY logic from SubscriptionModelImpl
. If both orderByComparator
and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
userId
- the user IDstart
- the lower bound of the range of subscriptionsend
- the upper bound of the range of subscriptions (not inclusive)public static List<Subscription> findByUserId(long userId, int start, int end, OrderByComparator<Subscription> orderByComparator)
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. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent and pagination is required (start
and end
are not QueryUtil#ALL_POS
), then the query will include the default ORDER BY logic from SubscriptionModelImpl
. If both orderByComparator
and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
userId
- the user IDstart
- the lower bound of the range of subscriptionsend
- the upper bound of the range of subscriptions (not inclusive)orderByComparator
- the comparator to order the results by (optionally null
)public static List<Subscription> findByUserId(long userId, int start, int end, OrderByComparator<Subscription> orderByComparator, boolean retrieveFromCache)
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. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent and pagination is required (start
and end
are not QueryUtil#ALL_POS
), then the query will include the default ORDER BY logic from SubscriptionModelImpl
. If both orderByComparator
and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
userId
- the user IDstart
- the lower bound of the range of subscriptionsend
- the upper bound of the range of subscriptions (not inclusive)orderByComparator
- the comparator to order the results by (optionally null
)retrieveFromCache
- whether to retrieve from the finder cachepublic static Subscription findByUserId_First(long userId, OrderByComparator<Subscription> orderByComparator) throws NoSuchSubscriptionException
userId
- the user IDorderByComparator
- the comparator to order the set by (optionally null
)NoSuchSubscriptionException
- if a matching subscription could not be foundpublic static Subscription fetchByUserId_First(long userId, OrderByComparator<Subscription> orderByComparator)
userId
- the user IDorderByComparator
- the comparator to order the set by (optionally null
)null
if a matching subscription could not be foundpublic static Subscription findByUserId_Last(long userId, OrderByComparator<Subscription> orderByComparator) throws NoSuchSubscriptionException
userId
- the user IDorderByComparator
- the comparator to order the set by (optionally null
)NoSuchSubscriptionException
- if a matching subscription could not be foundpublic static Subscription fetchByUserId_Last(long userId, OrderByComparator<Subscription> orderByComparator)
userId
- the user IDorderByComparator
- the comparator to order the set by (optionally null
)null
if a matching subscription could not be foundpublic static Subscription[] findByUserId_PrevAndNext(long subscriptionId, long userId, OrderByComparator<Subscription> orderByComparator) throws NoSuchSubscriptionException
subscriptionId
- the primary key of the current subscriptionuserId
- the user IDorderByComparator
- the comparator to order the set by (optionally null
)NoSuchSubscriptionException
- if a subscription with the primary key could not be foundpublic static void removeByUserId(long userId)
userId
- the user IDpublic static int countByUserId(long userId)
userId
- the user IDpublic static List<Subscription> findByG_U(long groupId, long userId)
groupId
- the group IDuserId
- the user IDpublic static List<Subscription> findByG_U(long groupId, long userId, int start, int end)
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. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent and pagination is required (start
and end
are not QueryUtil#ALL_POS
), then the query will include the default ORDER BY logic from SubscriptionModelImpl
. If both orderByComparator
and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
groupId
- the group IDuserId
- the user IDstart
- the lower bound of the range of subscriptionsend
- the upper bound of the range of subscriptions (not inclusive)public static List<Subscription> findByG_U(long groupId, long userId, int start, int end, OrderByComparator<Subscription> orderByComparator)
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. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent and pagination is required (start
and end
are not QueryUtil#ALL_POS
), then the query will include the default ORDER BY logic from SubscriptionModelImpl
. If both orderByComparator
and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
groupId
- the group IDuserId
- the user IDstart
- the lower bound of the range of subscriptionsend
- the upper bound of the range of subscriptions (not inclusive)orderByComparator
- the comparator to order the results by (optionally null
)public static List<Subscription> findByG_U(long groupId, long userId, int start, int end, OrderByComparator<Subscription> orderByComparator, boolean retrieveFromCache)
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. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent and pagination is required (start
and end
are not QueryUtil#ALL_POS
), then the query will include the default ORDER BY logic from SubscriptionModelImpl
. If both orderByComparator
and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
groupId
- the group IDuserId
- the user IDstart
- the lower bound of the range of subscriptionsend
- the upper bound of the range of subscriptions (not inclusive)orderByComparator
- the comparator to order the results by (optionally null
)retrieveFromCache
- whether to retrieve from the finder cachepublic static Subscription findByG_U_First(long groupId, long userId, OrderByComparator<Subscription> orderByComparator) throws NoSuchSubscriptionException
groupId
- the group IDuserId
- the user IDorderByComparator
- the comparator to order the set by (optionally null
)NoSuchSubscriptionException
- if a matching subscription could not be foundpublic static Subscription fetchByG_U_First(long groupId, long userId, OrderByComparator<Subscription> orderByComparator)
groupId
- the group IDuserId
- the user IDorderByComparator
- the comparator to order the set by (optionally null
)null
if a matching subscription could not be foundpublic static Subscription findByG_U_Last(long groupId, long userId, OrderByComparator<Subscription> orderByComparator) throws NoSuchSubscriptionException
groupId
- the group IDuserId
- the user IDorderByComparator
- the comparator to order the set by (optionally null
)NoSuchSubscriptionException
- if a matching subscription could not be foundpublic static Subscription fetchByG_U_Last(long groupId, long userId, OrderByComparator<Subscription> orderByComparator)
groupId
- the group IDuserId
- the user IDorderByComparator
- the comparator to order the set by (optionally null
)null
if a matching subscription could not be foundpublic static Subscription[] findByG_U_PrevAndNext(long subscriptionId, long groupId, long userId, OrderByComparator<Subscription> orderByComparator) throws NoSuchSubscriptionException
subscriptionId
- the primary key of the current subscriptiongroupId
- the group IDuserId
- the user IDorderByComparator
- the comparator to order the set by (optionally null
)NoSuchSubscriptionException
- if a subscription with the primary key could not be foundpublic static void removeByG_U(long groupId, long userId)
groupId
- the group IDuserId
- the user IDpublic static int countByG_U(long groupId, long userId)
groupId
- the group IDuserId
- the user IDpublic static List<Subscription> findByU_C(long userId, long classNameId)
userId
- the user IDclassNameId
- the class name IDpublic static List<Subscription> findByU_C(long userId, long classNameId, int start, int end)
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. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent and pagination is required (start
and end
are not QueryUtil#ALL_POS
), then the query will include the default ORDER BY logic from SubscriptionModelImpl
. If both orderByComparator
and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
userId
- the user IDclassNameId
- the class name IDstart
- the lower bound of the range of subscriptionsend
- the upper bound of the range of subscriptions (not inclusive)public static List<Subscription> findByU_C(long userId, long classNameId, int start, int end, OrderByComparator<Subscription> orderByComparator)
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. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent and pagination is required (start
and end
are not QueryUtil#ALL_POS
), then the query will include the default ORDER BY logic from SubscriptionModelImpl
. If both orderByComparator
and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
userId
- the user IDclassNameId
- the class name IDstart
- the lower bound of the range of subscriptionsend
- the upper bound of the range of subscriptions (not inclusive)orderByComparator
- the comparator to order the results by (optionally null
)public static List<Subscription> findByU_C(long userId, long classNameId, int start, int end, OrderByComparator<Subscription> orderByComparator, boolean retrieveFromCache)
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. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent and pagination is required (start
and end
are not QueryUtil#ALL_POS
), then the query will include the default ORDER BY logic from SubscriptionModelImpl
. If both orderByComparator
and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
userId
- the user IDclassNameId
- the class name IDstart
- the lower bound of the range of subscriptionsend
- the upper bound of the range of subscriptions (not inclusive)orderByComparator
- the comparator to order the results by (optionally null
)retrieveFromCache
- whether to retrieve from the finder cachepublic static Subscription findByU_C_First(long userId, long classNameId, OrderByComparator<Subscription> orderByComparator) throws NoSuchSubscriptionException
userId
- the user IDclassNameId
- the class name IDorderByComparator
- the comparator to order the set by (optionally null
)NoSuchSubscriptionException
- if a matching subscription could not be foundpublic static Subscription fetchByU_C_First(long userId, long classNameId, OrderByComparator<Subscription> orderByComparator)
userId
- the user IDclassNameId
- the class name IDorderByComparator
- the comparator to order the set by (optionally null
)null
if a matching subscription could not be foundpublic static Subscription findByU_C_Last(long userId, long classNameId, OrderByComparator<Subscription> orderByComparator) throws NoSuchSubscriptionException
userId
- the user IDclassNameId
- the class name IDorderByComparator
- the comparator to order the set by (optionally null
)NoSuchSubscriptionException
- if a matching subscription could not be foundpublic static Subscription fetchByU_C_Last(long userId, long classNameId, OrderByComparator<Subscription> orderByComparator)
userId
- the user IDclassNameId
- the class name IDorderByComparator
- the comparator to order the set by (optionally null
)null
if a matching subscription could not be foundpublic static Subscription[] findByU_C_PrevAndNext(long subscriptionId, long userId, long classNameId, OrderByComparator<Subscription> orderByComparator) throws NoSuchSubscriptionException
subscriptionId
- the primary key of the current subscriptionuserId
- the user IDclassNameId
- the class name IDorderByComparator
- the comparator to order the set by (optionally null
)NoSuchSubscriptionException
- if a subscription with the primary key could not be foundpublic static void removeByU_C(long userId, long classNameId)
userId
- the user IDclassNameId
- the class name IDpublic static int countByU_C(long userId, long classNameId)
userId
- the user IDclassNameId
- the class name IDpublic static List<Subscription> findByC_C_C(long companyId, long classNameId, long classPK)
companyId
- the company IDclassNameId
- the class name IDclassPK
- the class pkpublic static List<Subscription> findByC_C_C(long companyId, long classNameId, long classPK, int start, int end)
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. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent and pagination is required (start
and end
are not QueryUtil#ALL_POS
), then the query will include the default ORDER BY logic from SubscriptionModelImpl
. If both orderByComparator
and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
companyId
- the company IDclassNameId
- the class name IDclassPK
- the class pkstart
- the lower bound of the range of subscriptionsend
- the upper bound of the range of subscriptions (not inclusive)public static List<Subscription> findByC_C_C(long companyId, long classNameId, long classPK, int start, int end, OrderByComparator<Subscription> orderByComparator)
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. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent and pagination is required (start
and end
are not QueryUtil#ALL_POS
), then the query will include the default ORDER BY logic from SubscriptionModelImpl
. If both orderByComparator
and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
companyId
- the company IDclassNameId
- the class name IDclassPK
- the class pkstart
- the lower bound of the range of subscriptionsend
- the upper bound of the range of subscriptions (not inclusive)orderByComparator
- the comparator to order the results by (optionally null
)public static List<Subscription> findByC_C_C(long companyId, long classNameId, long classPK, int start, int end, OrderByComparator<Subscription> orderByComparator, boolean retrieveFromCache)
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. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent and pagination is required (start
and end
are not QueryUtil#ALL_POS
), then the query will include the default ORDER BY logic from SubscriptionModelImpl
. If both orderByComparator
and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
companyId
- the company IDclassNameId
- the class name IDclassPK
- the class pkstart
- the lower bound of the range of subscriptionsend
- the upper bound of the range of subscriptions (not inclusive)orderByComparator
- the comparator to order the results by (optionally null
)retrieveFromCache
- whether to retrieve from the finder cachepublic static Subscription findByC_C_C_First(long companyId, long classNameId, long classPK, OrderByComparator<Subscription> orderByComparator) throws NoSuchSubscriptionException
companyId
- the company IDclassNameId
- the class name IDclassPK
- the class pkorderByComparator
- the comparator to order the set by (optionally null
)NoSuchSubscriptionException
- if a matching subscription could not be foundpublic static Subscription fetchByC_C_C_First(long companyId, long classNameId, long classPK, OrderByComparator<Subscription> orderByComparator)
companyId
- the company IDclassNameId
- the class name IDclassPK
- the class pkorderByComparator
- the comparator to order the set by (optionally null
)null
if a matching subscription could not be foundpublic static Subscription findByC_C_C_Last(long companyId, long classNameId, long classPK, OrderByComparator<Subscription> orderByComparator) throws NoSuchSubscriptionException
companyId
- the company IDclassNameId
- the class name IDclassPK
- the class pkorderByComparator
- the comparator to order the set by (optionally null
)NoSuchSubscriptionException
- if a matching subscription could not be foundpublic static Subscription fetchByC_C_C_Last(long companyId, long classNameId, long classPK, OrderByComparator<Subscription> orderByComparator)
companyId
- the company IDclassNameId
- the class name IDclassPK
- the class pkorderByComparator
- the comparator to order the set by (optionally null
)null
if a matching subscription could not be foundpublic static Subscription[] findByC_C_C_PrevAndNext(long subscriptionId, long companyId, long classNameId, long classPK, OrderByComparator<Subscription> orderByComparator) throws NoSuchSubscriptionException
subscriptionId
- the primary key of the current subscriptioncompanyId
- the company IDclassNameId
- the class name IDclassPK
- the class pkorderByComparator
- the comparator to order the set by (optionally null
)NoSuchSubscriptionException
- if a subscription with the primary key could not be foundpublic static void removeByC_C_C(long companyId, long classNameId, long classPK)
companyId
- the company IDclassNameId
- the class name IDclassPK
- the class pkpublic static int countByC_C_C(long companyId, long classNameId, long classPK)
companyId
- the company IDclassNameId
- the class name IDclassPK
- the class pkpublic static List<Subscription> findByC_U_C_C(long companyId, long userId, long classNameId, long[] classPKs)
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. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent and pagination is required (start
and end
are not QueryUtil#ALL_POS
), then the query will include the default ORDER BY logic from SubscriptionModelImpl
. If both orderByComparator
and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
companyId
- the company IDuserId
- the user IDclassNameId
- the class name IDclassPKs
- the class pkspublic static List<Subscription> findByC_U_C_C(long companyId, long userId, long classNameId, long[] classPKs, int start, int end)
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. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent and pagination is required (start
and end
are not QueryUtil#ALL_POS
), then the query will include the default ORDER BY logic from SubscriptionModelImpl
. If both orderByComparator
and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
companyId
- the company IDuserId
- the user IDclassNameId
- the class name IDclassPKs
- the class pksstart
- the lower bound of the range of subscriptionsend
- the upper bound of the range of subscriptions (not inclusive)public static List<Subscription> findByC_U_C_C(long companyId, long userId, long classNameId, long[] classPKs, int start, int end, OrderByComparator<Subscription> orderByComparator)
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. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent and pagination is required (start
and end
are not QueryUtil#ALL_POS
), then the query will include the default ORDER BY logic from SubscriptionModelImpl
. If both orderByComparator
and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
companyId
- the company IDuserId
- the user IDclassNameId
- the class name IDclassPKs
- the class pksstart
- the lower bound of the range of subscriptionsend
- the upper bound of the range of subscriptions (not inclusive)orderByComparator
- the comparator to order the results by (optionally null
)public static List<Subscription> findByC_U_C_C(long companyId, long userId, long classNameId, long[] classPKs, int start, int end, OrderByComparator<Subscription> orderByComparator, boolean retrieveFromCache)
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. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent and pagination is required (start
and end
are not QueryUtil#ALL_POS
), then the query will include the default ORDER BY logic from SubscriptionModelImpl
. If both orderByComparator
and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
companyId
- the company IDuserId
- the user IDclassNameId
- the class name IDclassPK
- the class pkstart
- the lower bound of the range of subscriptionsend
- the upper bound of the range of subscriptions (not inclusive)orderByComparator
- the comparator to order the results by (optionally null
)retrieveFromCache
- whether to retrieve from the finder cachepublic static Subscription findByC_U_C_C(long companyId, long userId, long classNameId, long classPK) throws NoSuchSubscriptionException
NoSuchSubscriptionException
if it could not be found.companyId
- the company IDuserId
- the user IDclassNameId
- the class name IDclassPK
- the class pkNoSuchSubscriptionException
- if a matching subscription could not be foundpublic static Subscription fetchByC_U_C_C(long companyId, long userId, long classNameId, long classPK)
null
if it could not be found. Uses the finder cache.companyId
- the company IDuserId
- the user IDclassNameId
- the class name IDclassPK
- the class pknull
if a matching subscription could not be foundpublic static Subscription fetchByC_U_C_C(long companyId, long userId, long classNameId, long classPK, boolean retrieveFromCache)
null
if it could not be found, optionally using the finder cache.companyId
- the company IDuserId
- the user IDclassNameId
- the class name IDclassPK
- the class pkretrieveFromCache
- whether to retrieve from the finder cachenull
if a matching subscription could not be foundpublic static Subscription removeByC_U_C_C(long companyId, long userId, long classNameId, long classPK) throws NoSuchSubscriptionException
companyId
- the company IDuserId
- the user IDclassNameId
- the class name IDclassPK
- the class pkNoSuchSubscriptionException
public static int countByC_U_C_C(long companyId, long userId, long classNameId, long classPK)
companyId
- the company IDuserId
- the user IDclassNameId
- the class name IDclassPK
- the class pkpublic static int countByC_U_C_C(long companyId, long userId, long classNameId, long[] classPKs)
companyId
- the company IDuserId
- the user IDclassNameId
- the class name IDclassPKs
- the class pkspublic static void cacheResult(Subscription subscription)
subscription
- the subscriptionpublic static void cacheResult(List<Subscription> subscriptions)
subscriptions
- the subscriptionspublic static Subscription create(long subscriptionId)
subscriptionId
- the primary key for the new subscriptionpublic static Subscription remove(long subscriptionId) throws NoSuchSubscriptionException
subscriptionId
- the primary key of the subscriptionNoSuchSubscriptionException
- if a subscription with the primary key could not be foundpublic static Subscription updateImpl(Subscription subscription)
public static Subscription findByPrimaryKey(long subscriptionId) throws NoSuchSubscriptionException
NoSuchSubscriptionException
if it could not be found.subscriptionId
- the primary key of the subscriptionNoSuchSubscriptionException
- if a subscription with the primary key could not be foundpublic static Subscription fetchByPrimaryKey(long subscriptionId)
null
if it could not be found.subscriptionId
- the primary key of the subscriptionnull
if a subscription with the primary key could not be foundpublic static Map<Serializable,Subscription> fetchByPrimaryKeys(Set<Serializable> primaryKeys)
public static List<Subscription> findAll()
public static List<Subscription> findAll(int start, int end)
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. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent and pagination is required (start
and end
are not QueryUtil#ALL_POS
), then the query will include the default ORDER BY logic from SubscriptionModelImpl
. If both orderByComparator
and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
start
- the lower bound of the range of subscriptionsend
- the upper bound of the range of subscriptions (not inclusive)public static List<Subscription> findAll(int start, int end, OrderByComparator<Subscription> orderByComparator)
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. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent and pagination is required (start
and end
are not QueryUtil#ALL_POS
), then the query will include the default ORDER BY logic from SubscriptionModelImpl
. If both orderByComparator
and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
start
- the lower bound of the range of subscriptionsend
- the upper bound of the range of subscriptions (not inclusive)orderByComparator
- the comparator to order the results by (optionally null
)public static List<Subscription> findAll(int start, int end, OrderByComparator<Subscription> orderByComparator, boolean retrieveFromCache)
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. If orderByComparator
is specified, then the query will include the given ORDER BY logic. If orderByComparator
is absent and pagination is required (start
and end
are not QueryUtil#ALL_POS
), then the query will include the default ORDER BY logic from SubscriptionModelImpl
. If both orderByComparator
and pagination are absent, for performance reasons, the query will not have an ORDER BY clause and the returned result set will be sorted on by the primary key in an ascending order.
start
- the lower bound of the range of subscriptionsend
- the upper bound of the range of subscriptions (not inclusive)orderByComparator
- the comparator to order the results by (optionally null
)retrieveFromCache
- whether to retrieve from the finder cachepublic static void removeAll()
public static int countAll()
public static SubscriptionPersistence getPersistence()