Class SentimentData.Builder (2.55.0)

public static final class SentimentData.Builder extends GeneratedMessageV3.Builder<SentimentData.Builder> implements SentimentDataOrBuilder

The data for a sentiment annotation.

Protobuf type google.cloud.contactcenterinsights.v1.SentimentData

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

addRepeatedField(Descriptors.FieldDescriptor field, Object value)

public SentimentData.Builder addRepeatedField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
SentimentData.Builder
Overrides

build()

public SentimentData build()
Returns
Type Description
SentimentData

buildPartial()

public SentimentData buildPartial()
Returns
Type Description
SentimentData

clear()

public SentimentData.Builder clear()
Returns
Type Description
SentimentData.Builder
Overrides

clearField(Descriptors.FieldDescriptor field)

public SentimentData.Builder clearField(Descriptors.FieldDescriptor field)
Parameter
Name Description
field FieldDescriptor
Returns
Type Description
SentimentData.Builder
Overrides

clearMagnitude()

public SentimentData.Builder clearMagnitude()

A non-negative number from 0 to infinity which represents the abolute magnitude of sentiment regardless of score.

float magnitude = 1;

Returns
Type Description
SentimentData.Builder

This builder for chaining.

clearOneof(Descriptors.OneofDescriptor oneof)

public SentimentData.Builder clearOneof(Descriptors.OneofDescriptor oneof)
Parameter
Name Description
oneof OneofDescriptor
Returns
Type Description
SentimentData.Builder
Overrides

clearScore()

public SentimentData.Builder clearScore()

The sentiment score between -1.0 (negative) and 1.0 (positive).

float score = 2;

Returns
Type Description
SentimentData.Builder

This builder for chaining.

clone()

public SentimentData.Builder clone()
Returns
Type Description
SentimentData.Builder
Overrides

getDefaultInstanceForType()

public SentimentData getDefaultInstanceForType()
Returns
Type Description
SentimentData

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getMagnitude()

public float getMagnitude()

A non-negative number from 0 to infinity which represents the abolute magnitude of sentiment regardless of score.

float magnitude = 1;

Returns
Type Description
float

The magnitude.

getScore()

public float getScore()

The sentiment score between -1.0 (negative) and 1.0 (positive).

float score = 2;

Returns
Type Description
float

The score.

internalGetFieldAccessorTable()

protected GeneratedMessageV3.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(SentimentData other)

public SentimentData.Builder mergeFrom(SentimentData other)
Parameter
Name Description
other SentimentData
Returns
Type Description
SentimentData.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public SentimentData.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
SentimentData.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public SentimentData.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
SentimentData.Builder
Overrides

mergeUnknownFields(UnknownFieldSet unknownFields)

public final SentimentData.Builder mergeUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
SentimentData.Builder
Overrides

setField(Descriptors.FieldDescriptor field, Object value)

public SentimentData.Builder setField(Descriptors.FieldDescriptor field, Object value)
Parameters
Name Description
field FieldDescriptor
value Object
Returns
Type Description
SentimentData.Builder
Overrides

setMagnitude(float value)

public SentimentData.Builder setMagnitude(float value)

A non-negative number from 0 to infinity which represents the abolute magnitude of sentiment regardless of score.

float magnitude = 1;

Parameter
Name Description
value float

The magnitude to set.

Returns
Type Description
SentimentData.Builder

This builder for chaining.

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

public SentimentData.Builder setRepeatedField(Descriptors.FieldDescriptor field, int index, Object value)
Parameters
Name Description
field FieldDescriptor
index int
value Object
Returns
Type Description
SentimentData.Builder
Overrides

setScore(float value)

public SentimentData.Builder setScore(float value)

The sentiment score between -1.0 (negative) and 1.0 (positive).

float score = 2;

Parameter
Name Description
value float

The score to set.

Returns
Type Description
SentimentData.Builder

This builder for chaining.

setUnknownFields(UnknownFieldSet unknownFields)

public final SentimentData.Builder setUnknownFields(UnknownFieldSet unknownFields)
Parameter
Name Description
unknownFields UnknownFieldSet
Returns
Type Description
SentimentData.Builder
Overrides