C
- the type of credentials that the filter acceptsP
- the type of the principal that the filter acceptspublic abstract static class AuthFilter.AuthFilterBuilder<C,P extends Principal,T extends AuthFilter<C,P>> extends Object
Constructor and Description |
---|
AuthFilterBuilder() |
Modifier and Type | Method and Description |
---|---|
T |
buildAuthFilter()
Builds an instance of the filter with a provided authenticator,
an authorizer, a prefix, and a realm.
|
protected abstract T |
newInstance() |
AuthFilter.AuthFilterBuilder<C,P,T> |
setAuthenticator(Authenticator<C,P> authenticator)
Sets the given authenticator
|
AuthFilter.AuthFilterBuilder<C,P,T> |
setAuthorizer(Authorizer<P> authorizer)
Sets the given authorizer
|
AuthFilter.AuthFilterBuilder<C,P,T> |
setPrefix(String prefix)
Sets the given prefix
|
AuthFilter.AuthFilterBuilder<C,P,T> |
setRealm(String realm)
Sets the given realm
|
AuthFilter.AuthFilterBuilder<C,P,T> |
setUnauthorizedHandler(UnauthorizedHandler unauthorizedHandler)
Sets the given unauthorized handler
|
public AuthFilter.AuthFilterBuilder<C,P,T> setRealm(String realm)
realm
- a realmpublic AuthFilter.AuthFilterBuilder<C,P,T> setPrefix(String prefix)
prefix
- a prefixpublic AuthFilter.AuthFilterBuilder<C,P,T> setAuthorizer(Authorizer<P> authorizer)
authorizer
- an Authorizer
public AuthFilter.AuthFilterBuilder<C,P,T> setAuthenticator(Authenticator<C,P> authenticator)
authenticator
- an Authenticator
public AuthFilter.AuthFilterBuilder<C,P,T> setUnauthorizedHandler(UnauthorizedHandler unauthorizedHandler)
unauthorizedHandler
- an UnauthorizedHandler
public T buildAuthFilter()
protected abstract T newInstance()
Copyright © 2011. All rights reserved.