Class SafetyInstance.Builder (3.41.0)

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

Spec for safety instance.

Protobuf type google.cloud.aiplatform.v1beta1.SafetyInstance

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
TypeDescription
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public SafetyInstance.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
SafetyInstance.Builder
Overrides

build()

public SafetyInstance build()
Returns
TypeDescription
SafetyInstance

buildPartial()

public SafetyInstance buildPartial()
Returns
TypeDescription
SafetyInstance

clear()

public SafetyInstance.Builder clear()
Returns
TypeDescription
SafetyInstance.Builder
Overrides

clearField(Descriptors.FieldDescriptor field)

public SafetyInstance.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
NameDescription
fieldFieldDescriptor
Returns
TypeDescription
SafetyInstance.Builder
Overrides

clearOneof(Descriptors.OneofDescriptor oneof)

public SafetyInstance.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
NameDescription
oneofOneofDescriptor
Returns
TypeDescription
SafetyInstance.Builder
Overrides

clearPrediction()

public SafetyInstance.Builder clearPrediction()

Required. Output of the evaluated model.

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

Returns
TypeDescription
SafetyInstance.Builder

This builder for chaining.

clone()

public SafetyInstance.Builder clone()
Returns
TypeDescription
SafetyInstance.Builder
Overrides

getDefaultInstanceForType()

public SafetyInstance getDefaultInstanceForType()
Returns
TypeDescription
SafetyInstance

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getPrediction()

public String getPrediction()

Required. Output of the evaluated model.

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

Returns
TypeDescription
String

The prediction.

getPredictionBytes()

public ByteString getPredictionBytes()

Required. Output of the evaluated model.

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

Returns
TypeDescription
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
TypeDescription
boolean

Whether the prediction field is set.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(SafetyInstance other)

public SafetyInstance.Builder mergeFrom(SafetyInstance other)
Parameter
NameDescription
otherSafetyInstance
Returns
TypeDescription
SafetyInstance.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public SafetyInstance.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
NameDescription
inputCodedInputStream
extensionRegistryExtensionRegistryLite
Returns
TypeDescription
SafetyInstance.Builder
Overrides
Exceptions
TypeDescription
IOException

mergeFrom(Message other)

public SafetyInstance.Builder mergeFrom(Message other)
Parameter
NameDescription
otherMessage
Returns
TypeDescription
SafetyInstance.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final SafetyInstance.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
SafetyInstance.Builder
Overrides

setField(Descriptors.FieldDescriptor field, Object value)

public SafetyInstance.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
NameDescription
fieldFieldDescriptor
valueObject
Returns
TypeDescription
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
NameDescription
valueString

The prediction to set.

Returns
TypeDescription
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
NameDescription
valueByteString

The bytes for prediction to set.

Returns
TypeDescription
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
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
SafetyInstance.Builder
Overrides

setUnknownFields(UnknownFieldSet unknownFields)

public final SafetyInstance.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
NameDescription
unknownFieldsUnknownFieldSet
Returns
TypeDescription
SafetyInstance.Builder
Overrides