public enum JwtHeaderKey extends Enum<JwtHeaderKey>
As described in the JWT specification, the reserved JWT header parameters are listed,
Enum Constant and Description |
---|
ALG
Algorithm JWT header parameter.
|
CUSTOM
Generic header key for a custom header parameter.
|
TYP
Type JWT header parameter..
|
Modifier and Type | Method and Description |
---|---|
static JwtHeaderKey |
getHeaderKey(String headerKey)
Gets the JwtHeaderKey constant that matches the given String.
|
String |
toString()
Turns the JwtHeaderKey constant into a lowercase String.
|
String |
value()
Returns a lowercase String of the JwtHeaderKey constant.
|
static JwtHeaderKey |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static JwtHeaderKey[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final JwtHeaderKey TYP
public static final JwtHeaderKey ALG
public static final JwtHeaderKey CUSTOM
public static JwtHeaderKey[] values()
for (JwtHeaderKey c : JwtHeaderKey.values()) System.out.println(c);
public static JwtHeaderKey valueOf(String name)
name
- the name of the enum constant to be returned.IllegalArgumentException
- if this enum type has no constant with the specified nameNullPointerException
- if the argument is nullpublic String value()
JwtHeaderKey.toString()
public static JwtHeaderKey getHeaderKey(String headerKey)
If the given String does not match any of the constants, then CUSTOM is returned.
headerKey
- The String representation of a JwtHeaderKey.public String toString()
toString
in class Enum<JwtHeaderKey>
Copyright © 2010-2018, ForgeRock All Rights Reserved.