| Constructor and Description |
|---|
Builder()
Constructs a new instance without a salt, no minimum hash length, the
default alphabet and no enabled
features. |
| Modifier and Type | Method and Description |
|---|---|
Hashids.Builder |
alphabet(String alphabet)
Sets the alphabet to be used for the hash generation.
|
Hashids |
build()
Builds a new configured
Hashids instance. |
Hashids.Builder |
features(HashidsFeature... features)
Enables the given instance
features. |
Hashids.Builder |
minLength(int minLength)
Sets the minimum hash length.
|
Hashids.Builder |
salt(String salt)
Sets the salt to be used as entropy.
|
public Builder()
default alphabet and no enabled
features.public Hashids.Builder salt(String salt)
By default the salt is empty.
salt - the salt to be used as entropypublic Hashids.Builder minLength(int minLength)
The default value is 0.
minLength - the minimum hash lengthpublic Hashids.Builder alphabet(String alphabet)
The default value is the default alphabet.
alphabet - the alphabet to be used for the hash generationpublic Hashids.Builder features(HashidsFeature... features)
features.
By default no features are enabled.
features - the features to be enabled for this instanceCopyright © 2017 Arctic Ice Studio