public interface SubscriptionService extends ActivateableBean
Modifier and Type | Method and Description |
---|---|
void |
follow(String userId,
String userToFollow)
Follows a user.
|
boolean |
follows(String userId,
String userToFollow)
Returns if the user follows to the given other user.
|
PagingFollowingResults |
getFollowers(String userId,
org.alfresco.query.PagingRequest pagingRequest)
Returns a list of users that follow the given user.
|
int |
getFollowersCount(String userId)
Returns how many users follow the given user.
|
PagingFollowingResults |
getFollowing(String userId,
org.alfresco.query.PagingRequest pagingRequest)
Returns a list of users that the given user follows.
|
int |
getFollowingCount(String userId)
Returns how many users the given user follows.
|
int |
getSubscriptionCount(String userId,
SubscriptionItemTypeEnum type)
Returns how many nodes the given user has subscribed to.
|
PagingSubscriptionResults |
getSubscriptions(String userId,
SubscriptionItemTypeEnum type,
org.alfresco.query.PagingRequest pagingRequest)
Returns the nodes a user has subscribed to.
|
boolean |
hasSubscribed(String userId,
org.alfresco.service.cmr.repository.NodeRef node)
Returns if the user has subscribed to the given node.
|
boolean |
isActive()
Returns if subscription are enabled for this system.
|
boolean |
isSubscriptionListPrivate(String userId)
Returns if the subscription list of the given user is set to private.
|
void |
setSubscriptionListPrivate(String userId,
boolean isPrivate)
Sets or unsets the subscription list of the given user to private.
|
void |
subscribe(String userId,
org.alfresco.service.cmr.repository.NodeRef node)
Subscribes to a node.
|
void |
unfollow(String userId,
String userToUnfollow)
Unfollows a user.
|
void |
unsubscribe(String userId,
org.alfresco.service.cmr.repository.NodeRef node)
Unsubscribes from a node.
|
@NotAuditable PagingSubscriptionResults getSubscriptions(String userId, SubscriptionItemTypeEnum type, org.alfresco.query.PagingRequest pagingRequest)
userId
- the id of the usertype
- the type of the nodespagingRequest
- paging detailsPrivateSubscriptionListException
- if the subscription list is private and the calling user is
not allowed to see it@NotAuditable int getSubscriptionCount(String userId, SubscriptionItemTypeEnum type)
userId
- the id of the usertype
- the type of the nodes@Auditable(parameters={"userId","node"}) void subscribe(String userId, org.alfresco.service.cmr.repository.NodeRef node)
userId
- id of the usernode
- the node@Auditable(parameters={"userId","node"}) void unsubscribe(String userId, org.alfresco.service.cmr.repository.NodeRef node)
userId
- id of the usernode
- the node@NotAuditable boolean hasSubscribed(String userId, org.alfresco.service.cmr.repository.NodeRef node)
userId
- id of the usernode
- the node@NotAuditable PagingFollowingResults getFollowing(String userId, org.alfresco.query.PagingRequest pagingRequest)
userId
- id of the userpagingRequest
- paging detailsPrivateSubscriptionListException
- if the subscription list is private and the calling user is
not allowed to see it@NotAuditable PagingFollowingResults getFollowers(String userId, org.alfresco.query.PagingRequest pagingRequest)
userId
- id of the userpagingRequest
- paging details@NotAuditable int getFollowingCount(String userId)
userId
- the id of the user@NotAuditable int getFollowersCount(String userId)
userId
- the id of the user@Auditable(parameters={"userId","userToFollow"}) void follow(String userId, String userToFollow)
userId
- the id of the useruserToFollow
- the id of the user to follow@Auditable(parameters={"userId","userToUnfollow"}) void unfollow(String userId, String userToUnfollow)
userId
- the id of the useruserToUnfollow
- the id of the user to unfollow@NotAuditable boolean follows(String userId, String userToFollow)
userId
- id of the useruserToFollow
- the id of the other user@Auditable(parameters={"userId","isPrivate"}) void setSubscriptionListPrivate(String userId, boolean isPrivate)
userId
- the id of the userisPrivate
- true
- set list private,
false
- set list public@NotAuditable boolean isSubscriptionListPrivate(String userId)
userId
- the id of the user@NotAuditable boolean isActive()
isActive
in interface ActivateableBean
true
if this bean is activeCopyright © 2005–2017 Alfresco Software. All rights reserved.