
                             S r SSKJr  SSKJr  SSKJr  SSKrSSKJr  SSKJ	r	  SSK
Jr  S	S
S.r\	R                  R                  4r\	R                    " S S\	R"                  5      5       r\\l        g)zDelete endpoint command.    )absolute_import)division)unicode_literalsN)activation_api)base)activation_flagsz
          Delete a firewall endpoint. Check the progress of endpoint deletion
          by using `gcloud network-security firewall-endpoints list`.

          For more examples, refer to the EXAMPLES section below.

        aM  
            To delete a firewall endpoint called `my-endpoint`, in zone
            `us-central1-a` and organization ID 1234, run:

            $ {command} my-endpoint --zone=us-central1-a --organization=1234

            OR

            $ {command} organizations/1234/locations/us-central1-a/firewallEndpoints/my-endpoint

        )DESCRIPTIONEXAMPLESc                   .    \ rS rSrSr\S 5       rS rSrg)Delete4   z Delete a Firewall Plus endpoint.c                 *   U R                  5       [        ;   n[        R                  " U R                  5       UU5        [        R                  " US5        [
        R                  R                  U5        [
        R                  R                  US5        g )N60mT)	ReleaseTrack_PROJECT_SCOPE_SUPPORTED_TRACKSr   AddEndpointResource
AddMaxWaitr   
ASYNC_FLAGAddToParser
SetDefault)clsparserproject_scope_supporteds      9lib/surface/network_security/firewall_endpoints/delete.pyArgsDelete.Args8   su     	==  ((
 .OO'OOvt,    c                 P   UR                   R                  R                  5       nUR                  nUR                  R
                  [        R                  :H  n[        R                  " U R                  5       U5      nUR                  n[        R                  " UR                  S9nUR                  UR!                  5       S9nU(       a  UR#                  S5      (       d  SUl        U$ UR'                  UR)                  U5      SR%                  UR!                  5       5      SUS9$ )N)seconds)nameformatdefaultz0waiting for firewall endpoint [{}] to be deletedF)operation_refmessage
has_resultmax_wait)CONCEPTSfirewall_endpointParseresultconcept_typer    r   $PROJECT_ENDPOINT_RESOURCE_COLLECTIONr   Clientr   async_datetime	timedeltar&   DeleteEndpointRelativeNameIsSpecifiedr!   WaitForOperationGetOperationRef)	selfargsr*   endpointproject_scopedclientis_asyncr&   	operations	            r   Run
Delete.RunF   s   ]],,224F}}H 	  @@	A 
 ""4#4#4#6GF{{H!!$--8H%%""$ & I  h''"",,Y7BII!!#
  #  r    N)	__name__
__module____qualname____firstlineno____doc__classmethodr   r=   __static_attributes__r?   r   r   r   r   4   s    (- -r   r   )rD   
__future__r   r   r   r/   :googlecloudsdk.api_lib.network_security.firewall_endpointsr   googlecloudsdk.callioper   +googlecloudsdk.command_lib.network_securityr   DETAILED_HELPr   ALPHAr   DefaultUniverseOnlyDeleteCommandr   detailed_helpr?   r   r   <module>rP      s{     &  '  U ( H
, 	# 
 0T 0 0f % r   