getHeader
Deserializes the token header as type T.
Return
the header deserialized into an instance of T
Parameters
jsonInstance
the Json instance to use for deserialization; defaults to the library's Jwt.defaultJsonParser configuration (ignoreUnknownKeys = true, explicitNulls = false)
Type Parameters
T
the target type to deserialize the header into
fun <T> getHeader(serializer: KSerializer<T>, jsonInstance: Json = Jwt.defaultJsonParser): T(source)
Deserializes the token header using the given serializer.
Return
the header deserialized into an instance of T
Parameters
serializer
the KSerializer used to deserialize the header
jsonInstance
the Json instance to use for deserialization; defaults to the library's Jwt.defaultJsonParser configuration (ignoreUnknownKeys = true, explicitNulls = false)
Type Parameters
T
the target type to deserialize the header into