Freigeben über


CheckNameAvailabilityOutput Class

  • java.lang.Object
    • com.azure.resourcemanager.search.models.CheckNameAvailabilityOutput

Implements

public final class CheckNameAvailabilityOutput
implements JsonSerializable<CheckNameAvailabilityOutput>

Output of check name availability API.

Constructor Summary

Constructor Description
CheckNameAvailabilityOutput()

Creates an instance of CheckNameAvailabilityOutput class.

Method Summary

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

Reads an instance of CheckNameAvailabilityOutput from the JsonReader.

Boolean isNameAvailable()

Get the isNameAvailable property: A value indicating whether the name is available.

String message()

Get the message property: A message that explains why the name is invalid and provides resource naming requirements.

UnavailableNameReason reason()

Get the reason property: The reason why the name is not available.

JsonWriter toJson(JsonWriter jsonWriter)
void validate()

Validates the instance.

Methods inherited from java.lang.Object

Constructor Details

CheckNameAvailabilityOutput

public CheckNameAvailabilityOutput()

Creates an instance of CheckNameAvailabilityOutput class.

Method Details

fromJson

public static CheckNameAvailabilityOutput fromJson(JsonReader jsonReader)

Reads an instance of CheckNameAvailabilityOutput from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

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

isNameAvailable

public Boolean isNameAvailable()

Get the isNameAvailable property: A value indicating whether the name is available.

Returns:

the isNameAvailable value.

message

public String message()

Get the message property: A message that explains why the name is invalid and provides resource naming requirements. Available only if 'Invalid' is returned in the 'reason' property.

Returns:

the message value.

reason

public UnavailableNameReason reason()

Get the reason property: The reason why the name is not available. 'Invalid' indicates the name provided does not match the naming requirements (incorrect length, unsupported characters, etc.). 'AlreadyExists' indicates that the name is already in use and is therefore unavailable.

Returns:

the reason value.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

validate

public void validate()

Validates the instance.

Applies to