
    	                         d Z ddlmZ ddlmZ ddlmZ ddlmZ ddlmZ ddl	m
Z
 ddlmZ d	d
dZ ej                  ej                  j                          G d dej"                               Zy)z!'vmware clusters delete' command.    )absolute_import)division)unicode_literals)ClustersClient)base)flags)logzF
          Delete a cluster in a VMware Engine private cloud.
        a  
          To delete a cluster called `my-cluster` in private cloud `my-private-cloud` and zone `us-west2-a`, run:

            $ {command} my-cluster --location=us-west2-a --project=my-project --private-cloud=my-private-cloud

            Or:

            $ {command} my-cluster --private-cloud=my-private-cloud

          In the second example, the project and location are taken from gcloud properties core/project and compute/zone.
    )DESCRIPTIONEXAMPLESc                   *    e Zd ZdZeZed        Zd Zy)Deletez,Delete a Google Cloud VMware Engine cluster.c                     t        j                  | d       t        j                  j	                  |        t        j                  j                  | d       y)z Register flags for this command.T)
positionalN)r   AddClusterArgToParserr   
ASYNC_FLAGAddToParser
SetDefault)parsers    4lib/surface/vmware/private_clouds/clusters/delete.pyArgszDelete.Args4   s:     
48OO'OOvt,    c                 d   |j                   j                  j                         }t               }|j                  }|j                  |      }|r$t        j                  |j                  dd       |S |j                  |j                  |      dj                  |j                               d      S )NclusterT)kindis_asyncz&waiting for cluster [{}] to be deletedF)operation_refmessage
has_result)CONCEPTSr   Parser   async_r   r	   DeletedResourcenameWaitForOperationGetOperationRefformatRelativeName)selfargsr   clientr   	operations         r   Runz
Delete.Run;   s    mm##))+GF{{Hg&I	)..y4H"",,Y78??  "$	 #  r   N)	__name__
__module____qualname____doc__DETAILED_HELPdetailed_helpstaticmethodr   r,    r   r   r   r   .   s!    4-- -r   r   N)r0   
__future__r   r   r   &googlecloudsdk.api_lib.vmware.clustersr   googlecloudsdk.callioper   !googlecloudsdk.command_lib.vmwarer   googlecloudsdk.corer	   r1   ReleaseTracksReleaseTrackGADeleteCommandr   r4   r   r   <module>r>      sj    ( &  ' A ( 3 #	
	( D%%(()T  *r   