public class AuthRegistry extends Object
| Constructor and Description |
|---|
AuthRegistry(Set<String> allowedUsers) |
| Modifier and Type | Method and Description |
|---|---|
Optional<String> |
addAuth(long sessionId,
String auth)
Add session with auth t registry.
|
Optional<String> |
getAuth(long sessionId)
Get session's auth data if exists.
|
String |
removeAuth(long sessionId)
Remove session from registry.
|
public Optional<String> getAuth(long sessionId)
sessionId - session id to get auth info forpublic Optional<String> addAuth(long sessionId, String auth)
sessionId - session id to add auth info forauth - auth info for given session idpublic String removeAuth(long sessionId)
sessionId - session id to be removed from registryCopyright © 2015–2020. All rights reserved.