Cloud Vision V1 Client - Class AnnotateImageRequest (1.7.6)

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

Request for performing Google Cloud Vision API tasks over a user-provided image, with user-requested features, and with context information.

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

Namespace

Google \ Cloud \ Vision \ V1

Methods

__construct

Constructor.

Parameters
NameDescription
data array

Optional. Data for populating the Message object.

↳ image Google\Cloud\Vision\V1\Image

The image to be processed.

↳ features array<Google\Cloud\Vision\V1\Feature>

Requested features.

↳ image_context Google\Cloud\Vision\V1\ImageContext

Additional context that may accompany the image.

getImage

The image to be processed.

Returns
TypeDescription
Google\Cloud\Vision\V1\Image|null

hasImage

clearImage

setImage

The image to be processed.

Parameter
NameDescription
var Google\Cloud\Vision\V1\Image
Returns
TypeDescription
$this

getFeatures

Requested features.

Returns
TypeDescription
Google\Protobuf\Internal\RepeatedField

setFeatures

Requested features.

Parameter
NameDescription
var array<Google\Cloud\Vision\V1\Feature>
Returns
TypeDescription
$this

getImageContext

Additional context that may accompany the image.

Returns
TypeDescription
Google\Cloud\Vision\V1\ImageContext|null

hasImageContext

clearImageContext

setImageContext

Additional context that may accompany the image.

Parameter
NameDescription
var Google\Cloud\Vision\V1\ImageContext
Returns
TypeDescription
$this