Class VpnNatRuleMapping

java.lang.Object
com.azure.resourcemanager.network.models.VpnNatRuleMapping
All Implemented Interfaces:
com.azure.json.JsonSerializable<VpnNatRuleMapping>

public final class VpnNatRuleMapping extends Object implements com.azure.json.JsonSerializable<VpnNatRuleMapping>
Vpn NatRule mapping.
  • Constructor Details

    • VpnNatRuleMapping

      public VpnNatRuleMapping()
      Creates an instance of VpnNatRuleMapping class.
  • Method Details

    • addressSpace

      public String addressSpace()
      Get the addressSpace property: Address space for Vpn NatRule mapping.
      Returns:
      the addressSpace value.
    • withAddressSpace

      public VpnNatRuleMapping withAddressSpace(String addressSpace)
      Set the addressSpace property: Address space for Vpn NatRule mapping.
      Parameters:
      addressSpace - the addressSpace value to set.
      Returns:
      the VpnNatRuleMapping object itself.
    • portRange

      public String portRange()
      Get the portRange property: Port range for Vpn NatRule mapping.
      Returns:
      the portRange value.
    • withPortRange

      public VpnNatRuleMapping withPortRange(String portRange)
      Set the portRange property: Port range for Vpn NatRule mapping.
      Parameters:
      portRange - the portRange value to set.
      Returns:
      the VpnNatRuleMapping object itself.
    • validate

      public void validate()
      Validates the instance.
      Throws:
      IllegalArgumentException - thrown if the instance is not valid.
    • toJson

      public com.azure.json.JsonWriter toJson(com.azure.json.JsonWriter jsonWriter) throws IOException
      Specified by:
      toJson in interface com.azure.json.JsonSerializable<VpnNatRuleMapping>
      Throws:
      IOException
    • fromJson

      public static VpnNatRuleMapping fromJson(com.azure.json.JsonReader jsonReader) throws IOException
      Reads an instance of VpnNatRuleMapping from the JsonReader.
      Parameters:
      jsonReader - The JsonReader being read.
      Returns:
      An instance of VpnNatRuleMapping 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 VpnNatRuleMapping.