public static final class AuthRequirement.Builder extends GeneratedMessageV3.Builder<AuthRequirement.Builder> implements AuthRequirementOrBuilder
User-defined authentication requirements, including support for
JSON Web Token
(JWT).
Protobuf type google.api.AuthRequirement
Inherited Members
com.google.protobuf.GeneratedMessageV3.Builder.getUnknownFieldSetBuilder()
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownLengthDelimitedField(int,com.google.protobuf.ByteString)
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownVarintField(int,int)
com.google.protobuf.GeneratedMessageV3.Builder.parseUnknownField(com.google.protobuf.CodedInputStream,com.google.protobuf.ExtensionRegistryLite,int)
com.google.protobuf.GeneratedMessageV3.Builder.setUnknownFieldSetBuilder(com.google.protobuf.UnknownFieldSet.Builder)
Static Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Returns
Methods
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public AuthRequirement.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Returns
Overrides
build()
public AuthRequirement build()
Returns
buildPartial()
public AuthRequirement buildPartial()
Returns
clear()
public AuthRequirement.Builder clear()
Returns
Overrides
clearAudiences()
public AuthRequirement.Builder clearAudiences()
NOTE: This will be deprecated soon, once AuthProvider.audiences is
implemented and accepted in all the runtime components.
The list of JWT
audiences.
that are allowed to access. A JWT containing any of these audiences will
be accepted. When this setting is absent, only JWTs with audience
"https://Service_name/API_name"
will be accepted. For example, if no audiences are in the setting,
LibraryService API will only accept JWTs with the following audience
"https://library-example.googleapis.com/google.example.library.v1.LibraryService".
Example:
audiences: bookstore_android.apps.googleusercontent.com,
bookstore_web.apps.googleusercontent.com
string audiences = 2;
Returns
clearField(Descriptors.FieldDescriptor field)
public AuthRequirement.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Returns
Overrides
clearOneof(Descriptors.OneofDescriptor oneof)
public AuthRequirement.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Returns
Overrides
clearProviderId()
public AuthRequirement.Builder clearProviderId()
id from authentication provider.
Example:
provider_id: bookstore_auth
string provider_id = 1;
Returns
clone()
public AuthRequirement.Builder clone()
Returns
Overrides
getAudiences()
public String getAudiences()
NOTE: This will be deprecated soon, once AuthProvider.audiences is
implemented and accepted in all the runtime components.
The list of JWT
audiences.
that are allowed to access. A JWT containing any of these audiences will
be accepted. When this setting is absent, only JWTs with audience
"https://Service_name/API_name"
will be accepted. For example, if no audiences are in the setting,
LibraryService API will only accept JWTs with the following audience
"https://library-example.googleapis.com/google.example.library.v1.LibraryService".
Example:
audiences: bookstore_android.apps.googleusercontent.com,
bookstore_web.apps.googleusercontent.com
string audiences = 2;
Returns
Type | Description |
String | The audiences.
|
getAudiencesBytes()
public ByteString getAudiencesBytes()
NOTE: This will be deprecated soon, once AuthProvider.audiences is
implemented and accepted in all the runtime components.
The list of JWT
audiences.
that are allowed to access. A JWT containing any of these audiences will
be accepted. When this setting is absent, only JWTs with audience
"https://Service_name/API_name"
will be accepted. For example, if no audiences are in the setting,
LibraryService API will only accept JWTs with the following audience
"https://library-example.googleapis.com/google.example.library.v1.LibraryService".
Example:
audiences: bookstore_android.apps.googleusercontent.com,
bookstore_web.apps.googleusercontent.com
string audiences = 2;
Returns
getDefaultInstanceForType()
public AuthRequirement getDefaultInstanceForType()
Returns
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()
Returns
Overrides
getProviderId()
public String getProviderId()
id from authentication provider.
Example:
provider_id: bookstore_auth
string provider_id = 1;
Returns
Type | Description |
String | The providerId.
|
getProviderIdBytes()
public ByteString getProviderIdBytes()
id from authentication provider.
Example:
provider_id: bookstore_auth
string provider_id = 1;
Returns
Type | Description |
ByteString | The bytes for providerId.
|
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Overrides
isInitialized()
public final boolean isInitialized()
Returns
Overrides
mergeFrom(AuthRequirement other)
public AuthRequirement.Builder mergeFrom(AuthRequirement other)
Parameter
Returns
public AuthRequirement.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Returns
Overrides
Exceptions
mergeFrom(Message other)
public AuthRequirement.Builder mergeFrom(Message other)
Parameter
Returns
Overrides
mergeUnknownFields(UnknownFieldSet unknownFields)
public final AuthRequirement.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Returns
Overrides
setAudiences(String value)
public AuthRequirement.Builder setAudiences(String value)
NOTE: This will be deprecated soon, once AuthProvider.audiences is
implemented and accepted in all the runtime components.
The list of JWT
audiences.
that are allowed to access. A JWT containing any of these audiences will
be accepted. When this setting is absent, only JWTs with audience
"https://Service_name/API_name"
will be accepted. For example, if no audiences are in the setting,
LibraryService API will only accept JWTs with the following audience
"https://library-example.googleapis.com/google.example.library.v1.LibraryService".
Example:
audiences: bookstore_android.apps.googleusercontent.com,
bookstore_web.apps.googleusercontent.com
string audiences = 2;
Parameter
Name | Description |
value | String
The audiences to set.
|
Returns
setAudiencesBytes(ByteString value)
public AuthRequirement.Builder setAudiencesBytes(ByteString value)
NOTE: This will be deprecated soon, once AuthProvider.audiences is
implemented and accepted in all the runtime components.
The list of JWT
audiences.
that are allowed to access. A JWT containing any of these audiences will
be accepted. When this setting is absent, only JWTs with audience
"https://Service_name/API_name"
will be accepted. For example, if no audiences are in the setting,
LibraryService API will only accept JWTs with the following audience
"https://library-example.googleapis.com/google.example.library.v1.LibraryService".
Example:
audiences: bookstore_android.apps.googleusercontent.com,
bookstore_web.apps.googleusercontent.com
string audiences = 2;
Parameter
Name | Description |
value | ByteString
The bytes for audiences to set.
|
Returns
setField(Descriptors.FieldDescriptor field, Object value)
public AuthRequirement.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Returns
Overrides
setProviderId(String value)
public AuthRequirement.Builder setProviderId(String value)
id from authentication provider.
Example:
provider_id: bookstore_auth
string provider_id = 1;
Parameter
Name | Description |
value | String
The providerId to set.
|
Returns
setProviderIdBytes(ByteString value)
public AuthRequirement.Builder setProviderIdBytes(ByteString value)
id from authentication provider.
Example:
provider_id: bookstore_auth
string provider_id = 1;
Parameter
Name | Description |
value | ByteString
The bytes for providerId to set.
|
Returns
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public AuthRequirement.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Returns
Overrides
setUnknownFields(UnknownFieldSet unknownFields)
public final AuthRequirement.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Returns
Overrides