
                             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dZ ej                  ej                  j                        ej                    G d dej"                                      Zy)z7Command to list all channels in a project and location.    )absolute_import)division)unicode_literals)channels)base)flagsz{description}z         To list all channels in location `us-central1`, run:

          $ {command} --location=us-central1

        To list all channels in all locations, run:

          $ {command} --location=-

        or

          $ {command}
        )DESCRIPTIONEXAMPLESz table(
    name.scope("channels"):label=NAME,
    provider:label=PROVIDER,
    state:label=STATE,
    pubsubTopic.scope("topics"):label=PUBSUB_TOPIC
)
c                   *    e Zd ZdZeZed        Zd Zy)ListzList Eventarc channels.c                     t        j                  | ddd       t        j                  |        | j                  j	                  t
               | j                  j                  t        j                         y )NzQLocation for which to list channels. This should be one of the supported regions.FT)requiredallow_aggregation)	r   AddLocationResourceArgAddProjectResourceArgdisplay_info	AddFormat_FORMAT
AddUriFuncr   GetChannelURI)parsers    %lib/surface/eventarc/channels/list.pyArgsz	List.Args=   s\    	  	 
'
!!'*
""8#9#9:    c                    t        j                         }|j                  j                  j	                          |j                  j
                  j	                         }|j                  ||j                  |j                        S )N)	r   ChannelClientV1CONCEPTSprojectParselocationr   limit	page_size)selfargsclientlocation_refs       r   RunzList.RunJ   sY    %%'FMM!==))//1L;;|TZZ@@r   N)	__name__
__module____qualname____doc___DETAILED_HELPdetailed_helpstaticmethodr   r'    r   r   r   r   6   s$       -
; 
;Ar   r   N)r+   
__future__r   r   r   googlecloudsdk.api_lib.eventarcr   googlecloudsdk.callioper   #googlecloudsdk.command_lib.eventarcr   r,   r   ReleaseTracksReleaseTrackGADefaultUniverseOnlyListCommandr   r/   r   r   <module>r9      s    > &  ' 4 ( 5 			& D%%(()A4 A  *Ar   