Class JwkOctet.Builder
java.lang.Object
io.helidon.security.jwt.jwk.JwkOctet.Builder
- All Implemented Interfaces:
Builder<JwkOctet.Builder, JwkOctet>, Supplier<JwkOctet>
- Enclosing class:
JwkOctet
public static final class JwkOctet.Builder
extends Object
implements Builder<JwkOctet.Builder, JwkOctet>
Builder for
JwkOctet.-
Method Summary
Modifier and TypeMethodDescriptionaddOperation(String operation) Add intended operation of this JWK.Algorithm of the key being built.build()Build a newJwkOctetinstance from this builder.fromJson(JsonObject json) Update this builder from JWK in json format.Key id of the key being built.Key type of the key being built.operations(List<String> operations) Intended operations of this JWK.Intended usage of this JWK.Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface Builder
get, identity, updateModifier and TypeMethodDescriptiondefault JwkOctetget()default JwkOctet.Builderidentity()Instance of this builder as the correct type.default JwkOctet.Builderupdate(Consumer<JwkOctet.Builder> consumer) Update the builder in a fluent API way.
-
Method Details
-
fromJson
Update this builder from JWK in json format. Note that the"k"must be base64 encoded. -
build
-
keyType
Key type of the key being built.- Parameters:
keyType- one of supported key types- Returns:
- updated builder instance
- See Also:
-
keyId
Key id of the key being built. Note that within one set of keysJwkKeysthis must be unique.- Parameters:
keyId- key id to map from a signed entity (such as JWT) to JWK definition- Returns:
- updated builder instance
-
algorithm
Algorithm of the key being built. Algorithm is optional (each type may have a reasonable default).- Parameters:
algorithm- see each key type for supported algorithms- Returns:
- updated builder instance
- See Also:
-
usage
Intended usage of this JWK. You may configure usage,operationsor neither (never both).- Parameters:
usage- usage of this JWK- Returns:
- updated builder instance
- See Also:
-
operations
Intended operations of this JWK. You may configure operations,usageor neither (never both).- Parameters:
operations- operations to use, replaces existing operations- Returns:
- updated builder instance
-
addOperation
Add intended operation of this JWK. You may configure operations,usageor neither (never both).- Parameters:
operation- operation to add to list of operations- Returns:
- updated builder instance
-