Google Cloud Contact Center Insights V1 Client - Class SentimentData (1.2.1)

Reference documentation and code samples for the Google Cloud Contact Center Insights V1 Client class SentimentData.

The data for a sentiment annotation.

Generated from protobuf message google.cloud.contactcenterinsights.v1.SentimentData

Methods

__construct

Constructor.

Parameters
NameDescription
data array

Optional. Data for populating the Message object.

↳ magnitude float

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

↳ score float

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

getMagnitude

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

Returns
TypeDescription
float

setMagnitude

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

Parameter
NameDescription
var float
Returns
TypeDescription
$this

getScore

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

Returns
TypeDescription
float

setScore

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

Parameter
NameDescription
var float
Returns
TypeDescription
$this