Class ComputeTokensResponse.Builder

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

public static final class ComputeTokensResponse.Builder extends com.google.protobuf.GeneratedMessage.Builder<ComputeTokensResponse.Builder> implements ComputeTokensResponseOrBuilder
 Response message for ComputeTokens RPC call.
 
Protobuf type google.cloud.aiplatform.v1.ComputeTokensResponse
  • 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<ComputeTokensResponse.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<ComputeTokensResponse.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<ComputeTokensResponse.Builder>
    • getDefaultInstanceForType

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

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

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

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

      public ComputeTokensResponse.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<ComputeTokensResponse.Builder>
      Throws:
      IOException
    • getTokensInfoList

      public List<TokensInfo> getTokensInfoList()
       Lists of tokens info from the input. A ComputeTokensRequest could have
       multiple instances with a prompt in each instance. We also need to return
       lists of tokens info for the request with multiple instances.
       
      repeated .google.cloud.aiplatform.v1.TokensInfo tokens_info = 1;
      Specified by:
      getTokensInfoList in interface ComputeTokensResponseOrBuilder
    • getTokensInfoCount

      public int getTokensInfoCount()
       Lists of tokens info from the input. A ComputeTokensRequest could have
       multiple instances with a prompt in each instance. We also need to return
       lists of tokens info for the request with multiple instances.
       
      repeated .google.cloud.aiplatform.v1.TokensInfo tokens_info = 1;
      Specified by:
      getTokensInfoCount in interface ComputeTokensResponseOrBuilder
    • getTokensInfo

      public TokensInfo getTokensInfo(int index)
       Lists of tokens info from the input. A ComputeTokensRequest could have
       multiple instances with a prompt in each instance. We also need to return
       lists of tokens info for the request with multiple instances.
       
      repeated .google.cloud.aiplatform.v1.TokensInfo tokens_info = 1;
      Specified by:
      getTokensInfo in interface ComputeTokensResponseOrBuilder
    • setTokensInfo

      public ComputeTokensResponse.Builder setTokensInfo(int index, TokensInfo value)
       Lists of tokens info from the input. A ComputeTokensRequest could have
       multiple instances with a prompt in each instance. We also need to return
       lists of tokens info for the request with multiple instances.
       
      repeated .google.cloud.aiplatform.v1.TokensInfo tokens_info = 1;
    • setTokensInfo

      public ComputeTokensResponse.Builder setTokensInfo(int index, TokensInfo.Builder builderForValue)
       Lists of tokens info from the input. A ComputeTokensRequest could have
       multiple instances with a prompt in each instance. We also need to return
       lists of tokens info for the request with multiple instances.
       
      repeated .google.cloud.aiplatform.v1.TokensInfo tokens_info = 1;
    • addTokensInfo

      public ComputeTokensResponse.Builder addTokensInfo(TokensInfo value)
       Lists of tokens info from the input. A ComputeTokensRequest could have
       multiple instances with a prompt in each instance. We also need to return
       lists of tokens info for the request with multiple instances.
       
      repeated .google.cloud.aiplatform.v1.TokensInfo tokens_info = 1;
    • addTokensInfo

      public ComputeTokensResponse.Builder addTokensInfo(int index, TokensInfo value)
       Lists of tokens info from the input. A ComputeTokensRequest could have
       multiple instances with a prompt in each instance. We also need to return
       lists of tokens info for the request with multiple instances.
       
      repeated .google.cloud.aiplatform.v1.TokensInfo tokens_info = 1;
    • addTokensInfo

      public ComputeTokensResponse.Builder addTokensInfo(TokensInfo.Builder builderForValue)
       Lists of tokens info from the input. A ComputeTokensRequest could have
       multiple instances with a prompt in each instance. We also need to return
       lists of tokens info for the request with multiple instances.
       
      repeated .google.cloud.aiplatform.v1.TokensInfo tokens_info = 1;
    • addTokensInfo

      public ComputeTokensResponse.Builder addTokensInfo(int index, TokensInfo.Builder builderForValue)
       Lists of tokens info from the input. A ComputeTokensRequest could have
       multiple instances with a prompt in each instance. We also need to return
       lists of tokens info for the request with multiple instances.
       
      repeated .google.cloud.aiplatform.v1.TokensInfo tokens_info = 1;
    • addAllTokensInfo

      public ComputeTokensResponse.Builder addAllTokensInfo(Iterable<? extends TokensInfo> values)
       Lists of tokens info from the input. A ComputeTokensRequest could have
       multiple instances with a prompt in each instance. We also need to return
       lists of tokens info for the request with multiple instances.
       
      repeated .google.cloud.aiplatform.v1.TokensInfo tokens_info = 1;
    • clearTokensInfo

      public ComputeTokensResponse.Builder clearTokensInfo()
       Lists of tokens info from the input. A ComputeTokensRequest could have
       multiple instances with a prompt in each instance. We also need to return
       lists of tokens info for the request with multiple instances.
       
      repeated .google.cloud.aiplatform.v1.TokensInfo tokens_info = 1;
    • removeTokensInfo

      public ComputeTokensResponse.Builder removeTokensInfo(int index)
       Lists of tokens info from the input. A ComputeTokensRequest could have
       multiple instances with a prompt in each instance. We also need to return
       lists of tokens info for the request with multiple instances.
       
      repeated .google.cloud.aiplatform.v1.TokensInfo tokens_info = 1;
    • getTokensInfoBuilder

      public TokensInfo.Builder getTokensInfoBuilder(int index)
       Lists of tokens info from the input. A ComputeTokensRequest could have
       multiple instances with a prompt in each instance. We also need to return
       lists of tokens info for the request with multiple instances.
       
      repeated .google.cloud.aiplatform.v1.TokensInfo tokens_info = 1;
    • getTokensInfoOrBuilder

      public TokensInfoOrBuilder getTokensInfoOrBuilder(int index)
       Lists of tokens info from the input. A ComputeTokensRequest could have
       multiple instances with a prompt in each instance. We also need to return
       lists of tokens info for the request with multiple instances.
       
      repeated .google.cloud.aiplatform.v1.TokensInfo tokens_info = 1;
      Specified by:
      getTokensInfoOrBuilder in interface ComputeTokensResponseOrBuilder
    • getTokensInfoOrBuilderList

      public List<? extends TokensInfoOrBuilder> getTokensInfoOrBuilderList()
       Lists of tokens info from the input. A ComputeTokensRequest could have
       multiple instances with a prompt in each instance. We also need to return
       lists of tokens info for the request with multiple instances.
       
      repeated .google.cloud.aiplatform.v1.TokensInfo tokens_info = 1;
      Specified by:
      getTokensInfoOrBuilderList in interface ComputeTokensResponseOrBuilder
    • addTokensInfoBuilder

      public TokensInfo.Builder addTokensInfoBuilder()
       Lists of tokens info from the input. A ComputeTokensRequest could have
       multiple instances with a prompt in each instance. We also need to return
       lists of tokens info for the request with multiple instances.
       
      repeated .google.cloud.aiplatform.v1.TokensInfo tokens_info = 1;
    • addTokensInfoBuilder

      public TokensInfo.Builder addTokensInfoBuilder(int index)
       Lists of tokens info from the input. A ComputeTokensRequest could have
       multiple instances with a prompt in each instance. We also need to return
       lists of tokens info for the request with multiple instances.
       
      repeated .google.cloud.aiplatform.v1.TokensInfo tokens_info = 1;
    • getTokensInfoBuilderList

      public List<TokensInfo.Builder> getTokensInfoBuilderList()
       Lists of tokens info from the input. A ComputeTokensRequest could have
       multiple instances with a prompt in each instance. We also need to return
       lists of tokens info for the request with multiple instances.
       
      repeated .google.cloud.aiplatform.v1.TokensInfo tokens_info = 1;