Class DeviceCodeOAuthFlow.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<DeviceCodeOAuthFlow.Builder>
org.a2aproject.sdk.grpc.DeviceCodeOAuthFlow.Builder
All Implemented Interfaces:
com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable, DeviceCodeOAuthFlowOrBuilder
Enclosing class:
DeviceCodeOAuthFlow

public static final class DeviceCodeOAuthFlow.Builder extends com.google.protobuf.GeneratedMessage.Builder<DeviceCodeOAuthFlow.Builder> implements DeviceCodeOAuthFlowOrBuilder
 Defines configuration details for the OAuth 2.0 Device Code flow (RFC 8628).
 This flow is designed for input-constrained devices such as IoT devices,
 and CLI tools where the user authenticates on a separate device.
 
Protobuf type lf.a2a.v1.DeviceCodeOAuthFlow
  • Method Details

    • getDescriptor

      public static final com.google.protobuf.Descriptors.Descriptor getDescriptor()
    • internalGetMapFieldReflection

      protected com.google.protobuf.MapFieldReflectionAccessor internalGetMapFieldReflection(int number)
      Overrides:
      internalGetMapFieldReflection in class com.google.protobuf.GeneratedMessage.Builder<DeviceCodeOAuthFlow.Builder>
    • internalGetMutableMapFieldReflection

      protected com.google.protobuf.MapFieldReflectionAccessor internalGetMutableMapFieldReflection(int number)
      Overrides:
      internalGetMutableMapFieldReflection in class com.google.protobuf.GeneratedMessage.Builder<DeviceCodeOAuthFlow.Builder>
    • internalGetFieldAccessorTable

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessage.Builder<DeviceCodeOAuthFlow.Builder>
    • clear

      Specified by:
      clear in interface com.google.protobuf.Message.Builder
      Specified by:
      clear in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      clear in class com.google.protobuf.GeneratedMessage.Builder<DeviceCodeOAuthFlow.Builder>
    • getDescriptorForType

      public com.google.protobuf.Descriptors.Descriptor getDescriptorForType()
      Specified by:
      getDescriptorForType in interface com.google.protobuf.Message.Builder
      Specified by:
      getDescriptorForType in interface com.google.protobuf.MessageOrBuilder
      Overrides:
      getDescriptorForType in class com.google.protobuf.GeneratedMessage.Builder<DeviceCodeOAuthFlow.Builder>
    • getDefaultInstanceForType

      public DeviceCodeOAuthFlow getDefaultInstanceForType()
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageLiteOrBuilder
      Specified by:
      getDefaultInstanceForType in interface com.google.protobuf.MessageOrBuilder
    • build

      public DeviceCodeOAuthFlow build()
      Specified by:
      build in interface com.google.protobuf.Message.Builder
      Specified by:
      build in interface com.google.protobuf.MessageLite.Builder
    • buildPartial

      public DeviceCodeOAuthFlow buildPartial()
      Specified by:
      buildPartial in interface com.google.protobuf.Message.Builder
      Specified by:
      buildPartial in interface com.google.protobuf.MessageLite.Builder
    • mergeFrom

      public DeviceCodeOAuthFlow.Builder mergeFrom(com.google.protobuf.Message other)
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<DeviceCodeOAuthFlow.Builder>
    • mergeFrom

    • isInitialized

      public final boolean isInitialized()
      Specified by:
      isInitialized in interface com.google.protobuf.MessageLiteOrBuilder
      Overrides:
      isInitialized in class com.google.protobuf.GeneratedMessage.Builder<DeviceCodeOAuthFlow.Builder>
    • mergeFrom

      public DeviceCodeOAuthFlow.Builder mergeFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry) throws IOException
      Specified by:
      mergeFrom in interface com.google.protobuf.Message.Builder
      Specified by:
      mergeFrom in interface com.google.protobuf.MessageLite.Builder
      Overrides:
      mergeFrom in class com.google.protobuf.AbstractMessage.Builder<DeviceCodeOAuthFlow.Builder>
      Throws:
      IOException
    • getDeviceAuthorizationUrl

      public String getDeviceAuthorizationUrl()
       The device authorization endpoint URL.
       
      string device_authorization_url = 1 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      getDeviceAuthorizationUrl in interface DeviceCodeOAuthFlowOrBuilder
      Returns:
      The deviceAuthorizationUrl.
    • getDeviceAuthorizationUrlBytes

      public com.google.protobuf.ByteString getDeviceAuthorizationUrlBytes()
       The device authorization endpoint URL.
       
      string device_authorization_url = 1 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      getDeviceAuthorizationUrlBytes in interface DeviceCodeOAuthFlowOrBuilder
      Returns:
      The bytes for deviceAuthorizationUrl.
    • setDeviceAuthorizationUrl

      public DeviceCodeOAuthFlow.Builder setDeviceAuthorizationUrl(String value)
       The device authorization endpoint URL.
       
      string device_authorization_url = 1 [(.google.api.field_behavior) = REQUIRED];
      Parameters:
      value - The deviceAuthorizationUrl to set.
      Returns:
      This builder for chaining.
    • clearDeviceAuthorizationUrl

      public DeviceCodeOAuthFlow.Builder clearDeviceAuthorizationUrl()
       The device authorization endpoint URL.
       
      string device_authorization_url = 1 [(.google.api.field_behavior) = REQUIRED];
      Returns:
      This builder for chaining.
    • setDeviceAuthorizationUrlBytes

      public DeviceCodeOAuthFlow.Builder setDeviceAuthorizationUrlBytes(com.google.protobuf.ByteString value)
       The device authorization endpoint URL.
       
      string device_authorization_url = 1 [(.google.api.field_behavior) = REQUIRED];
      Parameters:
      value - The bytes for deviceAuthorizationUrl to set.
      Returns:
      This builder for chaining.
    • getTokenUrl

      public String getTokenUrl()
       The token URL to be used for this flow.
       
      string token_url = 2 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      getTokenUrl in interface DeviceCodeOAuthFlowOrBuilder
      Returns:
      The tokenUrl.
    • getTokenUrlBytes

      public com.google.protobuf.ByteString getTokenUrlBytes()
       The token URL to be used for this flow.
       
      string token_url = 2 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      getTokenUrlBytes in interface DeviceCodeOAuthFlowOrBuilder
      Returns:
      The bytes for tokenUrl.
    • setTokenUrl

      public DeviceCodeOAuthFlow.Builder setTokenUrl(String value)
       The token URL to be used for this flow.
       
      string token_url = 2 [(.google.api.field_behavior) = REQUIRED];
      Parameters:
      value - The tokenUrl to set.
      Returns:
      This builder for chaining.
    • clearTokenUrl

      public DeviceCodeOAuthFlow.Builder clearTokenUrl()
       The token URL to be used for this flow.
       
      string token_url = 2 [(.google.api.field_behavior) = REQUIRED];
      Returns:
      This builder for chaining.
    • setTokenUrlBytes

      public DeviceCodeOAuthFlow.Builder setTokenUrlBytes(com.google.protobuf.ByteString value)
       The token URL to be used for this flow.
       
      string token_url = 2 [(.google.api.field_behavior) = REQUIRED];
      Parameters:
      value - The bytes for tokenUrl to set.
      Returns:
      This builder for chaining.
    • getRefreshUrl

      public String getRefreshUrl()
       The URL to be used for obtaining refresh tokens.
       
      string refresh_url = 3;
      Specified by:
      getRefreshUrl in interface DeviceCodeOAuthFlowOrBuilder
      Returns:
      The refreshUrl.
    • getRefreshUrlBytes

      public com.google.protobuf.ByteString getRefreshUrlBytes()
       The URL to be used for obtaining refresh tokens.
       
      string refresh_url = 3;
      Specified by:
      getRefreshUrlBytes in interface DeviceCodeOAuthFlowOrBuilder
      Returns:
      The bytes for refreshUrl.
    • setRefreshUrl

      public DeviceCodeOAuthFlow.Builder setRefreshUrl(String value)
       The URL to be used for obtaining refresh tokens.
       
      string refresh_url = 3;
      Parameters:
      value - The refreshUrl to set.
      Returns:
      This builder for chaining.
    • clearRefreshUrl

      public DeviceCodeOAuthFlow.Builder clearRefreshUrl()
       The URL to be used for obtaining refresh tokens.
       
      string refresh_url = 3;
      Returns:
      This builder for chaining.
    • setRefreshUrlBytes

      public DeviceCodeOAuthFlow.Builder setRefreshUrlBytes(com.google.protobuf.ByteString value)
       The URL to be used for obtaining refresh tokens.
       
      string refresh_url = 3;
      Parameters:
      value - The bytes for refreshUrl to set.
      Returns:
      This builder for chaining.
    • getScopesCount

      public int getScopesCount()
      Description copied from interface: DeviceCodeOAuthFlowOrBuilder
       The available scopes for the OAuth2 security scheme.
       
      map<string, string> scopes = 4 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      getScopesCount in interface DeviceCodeOAuthFlowOrBuilder
    • containsScopes

      public boolean containsScopes(String key)
       The available scopes for the OAuth2 security scheme.
       
      map<string, string> scopes = 4 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      containsScopes in interface DeviceCodeOAuthFlowOrBuilder
    • getScopes

      @Deprecated public Map<String,String> getScopes()
      Deprecated.
      Use getScopesMap() instead.
      Specified by:
      getScopes in interface DeviceCodeOAuthFlowOrBuilder
    • getScopesMap

      public Map<String,String> getScopesMap()
       The available scopes for the OAuth2 security scheme.
       
      map<string, string> scopes = 4 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      getScopesMap in interface DeviceCodeOAuthFlowOrBuilder
    • getScopesOrDefault

      public String getScopesOrDefault(String key, String defaultValue)
       The available scopes for the OAuth2 security scheme.
       
      map<string, string> scopes = 4 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      getScopesOrDefault in interface DeviceCodeOAuthFlowOrBuilder
    • getScopesOrThrow

      public String getScopesOrThrow(String key)
       The available scopes for the OAuth2 security scheme.
       
      map<string, string> scopes = 4 [(.google.api.field_behavior) = REQUIRED];
      Specified by:
      getScopesOrThrow in interface DeviceCodeOAuthFlowOrBuilder
    • clearScopes

      public DeviceCodeOAuthFlow.Builder clearScopes()
    • removeScopes

      public DeviceCodeOAuthFlow.Builder removeScopes(String key)
       The available scopes for the OAuth2 security scheme.
       
      map<string, string> scopes = 4 [(.google.api.field_behavior) = REQUIRED];
    • getMutableScopes

      @Deprecated public Map<String,String> getMutableScopes()
      Deprecated.
      Use alternate mutation accessors instead.
    • putScopes

      public DeviceCodeOAuthFlow.Builder putScopes(String key, String value)
       The available scopes for the OAuth2 security scheme.
       
      map<string, string> scopes = 4 [(.google.api.field_behavior) = REQUIRED];
    • putAllScopes

      public DeviceCodeOAuthFlow.Builder putAllScopes(Map<String,String> values)
       The available scopes for the OAuth2 security scheme.
       
      map<string, string> scopes = 4 [(.google.api.field_behavior) = REQUIRED];