
    r	                        S r SSKJr  SSKJr  SSKJr  SSKJr  SSK	J
r  SSKJ
r
  SSKJr  \R                  \R                  " \R                   R"                  5       " S S	\R$                  5      5       5       rS
S0\l        g)z*Command for deleting network policy rules.    )ClassVar)base_classes)client)base)flags)rules_utilsc                   T    \ rS rSr% Sr\\R                     \S'   \	S 5       r
S rSrg)Delete   zcDeletes a Compute Engine network policy rule.

*{command}* is used to delete network policy rules.
NETWORK_POLICY_ARGc                     [         R                  " SSS9U l        U R                  R                  USS9  [         R                  " U5        UR
                  R                  [         R                  5        g )NTdelete)required	operation)operation_type)r   NetworkPolicyRuleArgumentr   AddArgumentAddArgsRemoveRuledisplay_infoAddCacheUpdaterNetworkPoliciesCompleter)clsparsers     Klib/surface/compute/network_policies/traffic_classification_rules/delete.pyArgsDelete.Args&   s]    "<<C &&vh&G	F#
''(F(FG    c                 @   [         R                  " U R                  5       5      nU R                  R	                  XR
                  5      n[        R                  " X2R                  S9nUR                  UR                  [        R                  " UR                  5      S9$ )N)refcompute_client)network_policypriority)r   ComputeApiHolderReleaseTrackr   ResolveAsResource	resourcesr   NetworkPolicyRule
DeleteRuler!   r   ConvertPriorityToIntr"   )selfargsholderr   network_policy_rule_clients        r   Run
Delete.Run/   s    **4+<+<+>?F

!
!
3
3D:J:J
KC!'!9!9" &00**11$--@ 1  r    N)__name__
__module____qualname____firstlineno____doc__r   compute_flagsResourceArgument__annotations__classmethodr   r.   __static_attributes__r0   r   r   r
   r
      s3    
 }==>>H H
r   r
   EXAMPLESz    To delete a rule with priority ``10'' in a network policy
    with name ``my-policy'', in region ``region-a'', run:

      $ {command} --priority=10 --network-policy=my-policy         --network-policy-region=region-a
    N)r5   typingr   googlecloudsdk.api_lib.computer   /googlecloudsdk.api_lib.compute.network_policiesr   googlecloudsdk.callioper   "googlecloudsdk.command_lib.computer   r6   3googlecloudsdk.command_lib.compute.network_policiesr   UniverseCompatibleReleaseTracksr$   ALPHADeleteCommandr
   detailed_helpr0   r   r   <module>rG      s{    1  7 B ( E E K D%%++,T  - >   r   