Class JOSEHeader.PublicKeyBuilder
java.lang.Object
de.christofreichardt.json.websignature.JOSEHeader.PublicKeyBuilder
- All Implemented Interfaces:
de.christofreichardt.diagnosis.Traceable
- Enclosing class:
JOSEHeader
public static final class JOSEHeader.PublicKeyBuilder
extends Object
implements de.christofreichardt.diagnosis.Traceable
A builder for a
JOSEHeader preconfigured with a JSON web (public) key.- Author:
- Christof Reichardt
-
Constructor Summary
ConstructorsConstructorDescriptionPublicKeyBuilder(JsonWebPublicKey jsonWebPublicKey) Creates the builder preconfigured with the givenJsonWebPublicKey. -
Method Summary
Modifier and TypeMethodDescriptionbuild()Builds theJOSEHeaderinstance with the configured parameters.de.christofreichardt.diagnosis.AbstractTracerAugments the builder instance with the "kid" parameter.Augments the builder instance with the "typ" parameter.
-
Constructor Details
-
PublicKeyBuilder
Creates the builder preconfigured with the givenJsonWebPublicKey.- Parameters:
jsonWebPublicKey- the requestedJsonWebPublicKey.
-
-
Method Details
-
withKid
Augments the builder instance with the "kid" parameter.- Parameters:
kid- denotes the key ID.- Returns:
- this
PublicKeyBuilderinstance. - See Also:
-
withTyp
Augments the builder instance with the "typ" parameter.- Parameters:
typ- denotes the (media) type- Returns:
- this
PublicKeyBuilderinstance - See Also:
-
build
Builds theJOSEHeaderinstance with the configured parameters.- Returns:
- the appropriately configured
JOSEHeaderinstance
-
getCurrentTracer
public de.christofreichardt.diagnosis.AbstractTracer getCurrentTracer()- Specified by:
getCurrentTracerin interfacede.christofreichardt.diagnosis.Traceable
-