
    e                         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  S	S
S.r\R                  " \R                  R                   5       " S S\R"                  5      5       rg)z+'vmware external-addresses update' command.    )absolute_import)division)unicode_literals)externaladdresses)base)flags)logz
          Updates an external IP address in a VMware Engine private cloud. Only description and internal-ip can be updated.
        a  
          To update an external IP address called `myip` that belongs to the private cloud `my-private-cloud` in project `my-project` and location `us-west1-a` by changing its description to `"Updated description for the external IP address"` and internal-ip to `165.87.54.14`, run:

            $ {command} myip --project=my-project --private-cloud=my-private-cloud --location=us-west1-a --internal-ip=165.87.54.14 --description="Updated description for the external IP address"

          Or:

            $ {command} myip --private-cloud=my-private-cloud --internal-ip=165.87.54.14 --description="Updated description for the external IP address"

          In the second example, the project and region are taken from gcloud properties core/project and vmware/region.
    )DESCRIPTIONEXAMPLESc                   2    \ rS rSrSr\r\S 5       rS r	Sr
g)Update,   z?Update an external IP address in a VMware Engine private cloud.c                 $   [         R                  " U 5        [        R                  R	                  U 5        [        R                  R                  U S5        U R                  R                  S5        U R                  SSS9  U R                  SSS9  g)	z Register flags for this command.Tyamlz--internal-ipzF        Updated internal ip address for this external address
        )helpz--descriptionz>        Updated description for this external address
        N)	r   AddExternalAddressArgToParserr   
ASYNC_FLAGAddToParser
SetDefaultdisplay_info	AddFormatadd_argument)parsers    >lib/surface/vmware/private_clouds/external_addresses/update.pyArgsUpdate.Args2   s     
''/OO'OOvt,
!!&)
         c                    UR                   R                  R                  5       n[        R                  " 5       nUR
                  nUR                  X!R                  UR                  5      nU(       a!  [        R                  " UR                  SSS9  g UR                  UR                  U5      SR                  UR                  5       5      S9n[        R                  " UR                  5       SS9  U$ )Nzexternal addressT)kindis_asyncz/waiting for external address [{}] to be updated)operation_refmessage)r   )CONCEPTSexternal_addressParser   ExternalAddressesClientasync_r   internal_ipdescriptionr	   UpdatedResourcenameWaitForOperationGetOperationRefformatRelativeName)selfargsr$   clientr    	operationresources          r   Run
Update.RunF   s    }}55;;=668F{{H**D,<,<I 	
..1D &&,,Y7AHH))+
 ' H %%'.@ Or    N)__name__
__module____qualname____firstlineno____doc__DETAILED_HELPdetailed_helpstaticmethodr   r5   __static_attributes__r7   r   r   r   r   ,   s!    G- &r   r   N)r<   
__future__r   r   r   googlecloudsdk.api_lib.vmwarer   googlecloudsdk.callioper   !googlecloudsdk.command_lib.vmwarer   googlecloudsdk.corer	   r=   ReleaseTracksReleaseTrackGAUpdateCommandr   r7   r   r   <module>rJ      sh    2 &  ' ; ( 3 #
	$ D%%(()/T / */r   