Package io.dropwizard.auth
Class PermitAllAuthorizer<P extends Principal>
- java.lang.Object
-
- io.dropwizard.auth.PermitAllAuthorizer<P>
-
- Type Parameters:
P
- the type of the principal
- All Implemented Interfaces:
Authorizer<P>
public class PermitAllAuthorizer<P extends Principal> extends Object implements Authorizer<P>
AnAuthorizer
that grants access for any principal in any role.
-
-
Constructor Summary
Constructors Constructor Description PermitAllAuthorizer()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
authorize(P principal, String role)
Decides if access is granted for the given principal in the given role.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface io.dropwizard.auth.Authorizer
authorize
-
-
-
-
Method Detail
-
authorize
public boolean authorize(P principal, String role)
Description copied from interface:Authorizer
Decides if access is granted for the given principal in the given role.- Specified by:
authorize
in interfaceAuthorizer<P extends Principal>
- Parameters:
principal
- aPrincipal
object, representing a userrole
- a user role- Returns:
true
, if the access is granted,false otherwise
-
-