你当前正在访问 Microsoft Azure Global Edition 技术文档网站。 如果需要访问由世纪互联运营的 Microsoft Azure 中国技术文档网站,请访问 https://docs.azure.cn

DetectedObject Class

  • java.lang.Object
    • com.azure.ai.vision.imageanalysis.models.DetectedObject

Implements

public final class DetectedObject
implements JsonSerializable<DetectedObject>

Represents a physical object detected in an image.

Method Summary

Modifier and Type Method and Description
static DetectedObject fromJson(JsonReader jsonReader)

Reads an instance of DetectedObject from the JsonReader.

ImageBoundingBox getBoundingBox()

Get the boundingBox property: A rectangular boundary where the object was detected.

List<DetectedTag> getTags()

Get the tags property: A single-item list containing the object information.

JsonWriter toJson(JsonWriter jsonWriter)

Methods inherited from java.lang.Object

Method Details

fromJson

public static DetectedObject fromJson(JsonReader jsonReader)

Reads an instance of DetectedObject from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

An instance of DetectedObject if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.

Throws:

IOException

- If the deserialized JSON object was missing any required properties.

getBoundingBox

public ImageBoundingBox getBoundingBox()

Get the boundingBox property: A rectangular boundary where the object was detected.

Returns:

the boundingBox value.

getTags

public List<DetectedTag> getTags()

Get the tags property: A single-item list containing the object information.

Returns:

the tags value.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

Applies to