Send feedback
Class OAuthRequirements.Builder (2.13.0)
Stay organized with collections
Save and categorize content based on your preferences.
Version 2.13.0 keyboard_arrow_down
public static final class OAuthRequirements . Builder extends GeneratedMessageV3 . Builder<OAuthRequirements . Builder > implements OAuthRequirementsOrBuilder
OAuth scopes are a way to define data and permissions on data. For example,
there are scopes defined for "Read-only access to Google Calendar" and
"Access to Cloud Platform". Users can consent to a scope for an application,
giving it permission to access that data on their behalf.
OAuth scope specifications should be fairly coarse grained; a user will need
to see and understand the text description of what your scope means.
In most cases: use one or at most two OAuth scopes for an entire family of
products. If your product has multiple APIs, you should probably be sharing
the OAuth scope across all of those APIs.
When you need finer grained OAuth consent screens: talk with your product
management about how developers will use them in practice.
Please note that even though each of the canonical scopes is enough for a
request to be accepted and passed to the backend, a request can still fail
due to the backend requiring additional scopes or permissions.
Protobuf type google.api.OAuthRequirements
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 OAuthRequirements . Builder addRepeatedField ( Descriptors . FieldDescriptor field , Object value )
Parameters
Returns
Overrides
build()
public OAuthRequirements build ()
Returns
buildPartial()
public OAuthRequirements buildPartial ()
Returns
clear()
public OAuthRequirements . Builder clear ()
Returns
Overrides
clearCanonicalScopes()
public OAuthRequirements . Builder clearCanonicalScopes ()
Returns
clearField(Descriptors.FieldDescriptor field)
public OAuthRequirements . Builder clearField ( Descriptors . FieldDescriptor field )
Parameter
Returns
Overrides
clearOneof(Descriptors.OneofDescriptor oneof)
public OAuthRequirements . Builder clearOneof ( Descriptors . OneofDescriptor oneof )
Parameter
Returns
Overrides
clone()
public OAuthRequirements . Builder clone ()
Returns
Overrides
getCanonicalScopes()
public String getCanonicalScopes ()
Returns
Type Description String
The canonicalScopes.
getCanonicalScopesBytes()
public ByteString getCanonicalScopesBytes ()
Returns
Type Description ByteString
The bytes for canonicalScopes.
getDefaultInstanceForType()
public OAuthRequirements getDefaultInstanceForType ()
Returns
getDescriptorForType()
public Descriptors . Descriptor getDescriptorForType ()
Returns
Overrides
internalGetFieldAccessorTable()
protected GeneratedMessageV3 . FieldAccessorTable internalGetFieldAccessorTable ()
Returns
Overrides
isInitialized()
public final boolean isInitialized ()
Returns
Overrides
mergeFrom(OAuthRequirements other)
public OAuthRequirements . Builder mergeFrom ( OAuthRequirements other )
Parameter
Returns
public OAuthRequirements . Builder mergeFrom ( CodedInputStream input , ExtensionRegistryLite extensionRegistry )
Parameters
Returns
Overrides
Exceptions
mergeFrom(Message other)
public OAuthRequirements . Builder mergeFrom ( Message other )
Parameter
Returns
Overrides
mergeUnknownFields(UnknownFieldSet unknownFields)
public final OAuthRequirements . Builder mergeUnknownFields ( UnknownFieldSet unknownFields )
Parameter
Returns
Overrides
setCanonicalScopes(String value)
public OAuthRequirements . Builder setCanonicalScopes ( String value )
Parameter
Name Description value
String
The canonicalScopes to set.
Returns
setCanonicalScopesBytes(ByteString value)
public OAuthRequirements . Builder setCanonicalScopesBytes ( ByteString value )
Parameter
Name Description value
ByteString
The bytes for canonicalScopes to set.
Returns
setField(Descriptors.FieldDescriptor field, Object value)
public OAuthRequirements . Builder setField ( Descriptors . FieldDescriptor field , Object value )
Parameters
Returns
Overrides
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public OAuthRequirements . Builder setRepeatedField ( Descriptors . FieldDescriptor field , int index , Object value )
Parameters
Returns
Overrides
setUnknownFields(UnknownFieldSet unknownFields)
public final OAuthRequirements . Builder setUnknownFields ( UnknownFieldSet unknownFields )
Parameter
Returns
Overrides
Send feedback
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License , and code samples are licensed under the Apache 2.0 License . For details, see the Google Developers Site Policies . Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-01-27 UTC.
Need to tell us more?
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-01-27 UTC."],[],[]]