NameAvailabilityRequest Class

  • java.lang.Object
    • com.azure.resourcemanager.datamigration.models.NameAvailabilityRequest

Implements

public final class NameAvailabilityRequest
implements JsonSerializable<NameAvailabilityRequest>

A resource type and proposed name.

Constructor Summary

Constructor Description
NameAvailabilityRequest()

Creates an instance of NameAvailabilityRequest class.

Method Summary

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

Reads an instance of NameAvailabilityRequest from the JsonReader.

String name()

Get the name property: The proposed resource name.

JsonWriter toJson(JsonWriter jsonWriter)
String type()

Get the type property: The resource type chain (e.g.

void validate()

Validates the instance.

NameAvailabilityRequest withName(String name)

Set the name property: The proposed resource name.

NameAvailabilityRequest withType(String type)

Set the type property: The resource type chain (e.g.

Methods inherited from java.lang.Object

Constructor Details

NameAvailabilityRequest

public NameAvailabilityRequest()

Creates an instance of NameAvailabilityRequest class.

Method Details

fromJson

public static NameAvailabilityRequest fromJson(JsonReader jsonReader)

Reads an instance of NameAvailabilityRequest from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

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

name

public String name()

Get the name property: The proposed resource name.

Returns:

the name value.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

type

public String type()

Get the type property: The resource type chain (e.g. virtualMachines/extensions).

Returns:

the type value.

validate

public void validate()

Validates the instance.

withName

public NameAvailabilityRequest withName(String name)

Set the name property: The proposed resource name.

Parameters:

name - the name value to set.

Returns:

the NameAvailabilityRequest object itself.

withType

public NameAvailabilityRequest withType(String type)

Set the type property: The resource type chain (e.g. virtualMachines/extensions).

Parameters:

type - the type value to set.

Returns:

the NameAvailabilityRequest object itself.

Applies to