public static final class SafetyRating.Builder extends GeneratedMessageV3.Builder<SafetyRating.Builder> implements SafetyRatingOrBuilder
Safety rating corresponding to the generated content.
Protobuf type google.cloud.vertexai.v1.SafetyRating
Inherited Members
com.google.protobuf.GeneratedMessageV3.Builder.getUnknownFieldSetBuilder()
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMapFieldReflection(int)
com.google.protobuf.GeneratedMessageV3.Builder.internalGetMutableMapFieldReflection(int)
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownLengthDelimitedField(int,com.google.protobuf.ByteString)
com.google.protobuf.GeneratedMessageV3.Builder.mergeUnknownVarintField(int,int)
com.google.protobuf.GeneratedMessageV3.Builder.parseUnknownField(com.google.protobuf.CodedInputStream,com.google.protobuf.ExtensionRegistryLite,int)
com.google.protobuf.GeneratedMessageV3.Builder.setUnknownFieldSetBuilder(com.google.protobuf.UnknownFieldSet.Builder)
Static Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()
Methods
addRepeatedField(Descriptors.FieldDescriptor field, Object value)
public SafetyRating.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Overrides
build()
public SafetyRating build()
buildPartial()
public SafetyRating buildPartial()
clear()
public SafetyRating.Builder clear()
Overrides
clearBlocked()
public SafetyRating.Builder clearBlocked()
Output only. Indicates whether the content was filtered out because of this
rating.
bool blocked = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
clearCategory()
public SafetyRating.Builder clearCategory()
Output only. Harm category.
.google.cloud.vertexai.v1.HarmCategory category = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
clearField(Descriptors.FieldDescriptor field)
public SafetyRating.Builder clearField(Descriptors.FieldDescriptor field)
Overrides
clearOneof(Descriptors.OneofDescriptor oneof)
public SafetyRating.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Overrides
clearProbability()
public SafetyRating.Builder clearProbability()
Output only. Harm probability levels in the content.
.google.cloud.vertexai.v1.SafetyRating.HarmProbability probability = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
clone()
public SafetyRating.Builder clone()
Overrides
getBlocked()
public boolean getBlocked()
Output only. Indicates whether the content was filtered out because of this
rating.
bool blocked = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns |
Type |
Description |
boolean |
The blocked.
|
getCategory()
public HarmCategory getCategory()
Output only. Harm category.
.google.cloud.vertexai.v1.HarmCategory category = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
getCategoryValue()
public int getCategoryValue()
Output only. Harm category.
.google.cloud.vertexai.v1.HarmCategory category = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns |
Type |
Description |
int |
The enum numeric value on the wire for category.
|
getDefaultInstanceForType()
public SafetyRating getDefaultInstanceForType()
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()
Overrides
getProbability()
public SafetyRating.HarmProbability getProbability()
Output only. Harm probability levels in the content.
.google.cloud.vertexai.v1.SafetyRating.HarmProbability probability = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
getProbabilityValue()
public int getProbabilityValue()
Output only. Harm probability levels in the content.
.google.cloud.vertexai.v1.SafetyRating.HarmProbability probability = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Returns |
Type |
Description |
int |
The enum numeric value on the wire for probability.
|
internalGetFieldAccessorTable()
protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Overrides
isInitialized()
public final boolean isInitialized()
Overrides
mergeFrom(SafetyRating other)
public SafetyRating.Builder mergeFrom(SafetyRating other)
public SafetyRating.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Overrides
mergeFrom(Message other)
public SafetyRating.Builder mergeFrom(Message other)
Parameter |
Name |
Description |
other |
Message
|
Overrides
mergeUnknownFields(UnknownFieldSet unknownFields)
public final SafetyRating.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Overrides
setBlocked(boolean value)
public SafetyRating.Builder setBlocked(boolean value)
Output only. Indicates whether the content was filtered out because of this
rating.
bool blocked = 3 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter |
Name |
Description |
value |
boolean
The blocked to set.
|
setCategory(HarmCategory value)
public SafetyRating.Builder setCategory(HarmCategory value)
Output only. Harm category.
.google.cloud.vertexai.v1.HarmCategory category = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter |
Name |
Description |
value |
HarmCategory
The category to set.
|
setCategoryValue(int value)
public SafetyRating.Builder setCategoryValue(int value)
Output only. Harm category.
.google.cloud.vertexai.v1.HarmCategory category = 1 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter |
Name |
Description |
value |
int
The enum numeric value on the wire for category to set.
|
setField(Descriptors.FieldDescriptor field, Object value)
public SafetyRating.Builder setField(Descriptors.FieldDescriptor field, Object value)
Overrides
setProbability(SafetyRating.HarmProbability value)
public SafetyRating.Builder setProbability(SafetyRating.HarmProbability value)
Output only. Harm probability levels in the content.
.google.cloud.vertexai.v1.SafetyRating.HarmProbability probability = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
setProbabilityValue(int value)
public SafetyRating.Builder setProbabilityValue(int value)
Output only. Harm probability levels in the content.
.google.cloud.vertexai.v1.SafetyRating.HarmProbability probability = 2 [(.google.api.field_behavior) = OUTPUT_ONLY];
Parameter |
Name |
Description |
value |
int
The enum numeric value on the wire for probability to set.
|
setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
public SafetyRating.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Overrides
setUnknownFields(UnknownFieldSet unknownFields)
public final SafetyRating.Builder setUnknownFields(UnknownFieldSet unknownFields)
Overrides