Class FirewallPolicyRuleApplicationProtocol

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

public final class FirewallPolicyRuleApplicationProtocol extends Object implements com.azure.json.JsonSerializable<FirewallPolicyRuleApplicationProtocol>
Properties of the application rule protocol.
  • Constructor Details

    • FirewallPolicyRuleApplicationProtocol

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

    • protocolType

      Get the protocolType property: Protocol type.
      Returns:
      the protocolType value.
    • withProtocolType

      Set the protocolType property: Protocol type.
      Parameters:
      protocolType - the protocolType value to set.
      Returns:
      the FirewallPolicyRuleApplicationProtocol object itself.
    • port

      public Integer port()
      Get the port property: Port number for the protocol, cannot be greater than 64000.
      Returns:
      the port value.
    • withPort

      Set the port property: Port number for the protocol, cannot be greater than 64000.
      Parameters:
      port - the port value to set.
      Returns:
      the FirewallPolicyRuleApplicationProtocol 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<FirewallPolicyRuleApplicationProtocol>
      Throws:
      IOException
    • fromJson

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