public static final class AssistAnswer.CustomerPolicyEnforcementResult.Builder extends GeneratedMessage.Builder<AssistAnswer.CustomerPolicyEnforcementResult.Builder> implements AssistAnswer.CustomerPolicyEnforcementResultOrBuilderCustomer policy enforcement results. Contains the results of the various policy checks, like the banned phrases or the Model Armor checks.
Protobuf type
google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult
Inheritance
java.lang.Object > AbstractMessageLite.Builder<MessageType,BuilderType> > AbstractMessage.Builder<BuilderType> > GeneratedMessage.Builder > AssistAnswer.CustomerPolicyEnforcementResult.BuilderStatic Methods
getDescriptor()
public static final Descriptors.Descriptor getDescriptor()| Returns | |
|---|---|
| Type | Description |
Descriptor |
|
Methods
addAllPolicyResults(Iterable<? extends AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult> values)
public AssistAnswer.CustomerPolicyEnforcementResult.Builder addAllPolicyResults(Iterable<? extends AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult> values)Customer policy enforcement results. Populated only if the assist call was skipped due to a policy violation. It contains results from those filters that blocked the processing of the query.
repeated .google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult policy_results = 3;
| Parameter | |
|---|---|
| Name | Description |
values |
Iterable<? extends com.google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult> |
| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.Builder |
|
addPolicyResults(AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult value)
public AssistAnswer.CustomerPolicyEnforcementResult.Builder addPolicyResults(AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult value)Customer policy enforcement results. Populated only if the assist call was skipped due to a policy violation. It contains results from those filters that blocked the processing of the query.
repeated .google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult policy_results = 3;
| Parameter | |
|---|---|
| Name | Description |
value |
AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult |
| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.Builder |
|
addPolicyResults(AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult.Builder builderForValue)
public AssistAnswer.CustomerPolicyEnforcementResult.Builder addPolicyResults(AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult.Builder builderForValue)Customer policy enforcement results. Populated only if the assist call was skipped due to a policy violation. It contains results from those filters that blocked the processing of the query.
repeated .google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult policy_results = 3;
| Parameter | |
|---|---|
| Name | Description |
builderForValue |
AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult.Builder |
| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.Builder |
|
addPolicyResults(int index, AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult value)
public AssistAnswer.CustomerPolicyEnforcementResult.Builder addPolicyResults(int index, AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult value)Customer policy enforcement results. Populated only if the assist call was skipped due to a policy violation. It contains results from those filters that blocked the processing of the query.
repeated .google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult policy_results = 3;
| Parameters | |
|---|---|
| Name | Description |
index |
int |
value |
AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult |
| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.Builder |
|
addPolicyResults(int index, AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult.Builder builderForValue)
public AssistAnswer.CustomerPolicyEnforcementResult.Builder addPolicyResults(int index, AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult.Builder builderForValue)Customer policy enforcement results. Populated only if the assist call was skipped due to a policy violation. It contains results from those filters that blocked the processing of the query.
repeated .google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult policy_results = 3;
| Parameters | |
|---|---|
| Name | Description |
index |
int |
builderForValue |
AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult.Builder |
| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.Builder |
|
addPolicyResultsBuilder()
public AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult.Builder addPolicyResultsBuilder()Customer policy enforcement results. Populated only if the assist call was skipped due to a policy violation. It contains results from those filters that blocked the processing of the query.
repeated .google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult policy_results = 3;
| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult.Builder |
|
addPolicyResultsBuilder(int index)
public AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult.Builder addPolicyResultsBuilder(int index)Customer policy enforcement results. Populated only if the assist call was skipped due to a policy violation. It contains results from those filters that blocked the processing of the query.
repeated .google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult policy_results = 3;
| Parameter | |
|---|---|
| Name | Description |
index |
int |
| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult.Builder |
|
build()
public AssistAnswer.CustomerPolicyEnforcementResult build()| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult |
|
buildPartial()
public AssistAnswer.CustomerPolicyEnforcementResult buildPartial()| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult |
|
clear()
public AssistAnswer.CustomerPolicyEnforcementResult.Builder clear()| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.Builder |
|
clearPolicyResults()
public AssistAnswer.CustomerPolicyEnforcementResult.Builder clearPolicyResults()Customer policy enforcement results. Populated only if the assist call was skipped due to a policy violation. It contains results from those filters that blocked the processing of the query.
repeated .google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult policy_results = 3;
| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.Builder |
|
clearVerdict()
public AssistAnswer.CustomerPolicyEnforcementResult.Builder clearVerdict()Final verdict of the customer policy enforcement. If only one policy blocked the processing, the verdict is BLOCK.
.google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.Verdict verdict = 1;
| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.Builder |
This builder for chaining. |
clearViolationSource()
public AssistAnswer.CustomerPolicyEnforcementResult.Builder clearViolationSource()Output only. The source of the violation.
.google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.ViolationSource violation_source = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.Builder |
This builder for chaining. |
getDefaultInstanceForType()
public AssistAnswer.CustomerPolicyEnforcementResult getDefaultInstanceForType()| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult |
|
getDescriptorForType()
public Descriptors.Descriptor getDescriptorForType()| Returns | |
|---|---|
| Type | Description |
Descriptor |
|
getPolicyResults(int index)
public AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult getPolicyResults(int index)Customer policy enforcement results. Populated only if the assist call was skipped due to a policy violation. It contains results from those filters that blocked the processing of the query.
repeated .google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult policy_results = 3;
| Parameter | |
|---|---|
| Name | Description |
index |
int |
| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult |
|
getPolicyResultsBuilder(int index)
public AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult.Builder getPolicyResultsBuilder(int index)Customer policy enforcement results. Populated only if the assist call was skipped due to a policy violation. It contains results from those filters that blocked the processing of the query.
repeated .google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult policy_results = 3;
| Parameter | |
|---|---|
| Name | Description |
index |
int |
| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult.Builder |
|
getPolicyResultsBuilderList()
public List<AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult.Builder> getPolicyResultsBuilderList()Customer policy enforcement results. Populated only if the assist call was skipped due to a policy violation. It contains results from those filters that blocked the processing of the query.
repeated .google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult policy_results = 3;
| Returns | |
|---|---|
| Type | Description |
List<Builder> |
|
getPolicyResultsCount()
public int getPolicyResultsCount()Customer policy enforcement results. Populated only if the assist call was skipped due to a policy violation. It contains results from those filters that blocked the processing of the query.
repeated .google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult policy_results = 3;
| Returns | |
|---|---|
| Type | Description |
int |
|
getPolicyResultsList()
public List<AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult> getPolicyResultsList()Customer policy enforcement results. Populated only if the assist call was skipped due to a policy violation. It contains results from those filters that blocked the processing of the query.
repeated .google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult policy_results = 3;
| Returns | |
|---|---|
| Type | Description |
List<PolicyEnforcementResult> |
|
getPolicyResultsOrBuilder(int index)
public AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResultOrBuilder getPolicyResultsOrBuilder(int index)Customer policy enforcement results. Populated only if the assist call was skipped due to a policy violation. It contains results from those filters that blocked the processing of the query.
repeated .google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult policy_results = 3;
| Parameter | |
|---|---|
| Name | Description |
index |
int |
| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResultOrBuilder |
|
getPolicyResultsOrBuilderList()
public List<? extends AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResultOrBuilder> getPolicyResultsOrBuilderList()Customer policy enforcement results. Populated only if the assist call was skipped due to a policy violation. It contains results from those filters that blocked the processing of the query.
repeated .google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult policy_results = 3;
| Returns | |
|---|---|
| Type | Description |
List<? extends com.google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResultOrBuilder> |
|
getVerdict()
public AssistAnswer.CustomerPolicyEnforcementResult.Verdict getVerdict()Final verdict of the customer policy enforcement. If only one policy blocked the processing, the verdict is BLOCK.
.google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.Verdict verdict = 1;
| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.Verdict |
The verdict. |
getVerdictValue()
public int getVerdictValue()Final verdict of the customer policy enforcement. If only one policy blocked the processing, the verdict is BLOCK.
.google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.Verdict verdict = 1;
| Returns | |
|---|---|
| Type | Description |
int |
The enum numeric value on the wire for verdict. |
getViolationSource()
public AssistAnswer.CustomerPolicyEnforcementResult.ViolationSource getViolationSource()Output only. The source of the violation.
.google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.ViolationSource violation_source = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.ViolationSource |
The violationSource. |
getViolationSourceValue()
public int getViolationSourceValue()Output only. The source of the violation.
.google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.ViolationSource violation_source = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
| Returns | |
|---|---|
| Type | Description |
int |
The enum numeric value on the wire for violationSource. |
internalGetFieldAccessorTable()
protected GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()| Returns | |
|---|---|
| Type | Description |
FieldAccessorTable |
|
isInitialized()
public final boolean isInitialized()| Returns | |
|---|---|
| Type | Description |
boolean |
|
mergeFrom(AssistAnswer.CustomerPolicyEnforcementResult other)
public AssistAnswer.CustomerPolicyEnforcementResult.Builder mergeFrom(AssistAnswer.CustomerPolicyEnforcementResult other)| Parameter | |
|---|---|
| Name | Description |
other |
AssistAnswer.CustomerPolicyEnforcementResult |
| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.Builder |
|
mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
public AssistAnswer.CustomerPolicyEnforcementResult.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)| Parameters | |
|---|---|
| Name | Description |
input |
CodedInputStream |
extensionRegistry |
ExtensionRegistryLite |
| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.Builder |
|
| Exceptions | |
|---|---|
| Type | Description |
IOException |
|
mergeFrom(Message other)
public AssistAnswer.CustomerPolicyEnforcementResult.Builder mergeFrom(Message other)| Parameter | |
|---|---|
| Name | Description |
other |
Message |
| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.Builder |
|
removePolicyResults(int index)
public AssistAnswer.CustomerPolicyEnforcementResult.Builder removePolicyResults(int index)Customer policy enforcement results. Populated only if the assist call was skipped due to a policy violation. It contains results from those filters that blocked the processing of the query.
repeated .google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult policy_results = 3;
| Parameter | |
|---|---|
| Name | Description |
index |
int |
| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.Builder |
|
setPolicyResults(int index, AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult value)
public AssistAnswer.CustomerPolicyEnforcementResult.Builder setPolicyResults(int index, AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult value)Customer policy enforcement results. Populated only if the assist call was skipped due to a policy violation. It contains results from those filters that blocked the processing of the query.
repeated .google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult policy_results = 3;
| Parameters | |
|---|---|
| Name | Description |
index |
int |
value |
AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult |
| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.Builder |
|
setPolicyResults(int index, AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult.Builder builderForValue)
public AssistAnswer.CustomerPolicyEnforcementResult.Builder setPolicyResults(int index, AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult.Builder builderForValue)Customer policy enforcement results. Populated only if the assist call was skipped due to a policy violation. It contains results from those filters that blocked the processing of the query.
repeated .google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult policy_results = 3;
| Parameters | |
|---|---|
| Name | Description |
index |
int |
builderForValue |
AssistAnswer.CustomerPolicyEnforcementResult.PolicyEnforcementResult.Builder |
| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.Builder |
|
setVerdict(AssistAnswer.CustomerPolicyEnforcementResult.Verdict value)
public AssistAnswer.CustomerPolicyEnforcementResult.Builder setVerdict(AssistAnswer.CustomerPolicyEnforcementResult.Verdict value)Final verdict of the customer policy enforcement. If only one policy blocked the processing, the verdict is BLOCK.
.google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.Verdict verdict = 1;
| Parameter | |
|---|---|
| Name | Description |
value |
AssistAnswer.CustomerPolicyEnforcementResult.VerdictThe verdict to set. |
| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.Builder |
This builder for chaining. |
setVerdictValue(int value)
public AssistAnswer.CustomerPolicyEnforcementResult.Builder setVerdictValue(int value)Final verdict of the customer policy enforcement. If only one policy blocked the processing, the verdict is BLOCK.
.google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.Verdict verdict = 1;
| Parameter | |
|---|---|
| Name | Description |
value |
intThe enum numeric value on the wire for verdict to set. |
| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.Builder |
This builder for chaining. |
setViolationSource(AssistAnswer.CustomerPolicyEnforcementResult.ViolationSource value)
public AssistAnswer.CustomerPolicyEnforcementResult.Builder setViolationSource(AssistAnswer.CustomerPolicyEnforcementResult.ViolationSource value)Output only. The source of the violation.
.google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.ViolationSource violation_source = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
| Parameter | |
|---|---|
| Name | Description |
value |
AssistAnswer.CustomerPolicyEnforcementResult.ViolationSourceThe violationSource to set. |
| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.Builder |
This builder for chaining. |
setViolationSourceValue(int value)
public AssistAnswer.CustomerPolicyEnforcementResult.Builder setViolationSourceValue(int value)Output only. The source of the violation.
.google.cloud.discoveryengine.v1.AssistAnswer.CustomerPolicyEnforcementResult.ViolationSource violation_source = 4 [(.google.api.field_behavior) = OUTPUT_ONLY];
| Parameter | |
|---|---|
| Name | Description |
value |
intThe enum numeric value on the wire for violationSource to set. |
| Returns | |
|---|---|
| Type | Description |
AssistAnswer.CustomerPolicyEnforcementResult.Builder |
This builder for chaining. |