Class JwtLocation (2.37.1)

public final class JwtLocation extends GeneratedMessageV3 implements JwtLocationOrBuilder

Specifies a location to extract JWT from an API request.

Protobuf type google.api.JwtLocation

Static Fields

public static final int COOKIE_FIELD_NUMBER
Field Value
TypeDescription
int

HEADER_FIELD_NUMBER

public static final int HEADER_FIELD_NUMBER
Field Value
TypeDescription
int

QUERY_FIELD_NUMBER

public static final int QUERY_FIELD_NUMBER
Field Value
TypeDescription
int

VALUE_PREFIX_FIELD_NUMBER

public static final int VALUE_PREFIX_FIELD_NUMBER
Field Value
TypeDescription
int

Static Methods

getDefaultInstance()

public static JwtLocation getDefaultInstance()
Returns
TypeDescription
JwtLocation

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

newBuilder()

public static JwtLocation.Builder newBuilder()
Returns
TypeDescription
JwtLocation.Builder

newBuilder(JwtLocation prototype)

public static JwtLocation.Builder newBuilder(JwtLocation prototype)
Parameter
NameDescription
prototypeJwtLocation
Returns
TypeDescription
JwtLocation.Builder

parseDelimitedFrom(InputStream input)

public static JwtLocation parseDelimitedFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
JwtLocation
Exceptions
TypeDescription
IOException

parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static JwtLocation parseDelimitedFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
JwtLocation
Exceptions
TypeDescription
IOException

parseFrom(byte[] data)

public static JwtLocation parseFrom(byte[] data)
Parameter
NameDescription
databyte[]
Returns
TypeDescription
JwtLocation
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)

public static JwtLocation parseFrom(byte[] data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
databyte[]
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
JwtLocation
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data)

public static JwtLocation parseFrom(ByteString data)
Parameter
NameDescription
dataByteString
Returns
TypeDescription
JwtLocation
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)

public static JwtLocation parseFrom(ByteString data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteString
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
JwtLocation
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(CodedInputStream input)

public static JwtLocation parseFrom(CodedInputStream input)
Parameter
NameDescription
inputCodedInputStream
Returns
TypeDescription
JwtLocation
Exceptions
TypeDescription
IOException

parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public static JwtLocation parseFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
JwtLocation
Exceptions
TypeDescription
IOException

parseFrom(InputStream input)

public static JwtLocation parseFrom(InputStream input)
Parameter
NameDescription
inputInputStream
Returns
TypeDescription
JwtLocation
Exceptions
TypeDescription
IOException

parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)

public static JwtLocation parseFrom(InputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
JwtLocation
Exceptions
TypeDescription
IOException

parseFrom(ByteBuffer data)

public static JwtLocation parseFrom(ByteBuffer data)
Parameter
NameDescription
dataByteBuffer
Returns
TypeDescription
JwtLocation
Exceptions
TypeDescription
InvalidProtocolBufferException

parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)

public static JwtLocation parseFrom(ByteBuffer data, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
dataByteBuffer
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
JwtLocation
Exceptions
TypeDescription
InvalidProtocolBufferException

parser()

public static Parser<JwtLocation> parser()
Returns
TypeDescription
Parser<JwtLocation>

Methods

equals(Object obj)

public boolean equals(Object obj)
Parameter
NameDescription
objObject
Returns
TypeDescription
boolean
Overrides

getCookie()

public String getCookie()

Specifies cookie name to extract JWT token.

string cookie = 4;

Returns
TypeDescription
String

The cookie.

getCookieBytes()

public ByteString getCookieBytes()

Specifies cookie name to extract JWT token.

string cookie = 4;

Returns
TypeDescription
ByteString

The bytes for cookie.

getDefaultInstanceForType()

public JwtLocation getDefaultInstanceForType()
Returns
TypeDescription
JwtLocation

getHeader()

public String getHeader()

Specifies HTTP header name to extract JWT token.

string header = 1;

Returns
TypeDescription
String

The header.

getHeaderBytes()

public ByteString getHeaderBytes()

Specifies HTTP header name to extract JWT token.

string header = 1;

Returns
TypeDescription
ByteString

The bytes for header.

getInCase()

public JwtLocation.InCase getInCase()
Returns
TypeDescription
JwtLocation.InCase

getParserForType()

public Parser<JwtLocation> getParserForType()
Returns
TypeDescription
Parser<JwtLocation>
Overrides

getQuery()

public String getQuery()

Specifies URL query parameter name to extract JWT token.

string query = 2;

Returns
TypeDescription
String

The query.

getQueryBytes()

public ByteString getQueryBytes()

Specifies URL query parameter name to extract JWT token.

string query = 2;

Returns
TypeDescription
ByteString

The bytes for query.

getSerializedSize()

public int getSerializedSize()
Returns
TypeDescription
int
Overrides

getValuePrefix()

public String getValuePrefix()

The value prefix. The value format is "value_prefix{token}" Only applies to "in" header type. Must be empty for "in" query type. If not empty, the header value has to match (case sensitive) this prefix. If not matched, JWT will not be extracted. If matched, JWT will be extracted after the prefix is removed.

For example, for "Authorization: Bearer {JWT}", value_prefix="Bearer " with a space at the end.

string value_prefix = 3;

Returns
TypeDescription
String

The valuePrefix.

getValuePrefixBytes()

public ByteString getValuePrefixBytes()

The value prefix. The value format is "value_prefix{token}" Only applies to "in" header type. Must be empty for "in" query type. If not empty, the header value has to match (case sensitive) this prefix. If not matched, JWT will not be extracted. If matched, JWT will be extracted after the prefix is removed.

For example, for "Authorization: Bearer {JWT}", value_prefix="Bearer " with a space at the end.

string value_prefix = 3;

Returns
TypeDescription
ByteString

The bytes for valuePrefix.

hasCookie()

public boolean hasCookie()

Specifies cookie name to extract JWT token.

string cookie = 4;

Returns
TypeDescription
boolean

Whether the cookie field is set.

hasHeader()

public boolean hasHeader()

Specifies HTTP header name to extract JWT token.

string header = 1;

Returns
TypeDescription
boolean

Whether the header field is set.

hasQuery()

public boolean hasQuery()

Specifies URL query parameter name to extract JWT token.

string query = 2;

Returns
TypeDescription
boolean

Whether the query field is set.

hashCode()

public int hashCode()
Returns
TypeDescription
int
Overrides

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

newBuilderForType()

public JwtLocation.Builder newBuilderForType()
Returns
TypeDescription
JwtLocation.Builder

newBuilderForType(GeneratedMessageV3.BuilderParent parent)

protected JwtLocation.Builder newBuilderForType(GeneratedMessageV3.BuilderParent parent)
Parameter
NameDescription
parentBuilderParent
Returns
TypeDescription
JwtLocation.Builder
Overrides

newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)

protected Object newInstance(GeneratedMessageV3.UnusedPrivateParameter unused)
Parameter
NameDescription
unusedUnusedPrivateParameter
Returns
TypeDescription
Object
Overrides

toBuilder()

public JwtLocation.Builder toBuilder()
Returns
TypeDescription
JwtLocation.Builder

writeTo(CodedOutputStream output)

public void writeTo(CodedOutputStream output)
Parameter
NameDescription
outputCodedOutputStream
Overrides
Exceptions
TypeDescription
IOException