Region Class
- java.
lang. Object - com.
azure. resourcemanager. trafficmanager. models. Region
- com.
Implements
public final class Region
implements JsonSerializable<Region>
Class representing a region in the Geographic hierarchy used with the Geographic traffic routing method.
Constructor Summary
Constructor | Description |
---|---|
Region() |
Creates an instance of Region class. |
Method Summary
Modifier and Type | Method and Description |
---|---|
String |
code()
Get the code property: The code of the region. |
static Region |
fromJson(JsonReader jsonReader)
Reads an instance of Region from the Json |
String |
name()
Get the name property: The name of the region. |
List<Region> |
regions()
Get the regions property: The list of Regions grouped under this Region in the Geographic Hierarchy. |
Json |
toJson(JsonWriter jsonWriter) |
void |
validate()
Validates the instance. |
Region |
withCode(String code)
Set the code property: The code of the region. |
Region |
withName(String name)
Set the name property: The name of the region. |
Region |
withRegions(List<Region> regions)
Set the regions property: The list of Regions grouped under this Region in the Geographic Hierarchy. |
Methods inherited from java.lang.Object
Constructor Details
Region
public Region()
Creates an instance of Region class.
Method Details
code
public String code()
Get the code property: The code of the region.
Returns:
fromJson
public static Region fromJson(JsonReader jsonReader)
Reads an instance of Region from the JsonReader.
Parameters:
Returns:
Throws:
name
public String name()
Get the name property: The name of the region.
Returns:
regions
public List
Get the regions property: The list of Regions grouped under this Region in the Geographic Hierarchy.
Returns:
toJson
validate
public void validate()
Validates the instance.
withCode
public Region withCode(String code)
Set the code property: The code of the region.
Parameters:
Returns:
withName
public Region withName(String name)
Set the name property: The name of the region.
Parameters:
Returns:
withRegions
public Region withRegions(List
Set the regions property: The list of Regions grouped under this Region in the Geographic Hierarchy.
Parameters:
Returns:
Applies to
Azure SDK for Java