Class SignatureBaseLine
java.lang.Object
com.authlete.hms.SignatureBaseLine
A class representing
signature-base-line
defined in RFC 9421
HTTP Message Signatures, Section 2.5. Creating the Signature Base.- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionSignatureBaseLine
(ComponentIdentifier identifier, String value) A constructor with a component identifier and a component value. -
Method Summary
Modifier and TypeMethodDescriptionGet the component identifier.Get the component value.Serialize the signature base line represented by this instance, and return the resulting string.Serialize the signature base line represented by this instance, and write the resulting string into the specified string builder.toString()
Get the string representation of this instance, which is the serialized signature base line returned by theserialize()
method.
-
Constructor Details
-
SignatureBaseLine
A constructor with a component identifier and a component value.- Parameters:
identifier
- A component identifier.value
- A component value. This should not be null when the identifier refers to a derived component.- Throws:
IllegalArgumentException
- The identifier is null.
-
-
Method Details
-
toString
Get the string representation of this instance, which is the serialized signature base line returned by theserialize()
method. -
serialize
Serialize the signature base line represented by this instance, and return the resulting string.- Returns:
- The serialized signature base line represented by this instance.
-
serializeTo
Serialize the signature base line represented by this instance, and write the resulting string into the specified string builder.The ABNF for signature base line from RFC 9421 HTTP Message Signatures, 2.5. Creating the Signature Base:
signature-base-line = component-identifier ":" SP ( derived-component-value / *field-content ) ; no obs-fold nor obs-text
- Parameters:
sb
- A string builder into which the resulting string is written.- Returns:
- The same string builder that was passed as the argument.
-
getComponentIdentifier
Get the component identifier.- Returns:
- The component identifier.
-
getComponentValue
-