Class SafetyInstance.Builder (3.50.0)

public static final class SafetyInstance.Builder extends GeneratedMessageV3.Builder<SafetyInstance.Builder> implements SafetyInstanceOrBuilder

Spec for safety instance.

Protobuf type google.cloud.aiplatform.v1.SafetyInstance

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public SafetyInstance.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
SafetyInstance.Builder
Overrides

build()

public SafetyInstance build()
Returns
Type Description
SafetyInstance

buildPartial()

public SafetyInstance buildPartial()
Returns
Type Description
SafetyInstance

clear()

public SafetyInstance.Builder clear()
Returns
Type Description
SafetyInstance.Builder
Overrides

clearField(Descriptors.FieldDescriptor field)

public SafetyInstance.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
SafetyInstance.Builder
Overrides

clearOneof(Descriptors.OneofDescriptor oneof)

public SafetyInstance.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
SafetyInstance.Builder
Overrides

clearPrediction()

public SafetyInstance.Builder clearPrediction()

Required. Output of the evaluated model.

optional string prediction = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
SafetyInstance.Builder

This builder for chaining.

clone()

public SafetyInstance.Builder clone()
Returns
Type Description
SafetyInstance.Builder
Overrides

getDefaultInstanceForType()

public SafetyInstance getDefaultInstanceForType()
Returns
Type Description
SafetyInstance

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getPrediction()

public String getPrediction()

Required. Output of the evaluated model.

optional string prediction = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
String

The prediction.

getPredictionBytes()

public ByteString getPredictionBytes()

Required. Output of the evaluated model.

optional string prediction = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
ByteString

The bytes for prediction.

hasPrediction()

public boolean hasPrediction()

Required. Output of the evaluated model.

optional string prediction = 1 [(.google.api.field_behavior) = REQUIRED];

Returns
Type Description
boolean

Whether the prediction field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(SafetyInstance other)

public SafetyInstance.Builder mergeFrom(SafetyInstance other)
Parameter
Name Description
other SafetyInstance
Returns
Type Description
SafetyInstance.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public SafetyInstance.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
SafetyInstance.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public SafetyInstance.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
SafetyInstance.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final SafetyInstance.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
SafetyInstance.Builder
Overrides

setField(Descriptors.FieldDescriptor field, Object value)

public SafetyInstance.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
SafetyInstance.Builder
Overrides

setPrediction(String value)

public SafetyInstance.Builder setPrediction(String value)

Required. Output of the evaluated model.

optional string prediction = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value String

The prediction to set.

Returns
Type Description
SafetyInstance.Builder

This builder for chaining.

setPredictionBytes(ByteString value)

public SafetyInstance.Builder setPredictionBytes(ByteString value)

Required. Output of the evaluated model.

optional string prediction = 1 [(.google.api.field_behavior) = REQUIRED];

Parameter
Name Description
value ByteString

The bytes for prediction to set.

Returns
Type Description
SafetyInstance.Builder

This builder for chaining.

setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)

public SafetyInstance.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
SafetyInstance.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final SafetyInstance.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
SafetyInstance.Builder
Overrides