
    	                         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	d
Z
 G d de	j                        Ze
e_        y)z#'logging buckets describe' command.    )absolute_import)division)unicode_literals)util)arg_parsers)basez9
        Display information about a linked dataset.
    z|
     To describe a linked dataset in a project, run:

        $ {command} my-link --bucket=my-bucket --location=global
    )DESCRIPTIONEXAMPLESc                   &    e Zd ZdZed        Zd Zy)Describez+Display information about a linked dataset.c                     | j                  dd       t        j                  | d       t        j                  | dd       | j                  ddt	        j
                  dd	      d
       y)z Register flags for this command.LINK_IDz%Id of the linked dataset to describe.)helpzlinked dataset to describeTzLocation of the bucket.z--bucketz.+zmust be non-emptyzID of bucket)requiredtyper   N)add_argumentr   AddParentArgsAddBucketLocationArgr   RegexpValidator)parsers    %lib/surface/logging/links/describe.pyArgszDescribe.Args(   si     	(OPv;<fd,EF
((0CD	      c                 B   t        j                         j                  j                  t        j                         j                  t        j                  t        j                  t        j                  |      d|j                        d|j                                    S )zThis 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:
      The specified linked dataset
    bucketslinks)name)
r   	GetClient projects_locations_buckets_linksGetGetMessages.LoggingProjectsLocationsBucketsLinksGetRequestCreateResourceNameGetBucketLocationFromArgsbucketr   )selfargss     r   RunzDescribe.Run5   s     >><<@@II((''2248)T[[  	J 	

 
r   N)__name__
__module____qualname____doc__staticmethodr   r(    r   r   r   r   %   s    3
 
r   r   N)r,   
__future__r   r   r   googlecloudsdk.api_lib.loggingr   googlecloudsdk.callioper   r   DETAILED_HELPDescribeCommandr   detailed_helpr.   r   r   <module>r5      sJ    * &  ' / / (		$t## $N ' r   