接口 SimpUserRegistry
public interface SimpUserRegistry
A registry of currently connected users.- 从以下版本开始:
- 4.2
- 作者:
- Rossen Stoyanchev
方法概要
所有方法 实例方法 抽象方法 修饰符和类型 方法 说明 Set<SimpSubscription>
findSubscriptions(SimpSubscriptionMatcher matcher)
Find subscriptions with the given matcher.SimpUser
getUser(String userName)
Get the user for the given name.int
getUserCount()
Return the count of all connected users.Set<SimpUser>
getUsers()
Return a snapshot of all connected users.
方法详细资料
getUser
SimpUser getUser(String userName)
Get the user for the given name.- 参数:
userName
- the name of the user to look up- 返回:
- the user, or
null
if not connected
getUsers
Set<SimpUser> getUsers()
Return a snapshot of all connected users.The returned set is a copy and will not reflect further changes.
- 返回:
- the connected users, or an empty set if none
getUserCount
int getUserCount()
Return the count of all connected users.- 返回:
- the number of connected users
- 从以下版本开始:
- 4.3.5
findSubscriptions
Set<SimpSubscription> findSubscriptions(SimpSubscriptionMatcher matcher)
Find subscriptions with the given matcher.- 参数:
matcher
- the matcher to use- 返回:
- a set of matching subscriptions, or an empty set if none