Cloud Vision V1 Client - Class AnnotateFileResponse (1.9.3)

Reference documentation and code samples for the Cloud Vision V1 Client class AnnotateFileResponse.

Response to a single file annotation request. A file may contain one or more images, which individually have their own responses.

Generated from protobuf message google.cloud.vision.v1.AnnotateFileResponse

Namespace

Google \ Cloud \ Vision \ V1

Methods

__construct

Constructor.

Parameters
Name Description
data array

Optional. Data for populating the Message object.

↳ input_config Google\Cloud\Vision\V1\InputConfig

Information about the file for which this response is generated.

↳ responses array<Google\Cloud\Vision\V1\AnnotateImageResponse>

Individual responses to images found within the file. This field will be empty if the error field is set.

↳ total_pages int

This field gives the total number of pages in the file.

↳ error Google\Rpc\Status

If set, represents the error message for the failed request. The responses field will not be set in this case.

getInputConfig

Information about the file for which this response is generated.

Returns
Type Description
Google\Cloud\Vision\V1\InputConfig|null

hasInputConfig

clearInputConfig

setInputConfig

Information about the file for which this response is generated.

Parameter
Name Description
var Google\Cloud\Vision\V1\InputConfig
Returns
Type Description
$this

getResponses

Individual responses to images found within the file. This field will be empty if the error field is set.

Returns
Type Description
Google\Protobuf\Internal\RepeatedField

setResponses

Individual responses to images found within the file. This field will be empty if the error field is set.

Parameter
Name Description
var array<Google\Cloud\Vision\V1\AnnotateImageResponse>
Returns
Type Description
$this

getTotalPages

This field gives the total number of pages in the file.

Returns
Type Description
int

setTotalPages

This field gives the total number of pages in the file.

Parameter
Name Description
var int
Returns
Type Description
$this

getError

If set, represents the error message for the failed request. The responses field will not be set in this case.

Returns
Type Description
Google\Rpc\Status|null

hasError

clearError

setError

If set, represents the error message for the failed request. The responses field will not be set in this case.

Parameter
Name Description
var Google\Rpc\Status
Returns
Type Description
$this