Class PasswordParameters
java.lang.Object
org.springframework.credhub.support.password.PasswordParameters
Parameters for generating a new password credential. All parameters are optional; if
not specified, CredHub-provided defaults will be used.
- Author:
- Scott Frederick
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic class
A builder that provides a fluent API for constructingPasswordParameters.PasswordParametersBuilder
s. -
Constructor Summary
ConstructorDescriptionCreate aPasswordParameters
using defaults for all parameter values.PasswordParameters
(int length, boolean excludeUpper, boolean excludeLower, boolean excludeNumber, boolean includeSpecial) Create aPasswordParameters
using the specified values. -
Method Summary
Modifier and TypeMethodDescriptionbuilder()
Create a builder that provides a fluent API for providing the values required to construct aPasswordParameters
.Get the value of the exclude lower case characters parameter.Get the value of the exclude numeric characters parameter.Get the value of the exclude upper case characters parameter.Get the value of the include non-alphanumeric characters parameter.Get the value of the length parameter.
-
Constructor Details
-
PasswordParameters
public PasswordParameters()Create aPasswordParameters
using defaults for all parameter values. -
PasswordParameters
public PasswordParameters(int length, boolean excludeUpper, boolean excludeLower, boolean excludeNumber, boolean includeSpecial) Create aPasswordParameters
using the specified values.- Parameters:
length
- length of generated password valueexcludeUpper
- true to exclude upper case alpha characters from generated credential valueexcludeLower
- true to exclude lower case alpha characters from generated credential valueexcludeNumber
- true to exclude numeric characters from generated credential valueincludeSpecial
- true to include non-alphanumeric characters in generated credential value
-
-
Method Details
-
getLength
Get the value of the length parameter.- Returns:
- the value of the parameter; will be null if not explicitly set
-
getExcludeUpper
Get the value of the exclude upper case characters parameter.- Returns:
- the value of the parameter; will be null if not explicitly set
-
getExcludeLower
Get the value of the exclude lower case characters parameter.- Returns:
- the value of the parameter; will be null if not explicitly set
-
getExcludeNumber
Get the value of the exclude numeric characters parameter.- Returns:
- the value of the parameter; will be null if not explicitly set
-
getIncludeSpecial
Get the value of the include non-alphanumeric characters parameter.- Returns:
- the value of the parameter; will be null if not explicitly set
-
builder
Create a builder that provides a fluent API for providing the values required to construct aPasswordParameters
.- Returns:
- a builder
-