Class RiskAnalysis.Builder (2.6.1)

public static final class RiskAnalysis.Builder extends GeneratedMessageV3.Builder<RiskAnalysis.Builder> implements RiskAnalysisOrBuilder

Risk analysis result for an event.

Protobuf type google.cloud.recaptchaenterprise.v1.RiskAnalysis

Static Methods

getDescriptor()

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

Methods

addAllReasons(Iterable<? extends RiskAnalysis.ClassificationReason> values)

public RiskAnalysis.Builder addAllReasons(Iterable<? extends RiskAnalysis.ClassificationReason> values)

Reasons contributing to the risk analysis verdict.

repeated .google.cloud.recaptchaenterprise.v1.RiskAnalysis.ClassificationReason reasons = 2;

Parameter
NameDescription
valuesIterable<? extends com.google.recaptchaenterprise.v1.RiskAnalysis.ClassificationReason>

The reasons to add.

Returns
TypeDescription
RiskAnalysis.Builder

This builder for chaining.

addAllReasonsValue(Iterable<Integer> values)

public RiskAnalysis.Builder addAllReasonsValue(Iterable<Integer> values)

Reasons contributing to the risk analysis verdict.

repeated .google.cloud.recaptchaenterprise.v1.RiskAnalysis.ClassificationReason reasons = 2;

Parameter
NameDescription
valuesIterable<Integer>

The enum numeric values on the wire for reasons to add.

Returns
TypeDescription
RiskAnalysis.Builder

This builder for chaining.

addReasons(RiskAnalysis.ClassificationReason value)

public RiskAnalysis.Builder addReasons(RiskAnalysis.ClassificationReason value)

Reasons contributing to the risk analysis verdict.

repeated .google.cloud.recaptchaenterprise.v1.RiskAnalysis.ClassificationReason reasons = 2;

Parameter
NameDescription
valueRiskAnalysis.ClassificationReason

The reasons to add.

Returns
TypeDescription
RiskAnalysis.Builder

This builder for chaining.

addReasonsValue(int value)

public RiskAnalysis.Builder addReasonsValue(int value)

Reasons contributing to the risk analysis verdict.

repeated .google.cloud.recaptchaenterprise.v1.RiskAnalysis.ClassificationReason reasons = 2;

Parameter
NameDescription
valueint

The enum numeric value on the wire for reasons to add.

Returns
TypeDescription
RiskAnalysis.Builder

This builder for chaining.

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

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

build()

public RiskAnalysis build()
Returns
TypeDescription
RiskAnalysis

buildPartial()

public RiskAnalysis buildPartial()
Returns
TypeDescription
RiskAnalysis

clear()

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

clearField(Descriptors.FieldDescriptor field)

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

clearOneof(Descriptors.OneofDescriptor oneof)

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

clearReasons()

public RiskAnalysis.Builder clearReasons()

Reasons contributing to the risk analysis verdict.

repeated .google.cloud.recaptchaenterprise.v1.RiskAnalysis.ClassificationReason reasons = 2;

Returns
TypeDescription
RiskAnalysis.Builder

This builder for chaining.

clearScore()

public RiskAnalysis.Builder clearScore()

Legitimate event score from 0.0 to 1.0. (1.0 means very likely legitimate traffic while 0.0 means very likely non-legitimate traffic).

float score = 1;

Returns
TypeDescription
RiskAnalysis.Builder

This builder for chaining.

clone()

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

getDefaultInstanceForType()

public RiskAnalysis getDefaultInstanceForType()
Returns
TypeDescription
RiskAnalysis

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
TypeDescription
Descriptor
Overrides

getReasons(int index)

public RiskAnalysis.ClassificationReason getReasons(int index)

Reasons contributing to the risk analysis verdict.

repeated .google.cloud.recaptchaenterprise.v1.RiskAnalysis.ClassificationReason reasons = 2;

Parameter
NameDescription
indexint

The index of the element to return.

Returns
TypeDescription
RiskAnalysis.ClassificationReason

The reasons at the given index.

getReasonsCount()

public int getReasonsCount()

Reasons contributing to the risk analysis verdict.

repeated .google.cloud.recaptchaenterprise.v1.RiskAnalysis.ClassificationReason reasons = 2;

Returns
TypeDescription
int

The count of reasons.

getReasonsList()

public List<RiskAnalysis.ClassificationReason> getReasonsList()

Reasons contributing to the risk analysis verdict.

repeated .google.cloud.recaptchaenterprise.v1.RiskAnalysis.ClassificationReason reasons = 2;

Returns
TypeDescription
List<ClassificationReason>

A list containing the reasons.

getReasonsValue(int index)

public int getReasonsValue(int index)

Reasons contributing to the risk analysis verdict.

repeated .google.cloud.recaptchaenterprise.v1.RiskAnalysis.ClassificationReason reasons = 2;

Parameter
NameDescription
indexint

The index of the value to return.

Returns
TypeDescription
int

The enum numeric value on the wire of reasons at the given index.

getReasonsValueList()

public List<Integer> getReasonsValueList()

Reasons contributing to the risk analysis verdict.

repeated .google.cloud.recaptchaenterprise.v1.RiskAnalysis.ClassificationReason reasons = 2;

Returns
TypeDescription
List<Integer>

A list containing the enum numeric values on the wire for reasons.

getScore()

public float getScore()

Legitimate event score from 0.0 to 1.0. (1.0 means very likely legitimate traffic while 0.0 means very likely non-legitimate traffic).

float score = 1;

Returns
TypeDescription
float

The score.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
TypeDescription
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
TypeDescription
boolean
Overrides

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

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

mergeFrom(Message other)

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

mergeFrom(RiskAnalysis other)

public RiskAnalysis.Builder mergeFrom(RiskAnalysis other)
Parameter
NameDescription
otherRiskAnalysis
Returns
TypeDescription
RiskAnalysis.Builder

mergeUnknownFields(UnknownFieldSet unknownFields)

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

setField(Descriptors.FieldDescriptor field, Object value)

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

setReasons(int index, RiskAnalysis.ClassificationReason value)

public RiskAnalysis.Builder setReasons(int index, RiskAnalysis.ClassificationReason value)

Reasons contributing to the risk analysis verdict.

repeated .google.cloud.recaptchaenterprise.v1.RiskAnalysis.ClassificationReason reasons = 2;

Parameters
NameDescription
indexint

The index to set the value at.

valueRiskAnalysis.ClassificationReason

The reasons to set.

Returns
TypeDescription
RiskAnalysis.Builder

This builder for chaining.

setReasonsValue(int index, int value)

public RiskAnalysis.Builder setReasonsValue(int index, int value)

Reasons contributing to the risk analysis verdict.

repeated .google.cloud.recaptchaenterprise.v1.RiskAnalysis.ClassificationReason reasons = 2;

Parameters
NameDescription
indexint

The index of the value to return.

valueint
Returns
TypeDescription
RiskAnalysis.Builder

The enum numeric value on the wire of reasons at the given index.

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

public RiskAnalysis.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
NameDescription
fieldFieldDescriptor
indexint
valueObject
Returns
TypeDescription
RiskAnalysis.Builder
Overrides

setScore(float value)

public RiskAnalysis.Builder setScore(float value)

Legitimate event score from 0.0 to 1.0. (1.0 means very likely legitimate traffic while 0.0 means very likely non-legitimate traffic).

float score = 1;

Parameter
NameDescription
valuefloat

The score to set.

Returns
TypeDescription
RiskAnalysis.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

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