다음을 통해 공유


Hostname Class

  • java.lang.Object
    • com.azure.resourcemanager.appservice.models.Hostname

Implements

public final class Hostname
implements JsonSerializable<Hostname>

Details of a hostname derived from a domain.

Constructor Summary

Constructor Description
Hostname()

Creates an instance of Hostname class.

Method Summary

Modifier and Type Method and Description
String azureResourceName()

Get the azureResourceName property: Name of the Azure resource the hostname is assigned to.

AzureResourceType azureResourceType()

Get the azureResourceType property: Type of the Azure resource the hostname is assigned to.

CustomHostnameDnsRecordType customHostnameDnsRecordType()

Get the customHostnameDnsRecordType property: Type of the DNS record.

static Hostname fromJson(JsonReader jsonReader)

Reads an instance of Hostname from the JsonReader.

HostnameType hostnameType()

Get the hostnameType property: Type of the hostname.

String name()

Get the name property: Name of the hostname.

List<String> siteNames()

Get the siteNames property: List of apps the hostname is assigned to.

JsonWriter toJson(JsonWriter jsonWriter)
void validate()

Validates the instance.

Hostname withAzureResourceName(String azureResourceName)

Set the azureResourceName property: Name of the Azure resource the hostname is assigned to.

Hostname withAzureResourceType(AzureResourceType azureResourceType)

Set the azureResourceType property: Type of the Azure resource the hostname is assigned to.

Hostname withCustomHostnameDnsRecordType(CustomHostnameDnsRecordType customHostnameDnsRecordType)

Set the customHostnameDnsRecordType property: Type of the DNS record.

Hostname withHostnameType(HostnameType hostnameType)

Set the hostnameType property: Type of the hostname.

Hostname withName(String name)

Set the name property: Name of the hostname.

Hostname withSiteNames(List<String> siteNames)

Set the siteNames property: List of apps the hostname is assigned to.

Methods inherited from java.lang.Object

Constructor Details

Hostname

public Hostname()

Creates an instance of Hostname class.

Method Details

azureResourceName

public String azureResourceName()

Get the azureResourceName property: Name of the Azure resource the hostname is assigned to. If it is assigned to a Traffic Manager then it will be the Traffic Manager name otherwise it will be the app name.

Returns:

the azureResourceName value.

azureResourceType

public AzureResourceType azureResourceType()

Get the azureResourceType property: Type of the Azure resource the hostname is assigned to.

Returns:

the azureResourceType value.

customHostnameDnsRecordType

public CustomHostnameDnsRecordType customHostnameDnsRecordType()

Get the customHostnameDnsRecordType property: Type of the DNS record.

Returns:

the customHostnameDnsRecordType value.

fromJson

public static Hostname fromJson(JsonReader jsonReader)

Reads an instance of Hostname from the JsonReader.

Parameters:

jsonReader - The JsonReader being read.

Returns:

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

hostnameType

public HostnameType hostnameType()

Get the hostnameType property: Type of the hostname.

Returns:

the hostnameType value.

name

public String name()

Get the name property: Name of the hostname.

Returns:

the name value.

siteNames

public List siteNames()

Get the siteNames property: List of apps the hostname is assigned to. This list will have more than one app only if the hostname is pointing to a Traffic Manager.

Returns:

the siteNames value.

toJson

public JsonWriter toJson(JsonWriter jsonWriter)

Parameters:

jsonWriter

Throws:

validate

public void validate()

Validates the instance.

withAzureResourceName

public Hostname withAzureResourceName(String azureResourceName)

Set the azureResourceName property: Name of the Azure resource the hostname is assigned to. If it is assigned to a Traffic Manager then it will be the Traffic Manager name otherwise it will be the app name.

Parameters:

azureResourceName - the azureResourceName value to set.

Returns:

the Hostname object itself.

withAzureResourceType

public Hostname withAzureResourceType(AzureResourceType azureResourceType)

Set the azureResourceType property: Type of the Azure resource the hostname is assigned to.

Parameters:

azureResourceType - the azureResourceType value to set.

Returns:

the Hostname object itself.

withCustomHostnameDnsRecordType

public Hostname withCustomHostnameDnsRecordType(CustomHostnameDnsRecordType customHostnameDnsRecordType)

Set the customHostnameDnsRecordType property: Type of the DNS record.

Parameters:

customHostnameDnsRecordType - the customHostnameDnsRecordType value to set.

Returns:

the Hostname object itself.

withHostnameType

public Hostname withHostnameType(HostnameType hostnameType)

Set the hostnameType property: Type of the hostname.

Parameters:

hostnameType - the hostnameType value to set.

Returns:

the Hostname object itself.

withName

public Hostname withName(String name)

Set the name property: Name of the hostname.

Parameters:

name - the name value to set.

Returns:

the Hostname object itself.

withSiteNames

public Hostname withSiteNames(List siteNames)

Set the siteNames property: List of apps the hostname is assigned to. This list will have more than one app only if the hostname is pointing to a Traffic Manager.

Parameters:

siteNames - the siteNames value to set.

Returns:

the Hostname object itself.

Applies to