ManagedResource Class

public class ManagedResource
extends ProxyResource

An azure managed resource object.

Constructor Summary

Constructor Description
ManagedResource()

Creates an instance of ManagedResource class.

Method Summary

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

Reads an instance of ManagedResource from the JsonReader.

String id()

Get the id property: Fully qualified resource Id for the resource.

String location()

Get the location property: Resource location.

String name()

Get the name property: The name of the resource.

Map<String,String> tags()

Get the tags property: Resource tags.

JsonWriter toJson(JsonWriter jsonWriter)
String type()

Get the type property: The type of the resource.

void validate()

Validates the instance.

ManagedResource withLocation(String location)

Set the location property: Resource location.

ManagedResource withTags(Map<String,String> tags)

Set the tags property: Resource tags.

Methods inherited from ProxyResource

Methods inherited from java.lang.Object

Constructor Details

ManagedResource

public ManagedResource()

Creates an instance of ManagedResource class.

Method Details

fromJson

public static ManagedResource fromJson(JsonReader jsonReader)

Reads an instance of ManagedResource from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

An instance of ManagedResource 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: Fully qualified resource Id for the resource.

Overrides:

ManagedResource.id()

Returns:

the id value.

location

public String location()

Get the location property: Resource location.

Returns:

the location value.

name

public String name()

Get the name property: The name of the resource.

Overrides:

ManagedResource.name()

Returns:

the name value.

tags

public Map<String,String> tags()

Get the tags property: Resource tags.

Returns:

the tags value.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Overrides:

ManagedResource.toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

type

public String type()

Get the type property: The type of the resource.

Overrides:

ManagedResource.type()

Returns:

the type value.

validate

public void validate()

Validates the instance.

withLocation

public ManagedResource withLocation(String location)

Set the location property: Resource location.

Parameters:

location - the location value to set.

Returns:

the ManagedResource object itself.

withTags

public ManagedResource withTags(Map<String,String> tags)

Set the tags property: Resource tags.

Parameters:

tags - the tags value to set.

Returns:

the ManagedResource object itself.

Applies to