
    ^                         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 private-clouds delete' command.    )absolute_import)division)unicode_literals)PrivateCloudsClient)base)flags)logz
          Marks a VMware Engine private cloud for deletion. The resource is deleted 3 hours after being marked for deletion. This process can be reversed by using `{parent_command} undelete`.
        a]  
          To mark a private cloud called `my-private-cloud` for deletion, run:

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

          Or:

            $ {command} 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)Deletez2Delete a Google Cloud VMware Engine private cloud.c                     t        j                  | d       t        j                  j	                  |        t        j                  j                  | d       | j                  dddg dt        d       y	)
z Register flags for this command.T)
positionalz--delay-hoursF   )	r         r                  z
        Number of hours to wait before deleting the private cloud. Specifying a value of `0` for this field begins the deletion process immediately.
        )requireddefaultchoicestypehelpN)r   AddPrivatecloudArgToParserr   
ASYNC_FLAGAddToParser
SetDefaultadd_argumentint)parsers    +lib/surface/vmware/private_clouds/delete.pyArgszDelete.Args4   sa     
$$V=OO'OOvt,
+      c                 z   |j                   j                  j                         }t               }|j                  }|j                  ||j                        }|r$t        j                  |j                  dd       |S |j                  |j                  |      dj                  |j                               d      S )Nzprivate cloudT)kindis_asyncz,waiting for private cloud [{}] to be deletedF)operation_refmessage
has_result)CONCEPTSprivate_cloudParser   async_r   delay_hoursr	   DeletedResourcenameWaitForOperationGetOperationRefformatRelativeName)selfargsprivatecloudclientr)   	operations         r$   Runz
Delete.RunD   s    ==..446L "F{{HlD,<,<=I	)..N"",,Y7>EE%%')	 #  r&   N)	__name__
__module____qualname____doc__DETAILED_HELPdetailed_helpstaticmethodr%   r=    r&   r$   r   r   .   s!    :- r&   r   N)rA   
__future__r   r   r   +googlecloudsdk.api_lib.vmware.privatecloudsr   googlecloudsdk.callioper   !googlecloudsdk.command_lib.vmwarer   googlecloudsdk.corer	   rB   ReleaseTracksReleaseTrackGADeleteCommandr   rE   r&   r$   <module>rO      sj    . &  ' K ( 3 #	
	( D%%(()"T " *"r&   