Class UserAuthorizer

java.lang.Object
no.polaric.core.auth.UserAuthorizer
All Implemented Interfaces:
org.pac4j.core.authorization.authorizer.Authorizer

public class UserAuthorizer extends Object implements org.pac4j.core.authorization.authorizer.Authorizer
Authorizer for users. Instantiated with an authorization level (0=login, 1=operator, 2=admin).
  • Constructor Details

    • UserAuthorizer

      public UserAuthorizer()
    • UserAuthorizer

      public UserAuthorizer(int lvl)
  • Method Details

    • isAuthorized

      public boolean isAuthorized(org.pac4j.core.context.WebContext ctx, org.pac4j.core.context.session.SessionStore ss, List<org.pac4j.core.profile.UserProfile> profile)
      Authorize if user has been assigned the specified level.
      Specified by:
      isAuthorized in interface org.pac4j.core.authorization.authorizer.Authorizer
    • toString

      public String toString()
      Overrides:
      toString in class Object