Reference documentation and code samples for the Cloud Vision V1 Client class AnnotateImageResponse.
Response to an image annotation request.
Generated from protobuf message google.cloud.vision.v1.AnnotateImageResponse
Methods
__construct
Constructor.
Parameters | |
---|---|
Name | Description |
data |
array
Optional. Data for populating the Message object. |
↳ face_annotations |
array<Google\Cloud\Vision\V1\FaceAnnotation>
If present, face detection has completed successfully. |
↳ landmark_annotations |
array<Google\Cloud\Vision\V1\EntityAnnotation>
If present, landmark detection has completed successfully. |
↳ logo_annotations |
array<Google\Cloud\Vision\V1\EntityAnnotation>
If present, logo detection has completed successfully. |
↳ label_annotations |
array<Google\Cloud\Vision\V1\EntityAnnotation>
If present, label detection has completed successfully. |
↳ localized_object_annotations |
array<Google\Cloud\Vision\V1\LocalizedObjectAnnotation>
If present, localized object detection has completed successfully. This will be sorted descending by confidence score. |
↳ text_annotations |
array<Google\Cloud\Vision\V1\EntityAnnotation>
If present, text (OCR) detection has completed successfully. |
↳ full_text_annotation |
Google\Cloud\Vision\V1\TextAnnotation
If present, text (OCR) detection or document (OCR) text detection has completed successfully. This annotation provides the structural hierarchy for the OCR detected text. |
↳ safe_search_annotation |
Google\Cloud\Vision\V1\SafeSearchAnnotation
If present, safe-search annotation has completed successfully. |
↳ image_properties_annotation |
Google\Cloud\Vision\V1\ImageProperties
If present, image properties were extracted successfully. |
↳ crop_hints_annotation |
Google\Cloud\Vision\V1\CropHintsAnnotation
If present, crop hints have completed successfully. |
↳ web_detection |
Google\Cloud\Vision\V1\WebDetection
If present, web detection has completed successfully. |
↳ product_search_results |
Google\Cloud\Vision\V1\ProductSearchResults
If present, product search has completed successfully. |
↳ error |
Google\Rpc\Status
If set, represents the error message for the operation. Note that filled-in image annotations are guaranteed to be correct, even when |
↳ context |
Google\Cloud\Vision\V1\ImageAnnotationContext
If present, contextual information is needed to understand where this image comes from. |
getFaceAnnotations
If present, face detection has completed successfully.
Returns | |
---|---|
Type | Description |
Google\Protobuf\Internal\RepeatedField |
setFaceAnnotations
If present, face detection has completed successfully.
Parameter | |
---|---|
Name | Description |
var |
array<Google\Cloud\Vision\V1\FaceAnnotation>
|
Returns | |
---|---|
Type | Description |
$this |
getLandmarkAnnotations
If present, landmark detection has completed successfully.
Returns | |
---|---|
Type | Description |
Google\Protobuf\Internal\RepeatedField |
setLandmarkAnnotations
If present, landmark detection has completed successfully.
Parameter | |
---|---|
Name | Description |
var |
array<Google\Cloud\Vision\V1\EntityAnnotation>
|
Returns | |
---|---|
Type | Description |
$this |
getLogoAnnotations
If present, logo detection has completed successfully.
Returns | |
---|---|
Type | Description |
Google\Protobuf\Internal\RepeatedField |
setLogoAnnotations
If present, logo detection has completed successfully.
Parameter | |
---|---|
Name | Description |
var |
array<Google\Cloud\Vision\V1\EntityAnnotation>
|
Returns | |
---|---|
Type | Description |
$this |
getLabelAnnotations
If present, label detection has completed successfully.
Returns | |
---|---|
Type | Description |
Google\Protobuf\Internal\RepeatedField |
setLabelAnnotations
If present, label detection has completed successfully.
Parameter | |
---|---|
Name | Description |
var |
array<Google\Cloud\Vision\V1\EntityAnnotation>
|
Returns | |
---|---|
Type | Description |
$this |
getLocalizedObjectAnnotations
If present, localized object detection has completed successfully.
This will be sorted descending by confidence score.
Returns | |
---|---|
Type | Description |
Google\Protobuf\Internal\RepeatedField |
setLocalizedObjectAnnotations
If present, localized object detection has completed successfully.
This will be sorted descending by confidence score.
Parameter | |
---|---|
Name | Description |
var |
array<Google\Cloud\Vision\V1\LocalizedObjectAnnotation>
|
Returns | |
---|---|
Type | Description |
$this |
getTextAnnotations
If present, text (OCR) detection has completed successfully.
Returns | |
---|---|
Type | Description |
Google\Protobuf\Internal\RepeatedField |
setTextAnnotations
If present, text (OCR) detection has completed successfully.
Parameter | |
---|---|
Name | Description |
var |
array<Google\Cloud\Vision\V1\EntityAnnotation>
|
Returns | |
---|---|
Type | Description |
$this |
getFullTextAnnotation
If present, text (OCR) detection or document (OCR) text detection has completed successfully.
This annotation provides the structural hierarchy for the OCR detected text.
Returns | |
---|---|
Type | Description |
Google\Cloud\Vision\V1\TextAnnotation|null |
hasFullTextAnnotation
clearFullTextAnnotation
setFullTextAnnotation
If present, text (OCR) detection or document (OCR) text detection has completed successfully.
This annotation provides the structural hierarchy for the OCR detected text.
Parameter | |
---|---|
Name | Description |
var |
Google\Cloud\Vision\V1\TextAnnotation
|
Returns | |
---|---|
Type | Description |
$this |
getSafeSearchAnnotation
If present, safe-search annotation has completed successfully.
Returns | |
---|---|
Type | Description |
Google\Cloud\Vision\V1\SafeSearchAnnotation|null |
hasSafeSearchAnnotation
clearSafeSearchAnnotation
setSafeSearchAnnotation
If present, safe-search annotation has completed successfully.
Parameter | |
---|---|
Name | Description |
var |
Google\Cloud\Vision\V1\SafeSearchAnnotation
|
Returns | |
---|---|
Type | Description |
$this |
getImagePropertiesAnnotation
If present, image properties were extracted successfully.
Returns | |
---|---|
Type | Description |
Google\Cloud\Vision\V1\ImageProperties|null |
hasImagePropertiesAnnotation
clearImagePropertiesAnnotation
setImagePropertiesAnnotation
If present, image properties were extracted successfully.
Parameter | |
---|---|
Name | Description |
var |
Google\Cloud\Vision\V1\ImageProperties
|
Returns | |
---|---|
Type | Description |
$this |
getCropHintsAnnotation
If present, crop hints have completed successfully.
Returns | |
---|---|
Type | Description |
Google\Cloud\Vision\V1\CropHintsAnnotation|null |
hasCropHintsAnnotation
clearCropHintsAnnotation
setCropHintsAnnotation
If present, crop hints have completed successfully.
Parameter | |
---|---|
Name | Description |
var |
Google\Cloud\Vision\V1\CropHintsAnnotation
|
Returns | |
---|---|
Type | Description |
$this |
getWebDetection
If present, web detection has completed successfully.
Returns | |
---|---|
Type | Description |
Google\Cloud\Vision\V1\WebDetection|null |
hasWebDetection
clearWebDetection
setWebDetection
If present, web detection has completed successfully.
Parameter | |
---|---|
Name | Description |
var |
Google\Cloud\Vision\V1\WebDetection
|
Returns | |
---|---|
Type | Description |
$this |
getProductSearchResults
If present, product search has completed successfully.
Returns | |
---|---|
Type | Description |
Google\Cloud\Vision\V1\ProductSearchResults|null |
hasProductSearchResults
clearProductSearchResults
setProductSearchResults
If present, product search has completed successfully.
Parameter | |
---|---|
Name | Description |
var |
Google\Cloud\Vision\V1\ProductSearchResults
|
Returns | |
---|---|
Type | Description |
$this |
getError
If set, represents the error message for the operation.
Note that filled-in image annotations are guaranteed to be
correct, even when error
is set.
Returns | |
---|---|
Type | Description |
Google\Rpc\Status|null |
hasError
clearError
setError
If set, represents the error message for the operation.
Note that filled-in image annotations are guaranteed to be
correct, even when error
is set.
Parameter | |
---|---|
Name | Description |
var |
Google\Rpc\Status
|
Returns | |
---|---|
Type | Description |
$this |
getContext
If present, contextual information is needed to understand where this image comes from.
Returns | |
---|---|
Type | Description |
Google\Cloud\Vision\V1\ImageAnnotationContext|null |
hasContext
clearContext
setContext
If present, contextual information is needed to understand where this image comes from.
Parameter | |
---|---|
Name | Description |
var |
Google\Cloud\Vision\V1\ImageAnnotationContext
|
Returns | |
---|---|
Type | Description |
$this |