Package io.datarouter.auth.session
Class RequestAwareCurrentSessionInfoFactory.RequestAwareCurrentSessionInfo
java.lang.Object
io.datarouter.auth.session.RequestAwareCurrentSessionInfoFactory.RequestAwareCurrentSessionInfo
- Enclosing class:
RequestAwareCurrentSessionInfoFactory
public static class RequestAwareCurrentSessionInfoFactory.RequestAwareCurrentSessionInfo
extends Object
This is a wrapper of
CurrentSessionInfo that does not require passing the request to every method.-
Constructor Summary
ConstructorsConstructorDescriptionRequestAwareCurrentSessionInfo(CurrentSessionInfo currentSessionInfo, javax.servlet.ServletRequest request) -
Method Summary
Modifier and TypeMethodDescriptiongetNonEmptyUsernameOrElse(String other) getRoles()booleanhasAnyRole(Collection<Role> targetRoles) booleanhasAnyRoleEnum(Collection<RoleEnum<?>> targetRoles) booleanboolean
-
Constructor Details
-
RequestAwareCurrentSessionInfo
public RequestAwareCurrentSessionInfo(CurrentSessionInfo currentSessionInfo, javax.servlet.ServletRequest request)
-
-
Method Details
-
findNonEmptyUsername
-
getNonEmptyUsernameOrElse
-
getSession
-
getRequiredSession
-
getRoles
-
hasRole
-
hasRole
-
hasAnyRole
-
hasAnyRoleEnum
-