public class SubscriptionLocalServiceImpl extends SubscriptionLocalServiceBaseImpl
assetEntryFinder, assetEntryLocalService, assetEntryPersistence, classNameLocalService, classNamePersistence, counterLocalService, mbThreadFinder, mbThreadLocalService, mbThreadPersistence, persistedModelLocalServiceRegistry, subscriptionLocalService, subscriptionPersistence, userFinder, userLocalService, userPersistence| Constructor and Description |
|---|
SubscriptionLocalServiceImpl() |
| Modifier and Type | Method and Description |
|---|---|
com.liferay.portal.kernel.model.Subscription |
addSubscription(long userId,
long groupId,
String className,
long classPK)
Subscribes the user to the entity, notifying him the instant the entity
is created, deleted, or modified.
|
com.liferay.portal.kernel.model.Subscription |
addSubscription(long userId,
long groupId,
String className,
long classPK,
String frequency)
Subscribes the user to the entity, notifying him at the given frequency.
|
com.liferay.portal.kernel.model.Subscription |
deleteSubscription(long subscriptionId)
Deletes the subscription with the primary key.
|
void |
deleteSubscription(long userId,
String className,
long classPK)
Deletes the user's subscription to the entity.
|
com.liferay.portal.kernel.model.Subscription |
deleteSubscription(com.liferay.portal.kernel.model.Subscription subscription)
Deletes the subscription.
|
void |
deleteSubscriptions(long userId)
Deletes all the subscriptions of the user.
|
void |
deleteSubscriptions(long userId,
long groupId) |
void |
deleteSubscriptions(long companyId,
String className,
long classPK)
Deletes all the subscriptions to the entity.
|
com.liferay.portal.kernel.model.Subscription |
fetchSubscription(long companyId,
long userId,
String className,
long classPK) |
com.liferay.portal.kernel.model.Subscription |
getSubscription(long companyId,
long userId,
String className,
long classPK)
Returns the subscription of the user to the entity.
|
List<com.liferay.portal.kernel.model.Subscription> |
getSubscriptions(long companyId,
long userId,
String className,
long[] classPKs)
Returns all the subscriptions of the user to the entities.
|
List<com.liferay.portal.kernel.model.Subscription> |
getSubscriptions(long companyId,
String className,
long classPK)
Returns all the subscriptions to the entity.
|
List<com.liferay.portal.kernel.model.Subscription> |
getUserSubscriptions(long userId,
int start,
int end,
com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.kernel.model.Subscription> orderByComparator)
Returns an ordered range of all the subscriptions of the user.
|
List<com.liferay.portal.kernel.model.Subscription> |
getUserSubscriptions(long userId,
String className)
Returns all the subscriptions of the user to the entities with the class
name.
|
int |
getUserSubscriptionsCount(long userId)
Returns the number of subscriptions of the user.
|
boolean |
isSubscribed(long companyId,
long userId,
String className,
long classPK)
Returns
true if the user is subscribed to the entity. |
boolean |
isSubscribed(long companyId,
long userId,
String className,
long[] classPKs)
Returns
true if the user is subscribed to any of the
entities. |
addSubscription, afterPropertiesSet, createSubscription, deletePersistedModel, destroy, dynamicQuery, dynamicQuery, dynamicQuery, dynamicQuery, dynamicQueryCount, dynamicQueryCount, fetchSubscription, getActionableDynamicQuery, getAssetEntryFinder, getAssetEntryLocalService, getAssetEntryPersistence, getClassNameLocalService, getClassNamePersistence, getCounterLocalService, getIndexableActionableDynamicQuery, getMBThreadFinder, getMBThreadLocalService, getMBThreadPersistence, getModelClass, getModelClassName, getOSGiServiceIdentifier, getPersistedModel, getSubscription, getSubscriptionLocalService, getSubscriptionPersistence, getSubscriptions, getSubscriptionsCount, getUserFinder, getUserLocalService, getUserPersistence, initActionableDynamicQuery, runSQL, setAssetEntryFinder, setAssetEntryLocalService, setAssetEntryPersistence, setClassNameLocalService, setClassNamePersistence, setCounterLocalService, setMBThreadFinder, setMBThreadLocalService, setMBThreadPersistence, setSubscriptionLocalService, setSubscriptionPersistence, setUserFinder, setUserLocalService, setUserPersistence, updateSubscriptionpublic com.liferay.portal.kernel.model.Subscription addSubscription(long userId,
long groupId,
String className,
long classPK)
throws com.liferay.portal.kernel.exception.PortalException
If there is no asset entry with the class name and class PK a new asset entry is created.
A social activity for the subscription is created using the asset entry associated with the class name and class PK, or the newly created asset entry.
userId - the primary key of the usergroupId - the primary key of the entity's groupclassName - the entity's class nameclassPK - the primary key of the entity's instancecom.liferay.portal.kernel.exception.PortalExceptionpublic com.liferay.portal.kernel.model.Subscription addSubscription(long userId,
long groupId,
String className,
long classPK,
String frequency)
throws com.liferay.portal.kernel.exception.PortalException
If there is no asset entry with the class name and class PK a new asset entry is created.
A social activity for the subscription is created using the asset entry associated with the class name and class PK, or the newly created asset entry.
userId - the primary key of the usergroupId - the primary key of the entity's groupclassName - the entity's class nameclassPK - the primary key of the entity's instancefrequency - the frequency for notificationscom.liferay.portal.kernel.exception.PortalExceptionpublic com.liferay.portal.kernel.model.Subscription deleteSubscription(long subscriptionId)
throws com.liferay.portal.kernel.exception.PortalException
deleteSubscription in interface com.liferay.portal.kernel.service.SubscriptionLocalServicedeleteSubscription in class SubscriptionLocalServiceBaseImplsubscriptionId - the primary key of the subscriptioncom.liferay.portal.kernel.exception.PortalException - if a subscription with the primary key could not be foundpublic void deleteSubscription(long userId,
String className,
long classPK)
throws com.liferay.portal.kernel.exception.PortalException
userId - the primary key of the userclassName - the entity's class nameclassPK - the primary key of the entity's instancecom.liferay.portal.kernel.exception.PortalExceptionpublic com.liferay.portal.kernel.model.Subscription deleteSubscription(com.liferay.portal.kernel.model.Subscription subscription)
throws com.liferay.portal.kernel.exception.PortalException
deleteSubscription in interface com.liferay.portal.kernel.service.SubscriptionLocalServicedeleteSubscription in class SubscriptionLocalServiceBaseImplsubscription - the subscriptioncom.liferay.portal.kernel.exception.PortalExceptionpublic void deleteSubscriptions(long userId)
throws com.liferay.portal.kernel.exception.PortalException
userId - the primary key of the usercom.liferay.portal.kernel.exception.PortalExceptionpublic void deleteSubscriptions(long userId,
long groupId)
throws com.liferay.portal.kernel.exception.PortalException
com.liferay.portal.kernel.exception.PortalExceptionpublic void deleteSubscriptions(long companyId,
String className,
long classPK)
throws com.liferay.portal.kernel.exception.PortalException
companyId - the primary key of the companyclassName - the entity's class nameclassPK - the primary key of the entity's instancecom.liferay.portal.kernel.exception.PortalExceptionpublic com.liferay.portal.kernel.model.Subscription fetchSubscription(long companyId,
long userId,
String className,
long classPK)
public com.liferay.portal.kernel.model.Subscription getSubscription(long companyId,
long userId,
String className,
long classPK)
throws com.liferay.portal.kernel.exception.PortalException
companyId - the primary key of the companyuserId - the primary key of the userclassName - the entity's class nameclassPK - the primary key of the entity's instancecom.liferay.portal.kernel.exception.PortalExceptionpublic List<com.liferay.portal.kernel.model.Subscription> getSubscriptions(long companyId, long userId, String className, long[] classPKs)
companyId - the primary key of the companyuserId - the primary key of the userclassName - the entity's class nameclassPKs - the primary key of the entitiespublic List<com.liferay.portal.kernel.model.Subscription> getSubscriptions(long companyId, String className, long classPK)
companyId - the primary key of the companyclassName - the entity's class nameclassPK - the primary key of the entity's instancepublic List<com.liferay.portal.kernel.model.Subscription> getUserSubscriptions(long userId, int start, int end, com.liferay.portal.kernel.util.OrderByComparator<com.liferay.portal.kernel.model.Subscription> orderByComparator)
userId - the primary key of the userstart - the lower bound of the range of resultsend - the upper bound of the range of results (not inclusive)orderByComparator - the comparator to order the subscriptionspublic List<com.liferay.portal.kernel.model.Subscription> getUserSubscriptions(long userId, String className)
userId - the primary key of the userclassName - the entity's class namepublic int getUserSubscriptionsCount(long userId)
userId - the primary key of the userpublic boolean isSubscribed(long companyId,
long userId,
String className,
long classPK)
true if the user is subscribed to the entity.companyId - the primary key of the companyuserId - the primary key of the userclassName - the entity's class nameclassPK - the primary key of the entity's instancetrue if the user is subscribed to the entity;
false otherwisepublic boolean isSubscribed(long companyId,
long userId,
String className,
long[] classPKs)
true if the user is subscribed to any of the
entities.companyId - the primary key of the companyuserId - the primary key of the userclassName - the entity's class nameclassPKs - the primary key of the entitiestrue if the user is subscribed to any of the
entities; false otherwise