public static class DefaultRealm.RealmBuilder extends Object implements Realm.Builder
Builder implementation.| Constructor and Description |
|---|
RealmBuilder()
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
Realm |
build()
Build
Realm instance |
Realm.Builder |
name(String name)
Set Realm name
|
Realm.Builder |
withAuthenticationListener(Authentication.AuthenticationListener authenticationListener)
Register an
Authentication.AuthenticationListener for authentication events |
<T extends AuthenticationToken> |
withAuthenticator(Authenticator<T> authenticator)
Register given
Authenticator in Realm. |
<P extends Permission> |
withAuthorizer(Authorizer<P> authorizer)
Register given
Authorizer in Realm. |
Realm.Builder |
withDefaultAuthorizer()
Register the default
Authorizer |
Realm.Builder |
withResolver(AuthenticationToken.AuthenticationTokenResolver<?> authenticationTokenResolver)
Add an
AuthenticationToken.AuthenticationTokenResolver to translate Messages into AuthenticationTokens. |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitauthenticator, authorizer, listener, resolverpublic Realm.Builder name(String name)
Realm.Buildername in interface Realm.Buildername - Realm name to setpublic <T extends AuthenticationToken> Realm.Builder withAuthenticator(Authenticator<T> authenticator)
Realm.BuilderAuthenticator in Realm.
Registered Authenticators will be inspected in the order they were added to Realm to find the first one which
is consistent with the AuthenticationToken type to process during authentication operations performed
using Authenticator.authenticate(AuthenticationToken).
withAuthenticator in interface Realm.BuilderT - Authentication token typeauthenticator - The Authenticator to add (not null)public Realm.Builder withResolver(AuthenticationToken.AuthenticationTokenResolver<?> authenticationTokenResolver)
Realm.BuilderAuthenticationToken.AuthenticationTokenResolver to translate Messages into AuthenticationTokens.withResolver in interface Realm.BuilderauthenticationTokenResolver - Resolver to addpublic <P extends Permission> Realm.Builder withAuthorizer(Authorizer<P> authorizer)
Realm.BuilderAuthorizer in Realm.
Registered Authorizers will be inspected in the order they were added to Realm to find the first one which is
consistent with the Permission type to process during authorization checking performed using
isPermitted methods.
withAuthorizer in interface Realm.BuilderP - Permission typeauthorizer - Authorizer to addpublic Realm.Builder withDefaultAuthorizer()
Realm.BuilderAuthorizerwithDefaultAuthorizer in interface Realm.BuilderAuthorizer.create()public Realm.Builder withAuthenticationListener(Authentication.AuthenticationListener authenticationListener)
Realm.BuilderAuthentication.AuthenticationListener for authentication eventswithAuthenticationListener in interface Realm.BuilderauthenticationListener - The AuthenticationListener to register (not null)public Realm build()
Realm.BuilderRealm instancebuild in interface Realm.BuilderCopyright © 2019 The Holon Platform. All rights reserved.