java.lang.Object
iu.auth.session.Session
- All Implemented Interfaces:
IuSession
IuSession
implementation-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
clearDetail
(Class<?> type) Clear session attributes<T> T
Get session attributes(package private) Instant
Gets session expire timeGet resource URIboolean
Gets whether session object state changeboolean
isStrict()
Gets strict(package private) void
setChanged
(boolean changed) Sets the change flagvoid
setStrict
(boolean strict) Set strict mode(package private) String
tokenize
(byte[] secretKey, WebKey issuerKey, WebKey.Algorithm algorithm) Token constructortoString()
-
Constructor Details
-
Session
New session constructor.- Parameters:
resourceUri
- root protected resource URIexpires
- expiration time
-
Session
Session token constructor.- Parameters:
token
- tokenized sessionsecretKey
- Secret key to use for detokenizing the session.issuerKey
- issuer keymaxSessionTtl
- maximum session time to live
-
-
Method Details
-
tokenize
Token constructor- Parameters:
secretKey
- secret keyissuerKey
- issuer keyalgorithm
- algorithm- Returns:
- tokenized session
-
getDetail
Description copied from interface:IuSession
Get session attributes -
clearDetail
Description copied from interface:IuSession
Clear session attributes- Specified by:
clearDetail
in interfaceIuSession
- Parameters:
type
- class
-
isChanged
public boolean isChanged()Description copied from interface:IuSession
Gets whether session object state change -
setChanged
void setChanged(boolean changed) Sets the change flag- Parameters:
changed
- set to true when session attributes change, otherwise false
-
getExpires
Instant getExpires()Gets session expire time- Returns:
Instant
session expire time
-
getResourceUri
Description copied from interface:IuSession
Get resource URI- Specified by:
getResourceUri
in interfaceIuSession
- Returns:
- resource URI
-
toString
-
isStrict
public boolean isStrict()Gets strict- Returns:
- strict mode
-
setStrict
public void setStrict(boolean strict) Description copied from interface:IuSession
Set strict mode
-