
    	                         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)7Command to update a experiment in the Project/Location.    )absolute_import)division)unicode_literals)experiments)base)
exceptions)flagsz{description}z         To update a experiment with the id `my-experiment` and file path `my/path/to/yaml`, run:

          $ {command} my-experiment --file=my/path/to/yaml
        )DESCRIPTIONEXAMPLESc                   *    e Zd ZdZeZed        Zd Zy)Updater   c                 .    t        j                  |        y )N)r
   AddUpdateExperimentFlags)parsers    1lib/surface/fault_injection/experiments/update.pyArgszUpdate.Args+   s    	""6*    c                 X   t        j                         }|j                  j                  j	                         }|j                         st        j                  dd      |j                  st        j                  dd      |j                  |j                         |j                        S )zRun the create command.
experimentz experiment id must be non-empty.zfile path must be non-empty.)r   experiment_config)r   ExperimentsClientCONCEPTSr   ParseNamer	   InvalidArgumentExceptionfiler   RelativeName)selfargsclientexp_refs       r   Runz
Update.Run/   s    **,Fmm&&,,.G<<>//
:  99//
6  =='')))   r   N)	__name__
__module____qualname____doc___DETAILED_HELPdetailed_helpstaticmethodr   r#    r   r   r   r   %   s!    ? -+ +r   r   N)r'   
__future__r   r   r   &googlecloudsdk.api_lib.fault_injectionr   googlecloudsdk.callioper   r	   *googlecloudsdk.command_lib.fault_injectionr
   r(   ReleaseTracksReleaseTrackALPHAUpdateCommandr   r+   r   r   <module>r4      sj    > &  ' > ( . < # D%%++,T  -r   