@ThreadRestricted public static final class CommandResponder.Session extends HashMap<Object,Object> implements AuthenticatedUser, ServiceSession
Modifier and Type | Class and Description |
---|---|
class |
CommandResponder.Session.ResponderNameComparator
A comparator to compare command-responders by commandName.
|
AbstractMap.SimpleEntry<K,V>, AbstractMap.SimpleImmutableEntry<K,V>
Constructor and Description |
---|
CommandResponder.Session(VoterInterface _voterInterface,
String _email,
int _trustLevel,
BundleFormatter _bunA,
ReplyBuilder _replyBuilder)
Constructs a Session.
|
Modifier and Type | Method and Description |
---|---|
BundleFormatter |
bunA()
The application (A) bundle formatter for this session.
|
BundleFormatter |
bunCR()
The command/response (CR) bundle formatter for this session.
|
String |
email()
The user's canonical email address, which might be that of NOBODY.email().
|
ReplyBuilder |
replyBuilder()
The command-response (CR) builder to use in replying to commands.
|
int |
trustLevel()
The user's trust level.
|
AuthenticatedUser |
user()
The authenticated user, or null if the user is unauthenticated.
|
AuthenticatedUser |
userOrNobody()
The authenticated user, or NOBODY if the user is
unauthenticated.
|
VoterInterface |
voterInterface()
The voter interface that is providing this session.
|
clear, clone, containsKey, containsValue, entrySet, get, isEmpty, keySet, put, putAll, remove, size, values
equals, hashCode, toString
public CommandResponder.Session(VoterInterface _voterInterface, String _email, int _trustLevel, BundleFormatter _bunA, ReplyBuilder _replyBuilder)
voterInterface()
,
email()
,
trustLevel()
,
bunA()
,
replyBuilder()
public BundleFormatter bunA()
bunCR()
public BundleFormatter bunCR()
bunA()
,
replyBuilder()
public ReplyBuilder replyBuilder()
bunA()
,
bunCR()
public VoterInterface voterInterface()
public String email()
AuthenticatedUser
email
in interface AuthenticatedUser
public int trustLevel()
AuthenticatedUser
trustLevel
in interface AuthenticatedUser
public AuthenticatedUser user()
ServiceSession
user
in interface ServiceSession
public AuthenticatedUser userOrNobody()
ServiceSession
userOrNobody
in interface ServiceSession