T
- the type of object to return to the parser caller after handling the parsed JWT.Jwt.accept(JwtVisitor)
.@Deprecated public interface JwtHandler<T> extends JwtVisitor<T>
JwtParser
after parsing a JWT to indicate the exact
type of JWT, JWS or JWE parsed.Modifier and Type | Method and Description |
---|---|
T |
onClaimsJwe(Jwe<Claims> jwe)
Deprecated.
This method is invoked when a
JwtParser determines that the parsed JWT is
a valid Claims JWE. |
T |
onClaimsJws(Jws<Claims> jws)
Deprecated.
This method is invoked when a
JwtParser determines that the parsed JWT is
a valid Claims JWS. |
T |
onClaimsJwt(Jwt<Header,Claims> jwt)
Deprecated.
This method is invoked when a
JwtParser determines that the parsed JWT is
a Claims JWT. |
T |
onContentJwe(Jwe<byte[]> jwe)
Deprecated.
This method is invoked when a
JwtParser determines that the parsed JWT is
a content JWE. |
T |
onContentJws(Jws<byte[]> jws)
Deprecated.
This method is invoked when a
JwtParser determines that the parsed JWT is
a content JWS. |
T |
onContentJwt(Jwt<Header,byte[]> jwt)
Deprecated.
This method is invoked when a
JwtParser determines that the parsed JWT is
an unsecured content JWT. |
visit, visit, visit
T onContentJwt(Jwt<Header,byte[]> jwt)
JwtParser
determines that the parsed JWT is
an unsecured content JWT. An unsecured content JWT has a byte array payload that is not
cryptographically signed or encrypted. If the JWT creator set the (optional)
contentType
header value, the application may inspect that value to determine
how to convert the byte array to the final content type as desired.jwt
- the parsed unsecured content JWTnull
if no return value is necessary.T onClaimsJwt(Jwt<Header,Claims> jwt)
JwtParser
determines that the parsed JWT is
a Claims JWT. A Claims JWT has a Claims
payload that is not cryptographically signed or encrypted.jwt
- the parsed claims JWTnull
if no return value is necessary.T onContentJws(Jws<byte[]> jws)
JwtParser
determines that the parsed JWT is
a content JWS. A content JWS is a JWT with a byte array payload that has been cryptographically signed.
If the JWT creator set the (optional) contentType
header value, the
application may inspect that value to determine how to convert the byte array to the final content type
as desired.
This method will only be invoked if the cryptographic signature can be successfully verified.
jws
- the parsed content JWSnull
if no return value is necessary.T onClaimsJws(Jws<Claims> jws)
JwtParser
determines that the parsed JWT is
a valid Claims JWS. A Claims JWS is a JWT with a Claims
payload that has been cryptographically signed.
This method will only be invoked if the cryptographic signature can be successfully verified.
jws
- the parsed claims JWSnull
if no return value is necessary.T onContentJwe(Jwe<byte[]> jwe)
JwtParser
determines that the parsed JWT is
a content JWE. A content JWE is a JWE with a byte array payload that has been encrypted. If the JWT creator set
the (optional) contentType
header value, the application may inspect that
value to determine how to convert the byte array to the final content type as desired.
This method will only be invoked if the content JWE can be successfully decrypted.
jwe
- the parsed content jwenull
if no return value is necessary.T onClaimsJwe(Jwe<Claims> jwe)
JwtParser
determines that the parsed JWT is
a valid Claims JWE. A Claims JWE is a JWT with a Claims
payload that has been encrypted.
This method will only be invoked if the Claims JWE can be successfully decrypted.
jwe
- the parsed claims jwenull
if no return value is necessary.Copyright © 2014–2025 jsonwebtoken.io. All rights reserved.