Class DnsConfig
java.lang.Object
com.azure.resourcemanager.trafficmanager.models.DnsConfig
- All Implemented Interfaces:
com.azure.json.JsonSerializable<DnsConfig>
Class containing DNS settings in a Traffic Manager profile.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionfqdn()Get the fqdn property: The fully-qualified domain name (FQDN) of the Traffic Manager profile.static DnsConfigfromJson(com.azure.json.JsonReader jsonReader) Reads an instance of DnsConfig from the JsonReader.Get the relativeName property: The relative DNS name provided by this Traffic Manager profile.com.azure.json.JsonWritertoJson(com.azure.json.JsonWriter jsonWriter) ttl()Get the ttl property: The DNS Time-To-Live (TTL), in seconds.voidvalidate()Validates the instance.withRelativeName(String relativeName) Set the relativeName property: The relative DNS name provided by this Traffic Manager profile.Set the ttl property: The DNS Time-To-Live (TTL), in seconds.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.azure.json.JsonSerializable
toJson, toJson, toJsonBytes, toJsonString
-
Constructor Details
-
DnsConfig
public DnsConfig()Creates an instance of DnsConfig class.
-
-
Method Details
-
relativeName
Get the relativeName property: The relative DNS name provided by this Traffic Manager profile. This value is combined with the DNS domain name used by Azure Traffic Manager to form the fully-qualified domain name (FQDN) of the profile.- Returns:
- the relativeName value.
-
withRelativeName
Set the relativeName property: The relative DNS name provided by this Traffic Manager profile. This value is combined with the DNS domain name used by Azure Traffic Manager to form the fully-qualified domain name (FQDN) of the profile.- Parameters:
relativeName- the relativeName value to set.- Returns:
- the DnsConfig object itself.
-
fqdn
Get the fqdn property: The fully-qualified domain name (FQDN) of the Traffic Manager profile. This is formed from the concatenation of the RelativeName with the DNS domain used by Azure Traffic Manager.- Returns:
- the fqdn value.
-
ttl
Get the ttl property: The DNS Time-To-Live (TTL), in seconds. This informs the local DNS resolvers and DNS clients how long to cache DNS responses provided by this Traffic Manager profile.- Returns:
- the ttl value.
-
withTtl
Set the ttl property: The DNS Time-To-Live (TTL), in seconds. This informs the local DNS resolvers and DNS clients how long to cache DNS responses provided by this Traffic Manager profile.- Parameters:
ttl- the ttl value to set.- Returns:
- the DnsConfig object itself.
-
validate
public void validate()Validates the instance.- Throws:
IllegalArgumentException- thrown if the instance is not valid.
-
toJson
- Specified by:
toJsonin interfacecom.azure.json.JsonSerializable<DnsConfig>- Throws:
IOException
-
fromJson
Reads an instance of DnsConfig from the JsonReader.- Parameters:
jsonReader- The JsonReader being read.- Returns:
- An instance of DnsConfig 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 DnsConfig.
-