Class InboundNatRule

java.lang.Object
com.azure.resourcemanager.devtestlabs.models.InboundNatRule

public final class InboundNatRule extends Object
A rule for NAT - exposing a VM's port (backendPort) on the public IP address using a load balancer.
  • Constructor Details

    • InboundNatRule

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

    • transportProtocol

      public TransportProtocol transportProtocol()
      Get the transportProtocol property: The transport protocol for the endpoint.
      Returns:
      the transportProtocol value.
    • withTransportProtocol

      public InboundNatRule withTransportProtocol(TransportProtocol transportProtocol)
      Set the transportProtocol property: The transport protocol for the endpoint.
      Parameters:
      transportProtocol - the transportProtocol value to set.
      Returns:
      the InboundNatRule object itself.
    • frontendPort

      public Integer frontendPort()
      Get the frontendPort property: The external endpoint port of the inbound connection. Possible values range between 1 and 65535, inclusive. If unspecified, a value will be allocated automatically.
      Returns:
      the frontendPort value.
    • withFrontendPort

      public InboundNatRule withFrontendPort(Integer frontendPort)
      Set the frontendPort property: The external endpoint port of the inbound connection. Possible values range between 1 and 65535, inclusive. If unspecified, a value will be allocated automatically.
      Parameters:
      frontendPort - the frontendPort value to set.
      Returns:
      the InboundNatRule object itself.
    • backendPort

      public Integer backendPort()
      Get the backendPort property: The port to which the external traffic will be redirected.
      Returns:
      the backendPort value.
    • withBackendPort

      public InboundNatRule withBackendPort(Integer backendPort)
      Set the backendPort property: The port to which the external traffic will be redirected.
      Parameters:
      backendPort - the backendPort value to set.
      Returns:
      the InboundNatRule object itself.
    • validate

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