public static final class Guardrail.ModelSafety.SafetySetting.Builder extends GeneratedMessage.Builder<Guardrail.ModelSafety.SafetySetting.Builder> implements Guardrail.ModelSafety.SafetySettingOrBuilderSafety setting.
Protobuf type google.cloud.ces.v1.Guardrail.ModelSafety.SafetySetting
Inheritance
java.lang.Object > AbstractMessageLite.Builder<MessageType,BuilderType> > AbstractMessage.Builder<BuilderType> > GeneratedMessage.Builder > Guardrail.ModelSafety.SafetySetting.BuilderImplements
Guardrail.ModelSafety.SafetySettingOrBuilderStatic Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()| Returns | |
|---|---|
| Type | Description |
Descriptor |
|
Methods
build()
public Guardrail.ModelSafety.SafetySetting build()| Returns | |
|---|---|
| Type | Description |
Guardrail.ModelSafety.SafetySetting |
|
buildPartial()
public Guardrail.ModelSafety.SafetySetting buildPartial()| Returns | |
|---|---|
| Type | Description |
Guardrail.ModelSafety.SafetySetting |
|
clear()
public Guardrail.ModelSafety.SafetySetting.Builder clear()| Returns | |
|---|---|
| Type | Description |
Guardrail.ModelSafety.SafetySetting.Builder |
|
clearCategory()
public Guardrail.ModelSafety.SafetySetting.Builder clearCategory()Required. The harm category.
.google.cloud.ces.v1.Guardrail.ModelSafety.HarmCategory category = 1 [(.google.api.field_behavior) = REQUIRED];
| Returns | |
|---|---|
| Type | Description |
Guardrail.ModelSafety.SafetySetting.Builder |
This builder for chaining. |
clearThreshold()
public Guardrail.ModelSafety.SafetySetting.Builder clearThreshold()Required. The harm block threshold.
.google.cloud.ces.v1.Guardrail.ModelSafety.HarmBlockThreshold threshold = 2 [(.google.api.field_behavior) = REQUIRED];
| Returns | |
|---|---|
| Type | Description |
Guardrail.ModelSafety.SafetySetting.Builder |
This builder for chaining. |
getCategory()
public Guardrail.ModelSafety.HarmCategory getCategory()Required. The harm category.
.google.cloud.ces.v1.Guardrail.ModelSafety.HarmCategory category = 1 [(.google.api.field_behavior) = REQUIRED];
| Returns | |
|---|---|
| Type | Description |
Guardrail.ModelSafety.HarmCategory |
The category. |
getCategoryValue()
public int getCategoryValue()Required. The harm category.
.google.cloud.ces.v1.Guardrail.ModelSafety.HarmCategory category = 1 [(.google.api.field_behavior) = REQUIRED];
| Returns | |
|---|---|
| Type | Description |
int |
The enum numeric value on the wire for category. |
getDefaultInstanceForType()
public Guardrail.ModelSafety.SafetySetting getDefaultInstanceForType()| Returns | |
|---|---|
| Type | Description |
Guardrail.ModelSafety.SafetySetting |
|
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()| Returns | |
|---|---|
| Type | Description |
Descriptor |
|
getThreshold()
public Guardrail.ModelSafety.HarmBlockThreshold getThreshold()Required. The harm block threshold.
.google.cloud.ces.v1.Guardrail.ModelSafety.HarmBlockThreshold threshold = 2 [(.google.api.field_behavior) = REQUIRED];
| Returns | |
|---|---|
| Type | Description |
Guardrail.ModelSafety.HarmBlockThreshold |
The threshold. |
getThresholdValue()
public int getThresholdValue()Required. The harm block threshold.
.google.cloud.ces.v1.Guardrail.ModelSafety.HarmBlockThreshold threshold = 2 [(.google.api.field_behavior) = REQUIRED];
| Returns | |
|---|---|
| Type | Description |
int |
The enum numeric value on the wire for threshold. |
internalGetFieldAccessorTable()
protected GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()| Returns | |
|---|---|
| Type | Description |
FieldAccessorTable |
|
isInitialized()
public final boolean isInitialized()| Returns | |
|---|---|
| Type | Description |
boolean |
|
mergeFrom(Guardrail.ModelSafety.SafetySetting other)
public Guardrail.ModelSafety.SafetySetting.Builder mergeFrom(Guardrail.ModelSafety.SafetySetting other)| Parameter | |
|---|---|
| Name | Description |
other |
Guardrail.ModelSafety.SafetySetting |
| Returns | |
|---|---|
| Type | Description |
Guardrail.ModelSafety.SafetySetting.Builder |
|
mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public Guardrail.ModelSafety.SafetySetting.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)| Parameters | |
|---|---|
| Name | Description |
input |
CodedInputStream |
extensionRegistry |
ExtensionRegistryLite |
| Returns | |
|---|---|
| Type | Description |
Guardrail.ModelSafety.SafetySetting.Builder |
|
| Exceptions | |
|---|---|
| Type | Description |
IOException |
|
mergeFrom(Message other)
public Guardrail.ModelSafety.SafetySetting.Builder mergeFrom(Message other)| Parameter | |
|---|---|
| Name | Description |
other |
Message |
| Returns | |
|---|---|
| Type | Description |
Guardrail.ModelSafety.SafetySetting.Builder |
|
setCategory(Guardrail.ModelSafety.HarmCategory value)
public Guardrail.ModelSafety.SafetySetting.Builder setCategory(Guardrail.ModelSafety.HarmCategory value)Required. The harm category.
.google.cloud.ces.v1.Guardrail.ModelSafety.HarmCategory category = 1 [(.google.api.field_behavior) = REQUIRED];
| Parameter | |
|---|---|
| Name | Description |
value |
Guardrail.ModelSafety.HarmCategoryThe category to set. |
| Returns | |
|---|---|
| Type | Description |
Guardrail.ModelSafety.SafetySetting.Builder |
This builder for chaining. |
setCategoryValue(int value)
public Guardrail.ModelSafety.SafetySetting.Builder setCategoryValue(int value)Required. The harm category.
.google.cloud.ces.v1.Guardrail.ModelSafety.HarmCategory category = 1 [(.google.api.field_behavior) = REQUIRED];
| Parameter | |
|---|---|
| Name | Description |
value |
intThe enum numeric value on the wire for category to set. |
| Returns | |
|---|---|
| Type | Description |
Guardrail.ModelSafety.SafetySetting.Builder |
This builder for chaining. |
setThreshold(Guardrail.ModelSafety.HarmBlockThreshold value)
public Guardrail.ModelSafety.SafetySetting.Builder setThreshold(Guardrail.ModelSafety.HarmBlockThreshold value)Required. The harm block threshold.
.google.cloud.ces.v1.Guardrail.ModelSafety.HarmBlockThreshold threshold = 2 [(.google.api.field_behavior) = REQUIRED];
| Parameter | |
|---|---|
| Name | Description |
value |
Guardrail.ModelSafety.HarmBlockThresholdThe threshold to set. |
| Returns | |
|---|---|
| Type | Description |
Guardrail.ModelSafety.SafetySetting.Builder |
This builder for chaining. |
setThresholdValue(int value)
public Guardrail.ModelSafety.SafetySetting.Builder setThresholdValue(int value)Required. The harm block threshold.
.google.cloud.ces.v1.Guardrail.ModelSafety.HarmBlockThreshold threshold = 2 [(.google.api.field_behavior) = REQUIRED];
| Parameter | |
|---|---|
| Name | Description |
value |
intThe enum numeric value on the wire for threshold to set. |
| Returns | |
|---|---|
| Type | Description |
Guardrail.ModelSafety.SafetySetting.Builder |
This builder for chaining. |