Class LoginToken.LoginTokenBuilder
java.lang.Object
org.springframework.vault.authentication.LoginToken.LoginTokenBuilder
- Enclosing class:
- LoginToken
Builder for
LoginToken.- Since:
- 3.0.2
-
Method Summary
Modifier and TypeMethodDescriptionConfigure the token accessor.build()Build a newLoginTokeninstance.leaseDuration(Duration leaseDuration) Configure the lease duration.renewable(boolean renewable) Configure whether the token is renewable.token(char[] token) Configure the token value.Configure the token value.Configure the token type.
-
Method Details
-
token
Configure the token value. This is a required builder property. Without this property, you cannotbuild()aLoginToken.- Parameters:
token- must not be empty or null.- Returns:
thisLoginToken.LoginTokenBuilder.
-
token
Configure the token value. This is a required builder property. Without this property, you cannotbuild()aLoginToken.- Parameters:
token- must not be empty or null.- Returns:
thisLoginToken.LoginTokenBuilder.
-
renewable
Configure whether the token is renewable.- Parameters:
renewable-- Returns:
thisLoginToken.LoginTokenBuilder.
-
leaseDuration
Configure the lease duration.- Parameters:
leaseDuration- must not be null.- Returns:
thisLoginToken.LoginTokenBuilder.
-
accessor
Configure the token accessor.- Parameters:
accessor- must not be empty or null.- Returns:
thisLoginToken.LoginTokenBuilder.
-
type
Configure the token type.- Parameters:
type- must not be empty or null.- Returns:
thisLoginToken.LoginTokenBuilder.
-
build
Build a newLoginTokeninstance.tokenmust be configured.- Returns:
- a new
LoginTokeninstance.
-