text: # coding=utf-8
  # --------------------------------------------------------------------------
  # Code generated by Microsoft (R) AutoRest Code Generator.
  # Changes may cause incorrect behavior and will be lost if the code is
  # regenerated.
  # --------------------------------------------------------------------------
  
  from .firewall_policy_rule_py3 import FirewallPolicyRule
  
  
  class ApplicationRule(FirewallPolicyRule):
      """Rule of type application.
  
      All required parameters must be populated in order to send to Azure.
  
      :param name: Name of the rule.
      :type name: str
      :param description: Description of the rule.
      :type description: str
      :param rule_type: Required. Constant filled by server.
      :type rule_type: str
      :param source_addresses: List of source IP addresses for this rule.
      :type source_addresses: list[str]
      :param destination_addresses: List of destination IP addresses or Service
       Tags.
      :type destination_addresses: list[str]
      :param protocols: Array of Application Protocols.
      :type protocols:
       list[~firewallpolicy.models.FirewallPolicyRuleApplicationProtocol]
      :param target_fqdns: List of FQDNs for this rule.
      :type target_fqdns: list[str]
      :param fqdn_tags: List of FQDN Tags for this rule.
      :type fqdn_tags: list[str]
      :param source_ip_groups: List of source IpGroups for this rule.
      :type source_ip_groups: list[str]
      """
  
      _validation = {
          'rule_type': {'required': True},
      }
  
      _attribute_map = {
          'name': {'key': 'name', 'type': 'str'},
          'description': {'key': 'description', 'type': 'str'},
          'rule_type': {'key': 'ruleType', 'type': 'str'},
          'source_addresses': {'key': 'sourceAddresses', 'type': '[str]'},
          'destination_addresses': {'key': 'destinationAddresses', 'type': '[str]'},
          'protocols': {'key': 'protocols', 'type': '[FirewallPolicyRuleApplicationProtocol]'},
          'target_fqdns': {'key': 'targetFqdns', 'type': '[str]'},
          'fqdn_tags': {'key': 'fqdnTags', 'type': '[str]'},
          'source_ip_groups': {'key': 'sourceIpGroups', 'type': '[str]'},
      }
  
      def __init__(self, *, name: str=None, description: str=None, source_addresses=None, destination_addresses=None, protocols=None, target_fqdns=None, fqdn_tags=None, source_ip_groups=None, **kwargs) -> None:
          super(ApplicationRule, self).__init__(name=name, description=description, **kwargs)
          self.source_addresses = source_addresses
          self.destination_addresses = destination_addresses
          self.protocols = protocols
          self.target_fqdns = target_fqdns
          self.fqdn_tags = fqdn_tags
          self.source_ip_groups = source_ip_groups
          self.rule_type = 'ApplicationRule'
  