Class FetchAccessTokenResponse.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder
com.google.protobuf.AbstractMessage.Builder<BuilderT>
com.google.protobuf.GeneratedMessage.Builder<FetchAccessTokenResponse.Builder>
com.google.cloud.developerconnect.v1.FetchAccessTokenResponse.Builder
All Implemented Interfaces:
FetchAccessTokenResponseOrBuilder, com.google.protobuf.Message.Builder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, com.google.protobuf.MessageOrBuilder, Cloneable
Enclosing class:
FetchAccessTokenResponse

public static final class FetchAccessTokenResponse.Builder extends com.google.protobuf.GeneratedMessage.Builder<FetchAccessTokenResponse.Builder> implements FetchAccessTokenResponseOrBuilder
 Message for responding to getting an OAuth access token.
 
Protobuf type google.cloud.developerconnect.v1.FetchAccessTokenResponse
  • Method Details

    • getDescriptor

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

      protected com.google.protobuf.GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
      Specified by:
      internalGetFieldAccessorTable in class com.google.protobuf.GeneratedMessage.Builder<FetchAccessTokenResponse.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<FetchAccessTokenResponse.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<FetchAccessTokenResponse.Builder>
    • getDefaultInstanceForType

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

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

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

      public FetchAccessTokenResponse.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<FetchAccessTokenResponse.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<FetchAccessTokenResponse.Builder>
    • mergeFrom

      public FetchAccessTokenResponse.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<FetchAccessTokenResponse.Builder>
      Throws:
      IOException
    • getToken

      public String getToken()
       The token content.
       
      string token = 1;
      Specified by:
      getToken in interface FetchAccessTokenResponseOrBuilder
      Returns:
      The token.
    • getTokenBytes

      public com.google.protobuf.ByteString getTokenBytes()
       The token content.
       
      string token = 1;
      Specified by:
      getTokenBytes in interface FetchAccessTokenResponseOrBuilder
      Returns:
      The bytes for token.
    • setToken

      public FetchAccessTokenResponse.Builder setToken(String value)
       The token content.
       
      string token = 1;
      Parameters:
      value - The token to set.
      Returns:
      This builder for chaining.
    • clearToken

      public FetchAccessTokenResponse.Builder clearToken()
       The token content.
       
      string token = 1;
      Returns:
      This builder for chaining.
    • setTokenBytes

      public FetchAccessTokenResponse.Builder setTokenBytes(com.google.protobuf.ByteString value)
       The token content.
       
      string token = 1;
      Parameters:
      value - The bytes for token to set.
      Returns:
      This builder for chaining.
    • hasExpirationTime

      public boolean hasExpirationTime()
       Expiration timestamp. Can be empty if unknown or non-expiring.
       
      .google.protobuf.Timestamp expiration_time = 2;
      Specified by:
      hasExpirationTime in interface FetchAccessTokenResponseOrBuilder
      Returns:
      Whether the expirationTime field is set.
    • getExpirationTime

      public com.google.protobuf.Timestamp getExpirationTime()
       Expiration timestamp. Can be empty if unknown or non-expiring.
       
      .google.protobuf.Timestamp expiration_time = 2;
      Specified by:
      getExpirationTime in interface FetchAccessTokenResponseOrBuilder
      Returns:
      The expirationTime.
    • setExpirationTime

      public FetchAccessTokenResponse.Builder setExpirationTime(com.google.protobuf.Timestamp value)
       Expiration timestamp. Can be empty if unknown or non-expiring.
       
      .google.protobuf.Timestamp expiration_time = 2;
    • setExpirationTime

      public FetchAccessTokenResponse.Builder setExpirationTime(com.google.protobuf.Timestamp.Builder builderForValue)
       Expiration timestamp. Can be empty if unknown or non-expiring.
       
      .google.protobuf.Timestamp expiration_time = 2;
    • mergeExpirationTime

      public FetchAccessTokenResponse.Builder mergeExpirationTime(com.google.protobuf.Timestamp value)
       Expiration timestamp. Can be empty if unknown or non-expiring.
       
      .google.protobuf.Timestamp expiration_time = 2;
    • clearExpirationTime

      public FetchAccessTokenResponse.Builder clearExpirationTime()
       Expiration timestamp. Can be empty if unknown or non-expiring.
       
      .google.protobuf.Timestamp expiration_time = 2;
    • getExpirationTimeBuilder

      public com.google.protobuf.Timestamp.Builder getExpirationTimeBuilder()
       Expiration timestamp. Can be empty if unknown or non-expiring.
       
      .google.protobuf.Timestamp expiration_time = 2;
    • getExpirationTimeOrBuilder

      public com.google.protobuf.TimestampOrBuilder getExpirationTimeOrBuilder()
       Expiration timestamp. Can be empty if unknown or non-expiring.
       
      .google.protobuf.Timestamp expiration_time = 2;
      Specified by:
      getExpirationTimeOrBuilder in interface FetchAccessTokenResponseOrBuilder
    • getScopesList

      public com.google.protobuf.ProtocolStringList getScopesList()
       The scopes of the access token.
       
      repeated string scopes = 3;
      Specified by:
      getScopesList in interface FetchAccessTokenResponseOrBuilder
      Returns:
      A list containing the scopes.
    • getScopesCount

      public int getScopesCount()
       The scopes of the access token.
       
      repeated string scopes = 3;
      Specified by:
      getScopesCount in interface FetchAccessTokenResponseOrBuilder
      Returns:
      The count of scopes.
    • getScopes

      public String getScopes(int index)
       The scopes of the access token.
       
      repeated string scopes = 3;
      Specified by:
      getScopes in interface FetchAccessTokenResponseOrBuilder
      Parameters:
      index - The index of the element to return.
      Returns:
      The scopes at the given index.
    • getScopesBytes

      public com.google.protobuf.ByteString getScopesBytes(int index)
       The scopes of the access token.
       
      repeated string scopes = 3;
      Specified by:
      getScopesBytes in interface FetchAccessTokenResponseOrBuilder
      Parameters:
      index - The index of the value to return.
      Returns:
      The bytes of the scopes at the given index.
    • setScopes

      public FetchAccessTokenResponse.Builder setScopes(int index, String value)
       The scopes of the access token.
       
      repeated string scopes = 3;
      Parameters:
      index - The index to set the value at.
      value - The scopes to set.
      Returns:
      This builder for chaining.
    • addScopes

      public FetchAccessTokenResponse.Builder addScopes(String value)
       The scopes of the access token.
       
      repeated string scopes = 3;
      Parameters:
      value - The scopes to add.
      Returns:
      This builder for chaining.
    • addAllScopes

      public FetchAccessTokenResponse.Builder addAllScopes(Iterable<String> values)
       The scopes of the access token.
       
      repeated string scopes = 3;
      Parameters:
      values - The scopes to add.
      Returns:
      This builder for chaining.
    • clearScopes

      public FetchAccessTokenResponse.Builder clearScopes()
       The scopes of the access token.
       
      repeated string scopes = 3;
      Returns:
      This builder for chaining.
    • addScopesBytes

      public FetchAccessTokenResponse.Builder addScopesBytes(com.google.protobuf.ByteString value)
       The scopes of the access token.
       
      repeated string scopes = 3;
      Parameters:
      value - The bytes of the scopes to add.
      Returns:
      This builder for chaining.
    • hasExchangeError

      public boolean hasExchangeError()
       The error resulted from exchanging OAuth tokens from the service provider.
       
      .google.cloud.developerconnect.v1.ExchangeError exchange_error = 4;
      Specified by:
      hasExchangeError in interface FetchAccessTokenResponseOrBuilder
      Returns:
      Whether the exchangeError field is set.
    • getExchangeError

      public ExchangeError getExchangeError()
       The error resulted from exchanging OAuth tokens from the service provider.
       
      .google.cloud.developerconnect.v1.ExchangeError exchange_error = 4;
      Specified by:
      getExchangeError in interface FetchAccessTokenResponseOrBuilder
      Returns:
      The exchangeError.
    • setExchangeError

      public FetchAccessTokenResponse.Builder setExchangeError(ExchangeError value)
       The error resulted from exchanging OAuth tokens from the service provider.
       
      .google.cloud.developerconnect.v1.ExchangeError exchange_error = 4;
    • setExchangeError

      public FetchAccessTokenResponse.Builder setExchangeError(ExchangeError.Builder builderForValue)
       The error resulted from exchanging OAuth tokens from the service provider.
       
      .google.cloud.developerconnect.v1.ExchangeError exchange_error = 4;
    • mergeExchangeError

      public FetchAccessTokenResponse.Builder mergeExchangeError(ExchangeError value)
       The error resulted from exchanging OAuth tokens from the service provider.
       
      .google.cloud.developerconnect.v1.ExchangeError exchange_error = 4;
    • clearExchangeError

      public FetchAccessTokenResponse.Builder clearExchangeError()
       The error resulted from exchanging OAuth tokens from the service provider.
       
      .google.cloud.developerconnect.v1.ExchangeError exchange_error = 4;
    • getExchangeErrorBuilder

      public ExchangeError.Builder getExchangeErrorBuilder()
       The error resulted from exchanging OAuth tokens from the service provider.
       
      .google.cloud.developerconnect.v1.ExchangeError exchange_error = 4;
    • getExchangeErrorOrBuilder

      public ExchangeErrorOrBuilder getExchangeErrorOrBuilder()
       The error resulted from exchanging OAuth tokens from the service provider.
       
      .google.cloud.developerconnect.v1.ExchangeError exchange_error = 4;
      Specified by:
      getExchangeErrorOrBuilder in interface FetchAccessTokenResponseOrBuilder