ResourceMetadata Class

  • java.lang.Object
    • com.azure.resourcemanager.appcomplianceautomation.models.ResourceMetadata

Implements

public final class ResourceMetadata
implements JsonSerializable<ResourceMetadata>

Single resource Id's metadata.

Constructor Summary

Constructor Description
ResourceMetadata()

Creates an instance of ResourceMetadata class.

Method Summary

Modifier and Type Method and Description
String accountId()

Get the accountId property: Account Id.

static ResourceMetadata fromJson(JsonReader jsonReader)

Reads an instance of ResourceMetadata from the JsonReader.

String resourceId()

Get the resourceId property: Resource Id - e.g.

String resourceKind()

Get the resourceKind property: Resource kind.

ResourceOrigin resourceOrigin()

Get the resourceOrigin property: Resource Origin.

String resourceType()

Get the resourceType property: Resource type.

JsonWriter toJson(JsonWriter jsonWriter)
ResourceMetadata withAccountId(String accountId)

Set the accountId property: Account Id.

ResourceMetadata withResourceId(String resourceId)

Set the resourceId property: Resource Id - e.g.

ResourceMetadata withResourceKind(String resourceKind)

Set the resourceKind property: Resource kind.

ResourceMetadata withResourceOrigin(ResourceOrigin resourceOrigin)

Set the resourceOrigin property: Resource Origin.

ResourceMetadata withResourceType(String resourceType)

Set the resourceType property: Resource type.

Methods inherited from java.lang.Object

Constructor Details

ResourceMetadata

public ResourceMetadata()

Creates an instance of ResourceMetadata class.

Method Details

accountId

public String accountId()

Get the accountId property: Account Id. For example - the AWS account id.

Returns:

the accountId value.

fromJson

public static ResourceMetadata fromJson(JsonReader jsonReader)

Reads an instance of ResourceMetadata from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

An instance of ResourceMetadata 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.

resourceId

public String resourceId()

Get the resourceId property: Resource Id - e.g. "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.Compute/virtualMachines/vm1".

Returns:

the resourceId value.

resourceKind

public String resourceKind()

Get the resourceKind property: Resource kind.

Returns:

the resourceKind value.

resourceOrigin

public ResourceOrigin resourceOrigin()

Get the resourceOrigin property: Resource Origin.

Returns:

the resourceOrigin value.

resourceType

public String resourceType()

Get the resourceType property: Resource type. e.g. "Microsoft.Compute/virtualMachines".

Returns:

the resourceType value.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

withAccountId

public ResourceMetadata withAccountId(String accountId)

Set the accountId property: Account Id. For example - the AWS account id.

Parameters:

accountId - the accountId value to set.

Returns:

the ResourceMetadata object itself.

withResourceId

public ResourceMetadata withResourceId(String resourceId)

Set the resourceId property: Resource Id - e.g. "/subscriptions/00000000-0000-0000-0000-000000000000/resourceGroups/rg1/providers/Microsoft.Compute/virtualMachines/vm1".

Parameters:

resourceId - the resourceId value to set.

Returns:

the ResourceMetadata object itself.

withResourceKind

public ResourceMetadata withResourceKind(String resourceKind)

Set the resourceKind property: Resource kind.

Parameters:

resourceKind - the resourceKind value to set.

Returns:

the ResourceMetadata object itself.

withResourceOrigin

public ResourceMetadata withResourceOrigin(ResourceOrigin resourceOrigin)

Set the resourceOrigin property: Resource Origin.

Parameters:

resourceOrigin - the resourceOrigin value to set.

Returns:

the ResourceMetadata object itself.

withResourceType

public ResourceMetadata withResourceType(String resourceType)

Set the resourceType property: Resource type. e.g. "Microsoft.Compute/virtualMachines".

Parameters:

resourceType - the resourceType value to set.

Returns:

the ResourceMetadata object itself.

Applies to