Class PredictResponse.Builder

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

public static final class PredictResponse.Builder extends com.google.protobuf.GeneratedMessage.Builder<PredictResponse.Builder> implements PredictResponseOrBuilder
 Response message for
 [PredictionService.Predict][google.cloud.aiplatform.v1.PredictionService.Predict].
 
Protobuf type google.cloud.aiplatform.v1.PredictResponse
  • 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<PredictResponse.Builder>
    • clear

      public PredictResponse.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<PredictResponse.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<PredictResponse.Builder>
    • getDefaultInstanceForType

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

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

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

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

      public PredictResponse.Builder mergeFrom(PredictResponse other)
    • isInitialized

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

      public PredictResponse.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<PredictResponse.Builder>
      Throws:
      IOException
    • getPredictionsList

      public List<com.google.protobuf.Value> getPredictionsList()
       The predictions that are the output of the predictions call.
       The schema of any single prediction may be specified via Endpoint's
       DeployedModels' [Model's ][google.cloud.aiplatform.v1.DeployedModel.model]
       [PredictSchemata's][google.cloud.aiplatform.v1.Model.predict_schemata]
       [prediction_schema_uri][google.cloud.aiplatform.v1.PredictSchemata.prediction_schema_uri].
       
      repeated .google.protobuf.Value predictions = 1;
      Specified by:
      getPredictionsList in interface PredictResponseOrBuilder
    • getPredictionsCount

      public int getPredictionsCount()
       The predictions that are the output of the predictions call.
       The schema of any single prediction may be specified via Endpoint's
       DeployedModels' [Model's ][google.cloud.aiplatform.v1.DeployedModel.model]
       [PredictSchemata's][google.cloud.aiplatform.v1.Model.predict_schemata]
       [prediction_schema_uri][google.cloud.aiplatform.v1.PredictSchemata.prediction_schema_uri].
       
      repeated .google.protobuf.Value predictions = 1;
      Specified by:
      getPredictionsCount in interface PredictResponseOrBuilder
    • getPredictions

      public com.google.protobuf.Value getPredictions(int index)
       The predictions that are the output of the predictions call.
       The schema of any single prediction may be specified via Endpoint's
       DeployedModels' [Model's ][google.cloud.aiplatform.v1.DeployedModel.model]
       [PredictSchemata's][google.cloud.aiplatform.v1.Model.predict_schemata]
       [prediction_schema_uri][google.cloud.aiplatform.v1.PredictSchemata.prediction_schema_uri].
       
      repeated .google.protobuf.Value predictions = 1;
      Specified by:
      getPredictions in interface PredictResponseOrBuilder
    • setPredictions

      public PredictResponse.Builder setPredictions(int index, com.google.protobuf.Value value)
       The predictions that are the output of the predictions call.
       The schema of any single prediction may be specified via Endpoint's
       DeployedModels' [Model's ][google.cloud.aiplatform.v1.DeployedModel.model]
       [PredictSchemata's][google.cloud.aiplatform.v1.Model.predict_schemata]
       [prediction_schema_uri][google.cloud.aiplatform.v1.PredictSchemata.prediction_schema_uri].
       
      repeated .google.protobuf.Value predictions = 1;
    • setPredictions

      public PredictResponse.Builder setPredictions(int index, com.google.protobuf.Value.Builder builderForValue)
       The predictions that are the output of the predictions call.
       The schema of any single prediction may be specified via Endpoint's
       DeployedModels' [Model's ][google.cloud.aiplatform.v1.DeployedModel.model]
       [PredictSchemata's][google.cloud.aiplatform.v1.Model.predict_schemata]
       [prediction_schema_uri][google.cloud.aiplatform.v1.PredictSchemata.prediction_schema_uri].
       
      repeated .google.protobuf.Value predictions = 1;
    • addPredictions

      public PredictResponse.Builder addPredictions(com.google.protobuf.Value value)
       The predictions that are the output of the predictions call.
       The schema of any single prediction may be specified via Endpoint's
       DeployedModels' [Model's ][google.cloud.aiplatform.v1.DeployedModel.model]
       [PredictSchemata's][google.cloud.aiplatform.v1.Model.predict_schemata]
       [prediction_schema_uri][google.cloud.aiplatform.v1.PredictSchemata.prediction_schema_uri].
       
      repeated .google.protobuf.Value predictions = 1;
    • addPredictions

      public PredictResponse.Builder addPredictions(int index, com.google.protobuf.Value value)
       The predictions that are the output of the predictions call.
       The schema of any single prediction may be specified via Endpoint's
       DeployedModels' [Model's ][google.cloud.aiplatform.v1.DeployedModel.model]
       [PredictSchemata's][google.cloud.aiplatform.v1.Model.predict_schemata]
       [prediction_schema_uri][google.cloud.aiplatform.v1.PredictSchemata.prediction_schema_uri].
       
      repeated .google.protobuf.Value predictions = 1;
    • addPredictions

      public PredictResponse.Builder addPredictions(com.google.protobuf.Value.Builder builderForValue)
       The predictions that are the output of the predictions call.
       The schema of any single prediction may be specified via Endpoint's
       DeployedModels' [Model's ][google.cloud.aiplatform.v1.DeployedModel.model]
       [PredictSchemata's][google.cloud.aiplatform.v1.Model.predict_schemata]
       [prediction_schema_uri][google.cloud.aiplatform.v1.PredictSchemata.prediction_schema_uri].
       
      repeated .google.protobuf.Value predictions = 1;
    • addPredictions

      public PredictResponse.Builder addPredictions(int index, com.google.protobuf.Value.Builder builderForValue)
       The predictions that are the output of the predictions call.
       The schema of any single prediction may be specified via Endpoint's
       DeployedModels' [Model's ][google.cloud.aiplatform.v1.DeployedModel.model]
       [PredictSchemata's][google.cloud.aiplatform.v1.Model.predict_schemata]
       [prediction_schema_uri][google.cloud.aiplatform.v1.PredictSchemata.prediction_schema_uri].
       
      repeated .google.protobuf.Value predictions = 1;
    • addAllPredictions

      public PredictResponse.Builder addAllPredictions(Iterable<? extends com.google.protobuf.Value> values)
       The predictions that are the output of the predictions call.
       The schema of any single prediction may be specified via Endpoint's
       DeployedModels' [Model's ][google.cloud.aiplatform.v1.DeployedModel.model]
       [PredictSchemata's][google.cloud.aiplatform.v1.Model.predict_schemata]
       [prediction_schema_uri][google.cloud.aiplatform.v1.PredictSchemata.prediction_schema_uri].
       
      repeated .google.protobuf.Value predictions = 1;
    • clearPredictions

      public PredictResponse.Builder clearPredictions()
       The predictions that are the output of the predictions call.
       The schema of any single prediction may be specified via Endpoint's
       DeployedModels' [Model's ][google.cloud.aiplatform.v1.DeployedModel.model]
       [PredictSchemata's][google.cloud.aiplatform.v1.Model.predict_schemata]
       [prediction_schema_uri][google.cloud.aiplatform.v1.PredictSchemata.prediction_schema_uri].
       
      repeated .google.protobuf.Value predictions = 1;
    • removePredictions

      public PredictResponse.Builder removePredictions(int index)
       The predictions that are the output of the predictions call.
       The schema of any single prediction may be specified via Endpoint's
       DeployedModels' [Model's ][google.cloud.aiplatform.v1.DeployedModel.model]
       [PredictSchemata's][google.cloud.aiplatform.v1.Model.predict_schemata]
       [prediction_schema_uri][google.cloud.aiplatform.v1.PredictSchemata.prediction_schema_uri].
       
      repeated .google.protobuf.Value predictions = 1;
    • getPredictionsBuilder

      public com.google.protobuf.Value.Builder getPredictionsBuilder(int index)
       The predictions that are the output of the predictions call.
       The schema of any single prediction may be specified via Endpoint's
       DeployedModels' [Model's ][google.cloud.aiplatform.v1.DeployedModel.model]
       [PredictSchemata's][google.cloud.aiplatform.v1.Model.predict_schemata]
       [prediction_schema_uri][google.cloud.aiplatform.v1.PredictSchemata.prediction_schema_uri].
       
      repeated .google.protobuf.Value predictions = 1;
    • getPredictionsOrBuilder

      public com.google.protobuf.ValueOrBuilder getPredictionsOrBuilder(int index)
       The predictions that are the output of the predictions call.
       The schema of any single prediction may be specified via Endpoint's
       DeployedModels' [Model's ][google.cloud.aiplatform.v1.DeployedModel.model]
       [PredictSchemata's][google.cloud.aiplatform.v1.Model.predict_schemata]
       [prediction_schema_uri][google.cloud.aiplatform.v1.PredictSchemata.prediction_schema_uri].
       
      repeated .google.protobuf.Value predictions = 1;
      Specified by:
      getPredictionsOrBuilder in interface PredictResponseOrBuilder
    • getPredictionsOrBuilderList

      public List<? extends com.google.protobuf.ValueOrBuilder> getPredictionsOrBuilderList()
       The predictions that are the output of the predictions call.
       The schema of any single prediction may be specified via Endpoint's
       DeployedModels' [Model's ][google.cloud.aiplatform.v1.DeployedModel.model]
       [PredictSchemata's][google.cloud.aiplatform.v1.Model.predict_schemata]
       [prediction_schema_uri][google.cloud.aiplatform.v1.PredictSchemata.prediction_schema_uri].
       
      repeated .google.protobuf.Value predictions = 1;
      Specified by:
      getPredictionsOrBuilderList in interface PredictResponseOrBuilder
    • addPredictionsBuilder

      public com.google.protobuf.Value.Builder addPredictionsBuilder()
       The predictions that are the output of the predictions call.
       The schema of any single prediction may be specified via Endpoint's
       DeployedModels' [Model's ][google.cloud.aiplatform.v1.DeployedModel.model]
       [PredictSchemata's][google.cloud.aiplatform.v1.Model.predict_schemata]
       [prediction_schema_uri][google.cloud.aiplatform.v1.PredictSchemata.prediction_schema_uri].
       
      repeated .google.protobuf.Value predictions = 1;
    • addPredictionsBuilder

      public com.google.protobuf.Value.Builder addPredictionsBuilder(int index)
       The predictions that are the output of the predictions call.
       The schema of any single prediction may be specified via Endpoint's
       DeployedModels' [Model's ][google.cloud.aiplatform.v1.DeployedModel.model]
       [PredictSchemata's][google.cloud.aiplatform.v1.Model.predict_schemata]
       [prediction_schema_uri][google.cloud.aiplatform.v1.PredictSchemata.prediction_schema_uri].
       
      repeated .google.protobuf.Value predictions = 1;
    • getPredictionsBuilderList

      public List<com.google.protobuf.Value.Builder> getPredictionsBuilderList()
       The predictions that are the output of the predictions call.
       The schema of any single prediction may be specified via Endpoint's
       DeployedModels' [Model's ][google.cloud.aiplatform.v1.DeployedModel.model]
       [PredictSchemata's][google.cloud.aiplatform.v1.Model.predict_schemata]
       [prediction_schema_uri][google.cloud.aiplatform.v1.PredictSchemata.prediction_schema_uri].
       
      repeated .google.protobuf.Value predictions = 1;
    • getDeployedModelId

      public String getDeployedModelId()
       ID of the Endpoint's DeployedModel that served this prediction.
       
      string deployed_model_id = 2;
      Specified by:
      getDeployedModelId in interface PredictResponseOrBuilder
      Returns:
      The deployedModelId.
    • getDeployedModelIdBytes

      public com.google.protobuf.ByteString getDeployedModelIdBytes()
       ID of the Endpoint's DeployedModel that served this prediction.
       
      string deployed_model_id = 2;
      Specified by:
      getDeployedModelIdBytes in interface PredictResponseOrBuilder
      Returns:
      The bytes for deployedModelId.
    • setDeployedModelId

      public PredictResponse.Builder setDeployedModelId(String value)
       ID of the Endpoint's DeployedModel that served this prediction.
       
      string deployed_model_id = 2;
      Parameters:
      value - The deployedModelId to set.
      Returns:
      This builder for chaining.
    • clearDeployedModelId

      public PredictResponse.Builder clearDeployedModelId()
       ID of the Endpoint's DeployedModel that served this prediction.
       
      string deployed_model_id = 2;
      Returns:
      This builder for chaining.
    • setDeployedModelIdBytes

      public PredictResponse.Builder setDeployedModelIdBytes(com.google.protobuf.ByteString value)
       ID of the Endpoint's DeployedModel that served this prediction.
       
      string deployed_model_id = 2;
      Parameters:
      value - The bytes for deployedModelId to set.
      Returns:
      This builder for chaining.
    • getModel

      public String getModel()
       Output only. The resource name of the Model which is deployed as the
       DeployedModel that this prediction hits.
       
      string model = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
      Specified by:
      getModel in interface PredictResponseOrBuilder
      Returns:
      The model.
    • getModelBytes

      public com.google.protobuf.ByteString getModelBytes()
       Output only. The resource name of the Model which is deployed as the
       DeployedModel that this prediction hits.
       
      string model = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
      Specified by:
      getModelBytes in interface PredictResponseOrBuilder
      Returns:
      The bytes for model.
    • setModel

      public PredictResponse.Builder setModel(String value)
       Output only. The resource name of the Model which is deployed as the
       DeployedModel that this prediction hits.
       
      string model = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
      Parameters:
      value - The model to set.
      Returns:
      This builder for chaining.
    • clearModel

      public PredictResponse.Builder clearModel()
       Output only. The resource name of the Model which is deployed as the
       DeployedModel that this prediction hits.
       
      string model = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
      Returns:
      This builder for chaining.
    • setModelBytes

      public PredictResponse.Builder setModelBytes(com.google.protobuf.ByteString value)
       Output only. The resource name of the Model which is deployed as the
       DeployedModel that this prediction hits.
       
      string model = 3 [(.google.api.field_behavior) = OUTPUT_ONLY, (.google.api.resource_reference) = { ... }
      Parameters:
      value - The bytes for model to set.
      Returns:
      This builder for chaining.
    • getModelVersionId

      public String getModelVersionId()
       Output only. The version ID of the Model which is deployed as the
       DeployedModel that this prediction hits.
       
      string model_version_id = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getModelVersionId in interface PredictResponseOrBuilder
      Returns:
      The modelVersionId.
    • getModelVersionIdBytes

      public com.google.protobuf.ByteString getModelVersionIdBytes()
       Output only. The version ID of the Model which is deployed as the
       DeployedModel that this prediction hits.
       
      string model_version_id = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getModelVersionIdBytes in interface PredictResponseOrBuilder
      Returns:
      The bytes for modelVersionId.
    • setModelVersionId

      public PredictResponse.Builder setModelVersionId(String value)
       Output only. The version ID of the Model which is deployed as the
       DeployedModel that this prediction hits.
       
      string model_version_id = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Parameters:
      value - The modelVersionId to set.
      Returns:
      This builder for chaining.
    • clearModelVersionId

      public PredictResponse.Builder clearModelVersionId()
       Output only. The version ID of the Model which is deployed as the
       DeployedModel that this prediction hits.
       
      string model_version_id = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Returns:
      This builder for chaining.
    • setModelVersionIdBytes

      public PredictResponse.Builder setModelVersionIdBytes(com.google.protobuf.ByteString value)
       Output only. The version ID of the Model which is deployed as the
       DeployedModel that this prediction hits.
       
      string model_version_id = 5 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Parameters:
      value - The bytes for modelVersionId to set.
      Returns:
      This builder for chaining.
    • getModelDisplayName

      public String getModelDisplayName()
       Output only. The [display
       name][google.cloud.aiplatform.v1.Model.display_name] of the Model which is
       deployed as the DeployedModel that this prediction hits.
       
      string model_display_name = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getModelDisplayName in interface PredictResponseOrBuilder
      Returns:
      The modelDisplayName.
    • getModelDisplayNameBytes

      public com.google.protobuf.ByteString getModelDisplayNameBytes()
       Output only. The [display
       name][google.cloud.aiplatform.v1.Model.display_name] of the Model which is
       deployed as the DeployedModel that this prediction hits.
       
      string model_display_name = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getModelDisplayNameBytes in interface PredictResponseOrBuilder
      Returns:
      The bytes for modelDisplayName.
    • setModelDisplayName

      public PredictResponse.Builder setModelDisplayName(String value)
       Output only. The [display
       name][google.cloud.aiplatform.v1.Model.display_name] of the Model which is
       deployed as the DeployedModel that this prediction hits.
       
      string model_display_name = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Parameters:
      value - The modelDisplayName to set.
      Returns:
      This builder for chaining.
    • clearModelDisplayName

      public PredictResponse.Builder clearModelDisplayName()
       Output only. The [display
       name][google.cloud.aiplatform.v1.Model.display_name] of the Model which is
       deployed as the DeployedModel that this prediction hits.
       
      string model_display_name = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Returns:
      This builder for chaining.
    • setModelDisplayNameBytes

      public PredictResponse.Builder setModelDisplayNameBytes(com.google.protobuf.ByteString value)
       Output only. The [display
       name][google.cloud.aiplatform.v1.Model.display_name] of the Model which is
       deployed as the DeployedModel that this prediction hits.
       
      string model_display_name = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Parameters:
      value - The bytes for modelDisplayName to set.
      Returns:
      This builder for chaining.
    • hasMetadata

      public boolean hasMetadata()
       Output only. Request-level metadata returned by the model. The metadata
       type will be dependent upon the model implementation.
       
      .google.protobuf.Value metadata = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      hasMetadata in interface PredictResponseOrBuilder
      Returns:
      Whether the metadata field is set.
    • getMetadata

      public com.google.protobuf.Value getMetadata()
       Output only. Request-level metadata returned by the model. The metadata
       type will be dependent upon the model implementation.
       
      .google.protobuf.Value metadata = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getMetadata in interface PredictResponseOrBuilder
      Returns:
      The metadata.
    • setMetadata

      public PredictResponse.Builder setMetadata(com.google.protobuf.Value value)
       Output only. Request-level metadata returned by the model. The metadata
       type will be dependent upon the model implementation.
       
      .google.protobuf.Value metadata = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • setMetadata

      public PredictResponse.Builder setMetadata(com.google.protobuf.Value.Builder builderForValue)
       Output only. Request-level metadata returned by the model. The metadata
       type will be dependent upon the model implementation.
       
      .google.protobuf.Value metadata = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • mergeMetadata

      public PredictResponse.Builder mergeMetadata(com.google.protobuf.Value value)
       Output only. Request-level metadata returned by the model. The metadata
       type will be dependent upon the model implementation.
       
      .google.protobuf.Value metadata = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • clearMetadata

      public PredictResponse.Builder clearMetadata()
       Output only. Request-level metadata returned by the model. The metadata
       type will be dependent upon the model implementation.
       
      .google.protobuf.Value metadata = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • getMetadataBuilder

      public com.google.protobuf.Value.Builder getMetadataBuilder()
       Output only. Request-level metadata returned by the model. The metadata
       type will be dependent upon the model implementation.
       
      .google.protobuf.Value metadata = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
    • getMetadataOrBuilder

      public com.google.protobuf.ValueOrBuilder getMetadataOrBuilder()
       Output only. Request-level metadata returned by the model. The metadata
       type will be dependent upon the model implementation.
       
      .google.protobuf.Value metadata = 6 [(.google.api.field_behavior) = OUTPUT_ONLY];
      Specified by:
      getMetadataOrBuilder in interface PredictResponseOrBuilder