public abstract class AuthenticationSessionAbstract extends Object implements AuthenticationSession, Serializable
| Constructor and Description |
|---|
AuthenticationSessionAbstract(DataInputExtended input) |
AuthenticationSessionAbstract(String name,
List<String> roles,
String validationCode) |
AuthenticationSessionAbstract(String name,
String code) |
| Modifier and Type | Method and Description |
|---|---|
void |
encode(DataOutputExtended output)
Returns the domain object's value as an encoded byte array via the
encoder.
|
Object |
getAttribute(String attributeName)
For viewers (in particular) to store additional attributes, analogous to
an HttpSession.
|
MessageBroker |
getMessageBroker()
The
MessageBroker that holds messages for this user. |
List<String> |
getRoles()
Can be overridden.
|
String |
getUserName()
The name of the authenticated user; for display purposes only.
|
String |
getValidationCode()
A unique code given to this session during authentication.
|
boolean |
hasUserNameOf(String userName) |
void |
setAttribute(String attributeName,
Object attribute) |
void |
setMessageBroker(MessageBroker messageBroker)
Providing the ability for a
MessageBroker to be set on this
AuthenticationSession (is lazily created by the runtime). |
String |
toString() |
public AuthenticationSessionAbstract(String name, String code)
public AuthenticationSessionAbstract(String name, List<String> roles, String validationCode)
public AuthenticationSessionAbstract(DataInputExtended input) throws IOException
IOExceptionpublic void encode(DataOutputExtended output) throws IOException
Encodableencode in interface EncodableIOExceptionpublic String getUserName()
AuthenticationSessiongetUserName in interface AuthenticationSessionpublic boolean hasUserNameOf(String userName)
hasUserNameOf in interface AuthenticationSessionpublic List<String> getRoles()
getRoles in interface AuthenticationSessionpublic String getValidationCode()
AuthenticationSessionThis can be used to confirm that this session has been properly created and the user has been authenticated. It should return an empty string ( "") if this is unauthenticated user (i.e., as created within an exploration system).
getValidationCode in interface AuthenticationSessionpublic Object getAttribute(String attributeName)
AuthenticationSessiongetAttribute in interface AuthenticationSessionpublic void setAttribute(String attributeName, Object attribute)
setAttribute in interface AuthenticationSessionAuthenticationSession.getAttribute(String)public MessageBroker getMessageBroker()
AuthenticationSessionMessageBroker that holds messages for this user.getMessageBroker in interface AuthenticationSessionpublic void setMessageBroker(MessageBroker messageBroker)
AuthenticationSessionMessageBroker to be set on this
AuthenticationSession (is lazily created by the runtime).setMessageBroker in interface AuthenticationSessionCopyright © 2010–2014 The Apache Software Foundation. All rights reserved.