Class RoutingRuleNextHop
java.lang.Object
com.azure.resourcemanager.network.models.RoutingRuleNextHop
- All Implemented Interfaces:
com.azure.json.JsonSerializable<RoutingRuleNextHop>
public final class RoutingRuleNextHop
extends Object
implements com.azure.json.JsonSerializable<RoutingRuleNextHop>
Next hop.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic RoutingRuleNextHopfromJson(com.azure.json.JsonReader jsonReader) Reads an instance of RoutingRuleNextHop from the JsonReader.Get the nextHopAddress property: Next hop address.Get the nextHopType property: Next hop type.com.azure.json.JsonWritertoJson(com.azure.json.JsonWriter jsonWriter) voidvalidate()Validates the instance.withNextHopAddress(String nextHopAddress) Set the nextHopAddress property: Next hop address.withNextHopType(RoutingRuleNextHopType nextHopType) Set the nextHopType property: Next hop type.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
-
RoutingRuleNextHop
public RoutingRuleNextHop()Creates an instance of RoutingRuleNextHop class.
-
-
Method Details
-
nextHopType
Get the nextHopType property: Next hop type.- Returns:
- the nextHopType value.
-
withNextHopType
Set the nextHopType property: Next hop type.- Parameters:
nextHopType- the nextHopType value to set.- Returns:
- the RoutingRuleNextHop object itself.
-
nextHopAddress
Get the nextHopAddress property: Next hop address. Only required if the next hop type is VirtualAppliance.- Returns:
- the nextHopAddress value.
-
withNextHopAddress
Set the nextHopAddress property: Next hop address. Only required if the next hop type is VirtualAppliance.- Parameters:
nextHopAddress- the nextHopAddress value to set.- Returns:
- the RoutingRuleNextHop 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<RoutingRuleNextHop>- Throws:
IOException
-
fromJson
Reads an instance of RoutingRuleNextHop from the JsonReader.- Parameters:
jsonReader- The JsonReader being read.- Returns:
- An instance of RoutingRuleNextHop if the JsonReader was pointing to an instance of it, or null if it was pointing to JSON null.
- Throws:
IllegalStateException- If the deserialized JSON object was missing any required properties.IOException- If an error occurs while reading the RoutingRuleNextHop.
-