java.lang.Object
iu.auth.session.Session
- All Implemented Interfaces:
IuSession
IuSession implementation-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidclearDetail(Class<?> type) Clear session attributes<T> TGet session attributes(package private) InstantGets session expire timeGet resource URIbooleanGets whether session object state changebooleanisStrict()Gets strict(package private) voidsetChanged(boolean changed) Sets the change flagvoidsetStrict(boolean strict) Set strict mode(package private) Stringtokenize(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:IuSessionGet session attributes -
clearDetail
Description copied from interface:IuSessionClear session attributes- Specified by:
clearDetailin interfaceIuSession- Parameters:
type- class
-
isChanged
public boolean isChanged()Description copied from interface:IuSessionGets 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:
Instantsession expire time
-
getResourceUri
Description copied from interface:IuSessionGet resource URI- Specified by:
getResourceUriin interfaceIuSession- Returns:
- resource URI
-
toString
-
isStrict
public boolean isStrict()Gets strict- Returns:
- strict mode
-
setStrict
public void setStrict(boolean strict) Description copied from interface:IuSessionSet strict mode
-