Modifier and Type | Method and Description |
---|---|
AmService.Builder |
authenticationService(AuthenticationService authenticationService)
Bind a
AuthenticationService instance to this builder. |
AmService |
build()
Returns a new
AmService instance. |
AmService.Builder |
cookieName(String cookieName)
Set the cookie/header name and returns this builder.
|
AmService.Builder |
enableNotifications(boolean enabled)
Enable or disable the notifications.
|
AmService.Builder |
notificationService(NotificationService notificationService)
Bind a
NotificationService instance to this builder. |
AmService.Builder |
notificationServiceReconnectDelay(Duration delay)
Specifies the delay to wait between connection re-establishments
when web-socket connection is lost (or cannot be acquired at startup).
|
AmService.Builder |
notificationServiceTls(TlsOptions tlsOptions)
Specifies the TLS options to use for establishing a connection to the Web-socket endpoint.
|
AmService.Builder |
realm(Realm realm)
Set the realm and returns this builder.
|
AmService.Builder |
realm(String realm)
Set the realm and returns this builder.
|
AmService.Builder |
sessionCache(com.github.benmanes.caffeine.cache.Caffeine<Object,Object> caffeine,
Duration maximumTimeout,
CacheSessionService.DisconnectionStrategy disconnectionStrategy)
Specifies the
Caffeine cache for the CacheSessionService . |
AmService.Builder |
sessionService(SessionService sessionService)
Bind a
SessionService instance to this builder. |
AmService.Builder |
uriService(UriService uriService)
Bind a
UriService instance to this builder. |
AmService.Builder |
version(String version)
Set the version and returns this builder.
|
AmService.Builder |
version(Version version)
Set the version and returns this builder.
|
public AmService.Builder realm(String realm)
realm
- The realm to use, such as finances. Default is 'root' (or '/') if this parameter is set to
null
.public AmService.Builder realm(Realm realm)
realm
- The realm to use, such as finances. Default is root realm (named '/') if this parameter
is set to null
.public AmService.Builder cookieName(String cookieName)
cookieName
- The cookie/header name to use with this server. Default is 'iPlanetDirectoryPro' if
this parameter is set to null
.public AmService.Builder enableNotifications(boolean enabled)
enabled
- true
if the notifications should be enabled or false
otherwise.public AmService.Builder version(String version)
version
- The version of OpenAM that this instance represents. Default is AmService.DEFAULT_AM_VERSION
if this parameter is set to null
.public AmService.Builder version(Version version)
version
- The version of OpenAM/AM that this instance represents. Default is AmService.DEFAULT_AM_VERSION
if this parameter is set to null
.public AmService.Builder sessionCache(com.github.benmanes.caffeine.cache.Caffeine<Object,Object> caffeine, Duration maximumTimeout, CacheSessionService.DisconnectionStrategy disconnectionStrategy)
Caffeine
cache for the CacheSessionService
.
If the cache is set to null
, no cache will be used.caffeine
- The Caffeine
cache. If the cache
is null
,
then the cache will be disabled.maximumTimeout
- The maximum time to cache a session; can be null
.disconnectionStrategy
- The strategy to apply in case of notifications' disconnection.public AmService.Builder sessionService(SessionService sessionService)
SessionService
instance to this builder.sessionService
- service to be boundpublic AmService.Builder authenticationService(AuthenticationService authenticationService)
AuthenticationService
instance to this builder.authenticationService
- service to be boundpublic AmService.Builder uriService(UriService uriService)
UriService
instance to this builder.uriService
- service to be boundpublic AmService.Builder notificationServiceReconnectDelay(Duration delay)
delay
- reconnection delay used when notification service is disconnectedpublic AmService.Builder notificationServiceTls(TlsOptions tlsOptions)
tlsOptions
- options to use when establishing secure connection to the WS endpointpublic AmService.Builder notificationService(NotificationService notificationService)
NotificationService
instance to this builder.notificationService
- service to be boundCopyright 2011-2017 ForgeRock AS.