AnalyzeDocumentRequest Class

  • java.lang.Object
    • com.azure.ai.documentintelligence.models.AnalyzeDocumentRequest

Implements

public final class AnalyzeDocumentRequest
implements JsonSerializable<AnalyzeDocumentRequest>

Document analysis parameters.

Constructor Summary

Constructor Description
AnalyzeDocumentRequest()

Creates an instance of AnalyzeDocumentRequest class.

Method Summary

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

Reads an instance of AnalyzeDocumentRequest from the JsonReader.

byte[] getBase64Source()

Get the base64Source property: Base64 encoding of the document to analyze.

String getUrlSource()

Get the urlSource property: Document URL to analyze.

AnalyzeDocumentRequest setBase64Source(byte[] base64Source)

Set the base64Source property: Base64 encoding of the document to analyze.

AnalyzeDocumentRequest setUrlSource(String urlSource)

Set the urlSource property: Document URL to analyze.

JsonWriter toJson(JsonWriter jsonWriter)

Methods inherited from java.lang.Object

Constructor Details

AnalyzeDocumentRequest

public AnalyzeDocumentRequest()

Creates an instance of AnalyzeDocumentRequest class.

Method Details

fromJson

public static AnalyzeDocumentRequest fromJson(JsonReader jsonReader)

Reads an instance of AnalyzeDocumentRequest from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

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

Throws:

IOException

- If an error occurs while reading the AnalyzeDocumentRequest.

getBase64Source

public byte[] getBase64Source()

Get the base64Source property: Base64 encoding of the document to analyze. Either urlSource or base64Source must be specified.

Returns:

the base64Source value.

getUrlSource

public String getUrlSource()

Get the urlSource property: Document URL to analyze. Either urlSource or base64Source must be specified.

Returns:

the urlSource value.

setBase64Source

public AnalyzeDocumentRequest setBase64Source(byte[] base64Source)

Set the base64Source property: Base64 encoding of the document to analyze. Either urlSource or base64Source must be specified.

Parameters:

base64Source - the base64Source value to set.

Returns:

the AnalyzeDocumentRequest object itself.

setUrlSource

public AnalyzeDocumentRequest setUrlSource(String urlSource)

Set the urlSource property: Document URL to analyze. Either urlSource or base64Source must be specified.

Parameters:

urlSource - the urlSource value to set.

Returns:

the AnalyzeDocumentRequest object itself.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

Applies to