共用方式為


CopyAuthorization Class

  • java.lang.Object
    • com.azure.ai.formrecognizer.training.models.CopyAuthorization

public final class CopyAuthorization

The CopyAuthorization model.

Constructor Summary

Constructor Description
CopyAuthorization(String modelId, String accessToken, String resourceId, String resourceRegion, long expiresOn)

Create a CopyAuthorization object

Method Summary

Modifier and Type Method and Description
static CopyAuthorization fromJson(String copyAuthorization)

Converts the json string representation to its equivalent CopyAuthorization object.

String getAccessToken()

Get the token claim used to authorize the request.

OffsetDateTime getExpiresOn()

Get the date-time when the access token expires.

String getModelId()

Get the modelId property.

String getResourceId()

Get the Azure Resource Id of the target Form Recognizer resource where the model will be copied to.

String getResourceRegion()

Get the location of the target Form Recognizer resource.

String toJson()

Converts the CopyAuthorization object to its equivalent json string representation.

Methods inherited from java.lang.Object

Constructor Details

CopyAuthorization

public CopyAuthorization(String modelId, String accessToken, String resourceId, String resourceRegion, long expiresOn)

Create a CopyAuthorization object

Parameters:

modelId - The model identifier
accessToken - The token used to authorize the request
resourceId - The resource identifier
resourceRegion - The region of the resource
expiresOn - The expiry time of the token

Method Details

fromJson

public static CopyAuthorization fromJson(String copyAuthorization)

Converts the json string representation to its equivalent CopyAuthorization object.

Parameters:

copyAuthorization - the json string representation of the object.

Returns:

the CopyAuthorization object equivalent of the json string.

getAccessToken

public String getAccessToken()

Get the token claim used to authorize the request.

Returns:

the accessToken value.

getExpiresOn

public OffsetDateTime getExpiresOn()

Get the date-time when the access token expires.

Returns:

the date-time value when the access token expires.

getModelId

public String getModelId()

Get the modelId property.

Returns:

the modelId value.

getResourceId

public String getResourceId()

Get the Azure Resource Id of the target Form Recognizer resource where the model will be copied to.

Returns:

the resourceId value.

getResourceRegion

public String getResourceRegion()

Get the location of the target Form Recognizer resource.

Returns:

the resourceRegion value.

toJson

public String toJson()

Converts the CopyAuthorization object to its equivalent json string representation.

Returns:

the json string representation of the CopyAuthorization object.

Applies to