
    
                         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	K	Jr  SS
KJr  \R                  " \R                   R"                  5       " S S\R$                  5      5       rg)zExport preview results.    )absolute_import)division)unicode_literals)configmanager_util)base)deploy_util)flags)resource_args)concept_parsersc                   6    \ rS rSrSrSS0r\S 5       rS rSr	g)	Export   z\Export preview results.

This command generates a signed url to download a preview results.
EXAMPLESz
        Export preview results for `my-preview`:

          $ {command} projects/p1/locations/us-central1/previews/my-preview

      c                     Sn[         R                  " X5        [        R                  " [        R
                  " S5      /5      R                  U 5        g )Nal          File name for preview export artifacts. It is optional and it specifies
        the filename or complete path for the downloaded preview export
        artifacts. If only a file path is provided, the artifacts will be
        downloaded as "preview" within that directory. If a filename is
        included, the artifacts will be downloaded with that name.z!the preview to be used as parent.)r	   AddFileFlagr   ConceptParserr
   GetPreviewResourceArgSpecAddToParser)parserflag_help_texts     ,lib/surface/infra_manager/previews/export.pyArgsExport.Args+   sJ    FN 
f-!!333	
 k&    c                     [         R                  " 5       nUR                  R                  R	                  5       nUR                  5       n[        R                  " UUUR                  5      $ )a  This is what gets called when the user runs this command.

Args:
  args: an argparse namespace. All the arguments that were provided to this
    command invocation.

Returns:
  Preview results containing signed urls that can be used to download the
  binary and json plans.
)	r   GetMessagesModuleCONCEPTSpreviewParseRelativeNamer   ExportPreviewResultfile)selfargsmessagespreview_refpreview_full_names        r   Run
Export.Run<   sY     "335H--''--/K#002**		 r    N)
__name__
__module____qualname____firstlineno____doc__detailed_helpstaticmethodr   r(   __static_attributes__r*   r   r   r   r      s1    
   
 -   r   r   N)r/   
__future__r   r   r   $googlecloudsdk.api_lib.infra_managerr   googlecloudsdk.callioper   (googlecloudsdk.command_lib.infra_managerr   r	   r
   (googlecloudsdk.command_lib.util.conceptsr   ReleaseTracksReleaseTrackGACommandr   r*   r   r   <module>r<      s[     &  ' C ( @ : B D D%%(()1T\\ 1 *1r   