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 newLoginToken
instance.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:
this
LoginToken.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:
this
LoginToken.LoginTokenBuilder
.
-
renewable
Configure whether the token is renewable.- Parameters:
renewable
-- Returns:
this
LoginToken.LoginTokenBuilder
.
-
leaseDuration
Configure the lease duration.- Parameters:
leaseDuration
- must not be null.- Returns:
this
LoginToken.LoginTokenBuilder
.
-
accessor
Configure the token accessor.- Parameters:
accessor
- must not be empty or null.- Returns:
this
LoginToken.LoginTokenBuilder
.
-
type
Configure the token type.- Parameters:
type
- must not be empty or null.- Returns:
this
LoginToken.LoginTokenBuilder
.
-
build
Build a newLoginToken
instance.token
must be configured.- Returns:
- a new
LoginToken
instance.
-