Cloud Translation V3 Client - Class DetectLanguageResponse (1.17.7)

Reference documentation and code samples for the Cloud Translation V3 Client class DetectLanguageResponse.

The response message for language detection.

Generated from protobuf message google.cloud.translation.v3.DetectLanguageResponse

Namespace

Google \ Cloud \ Translate \ V3

Methods

__construct

Constructor.

Parameters
Name Description
data array

Optional. Data for populating the Message object.

↳ languages array<Google\Cloud\Translate\V3\DetectedLanguage>

The most probable language detected by the Translation API. For each request, the Translation API will always return only one result.

getLanguages

The most probable language detected by the Translation API. For each request, the Translation API will always return only one result.

Returns
Type Description
Google\Protobuf\Internal\RepeatedField

setLanguages

The most probable language detected by the Translation API. For each request, the Translation API will always return only one result.

Parameter
Name Description
var array<Google\Cloud\Translate\V3\DetectedLanguage>
Returns
Type Description
$this