ResourceId Class

  • java.lang.Object
    • com.azure.resourcemanager.machinelearning.models.ResourceId

Implements

public final class ResourceId
implements JsonSerializable<ResourceId>

Represents a resource ID. For example, for a subnet, it is the resource URL for the subnet.

Constructor Summary

Constructor Description
ResourceId()

Creates an instance of ResourceId class.

Method Summary

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

Reads an instance of ResourceId from the JsonReader.

String id()

Get the id property: The ID of the resource.

JsonWriter toJson(JsonWriter jsonWriter)
void validate()

Validates the instance.

ResourceId withId(String id)

Set the id property: The ID of the resource.

Methods inherited from java.lang.Object

Constructor Details

ResourceId

public ResourceId()

Creates an instance of ResourceId class.

Method Details

fromJson

public static ResourceId fromJson(JsonReader jsonReader)

Reads an instance of ResourceId from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

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

id

public String id()

Get the id property: The ID of the resource.

Returns:

the id value.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

validate

public void validate()

Validates the instance.

withId

public ResourceId withId(String id)

Set the id property: The ID of the resource.

Parameters:

id - the id value to set.

Returns:

the ResourceId object itself.

Applies to