
    
                     *   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	lmZ dd
lmZ ddlmZ dZ e	j&                  e	j(                  j*                  e	j(                  j,                         G d de	j.                               Zy)z7Command to list node pools in an Anthos cluster on AWS.    )absolute_import)division)unicode_literals)aws)base)resource_args)	constants)endpoint_util)versions)logz
To list all node pools in a cluster named ``my-cluster''
managed in location ``us-west1'', run:

$ {command} --cluster=my-cluster --location=us-west1
c                   @     e Zd ZdZdeiZed        Zd Z fdZ	 xZ
S )Listz,List node pools in an Anthos cluster on AWS.EXAMPLESc                     t        j                  | dd       | j                  j                  t        j
                         y )Nzto listF)
positional)r   AddAwsClusterResourceArgdisplay_info	AddFormatr	   AWS_NODEPOOLS_FORMAT)parsers    ,lib/surface/container/aws/node_pools/list.pyArgsz	List.Args,   s.    **69O
!!)"@"@A    c                    d| _         |j                  j                  j                         }t	        j
                  |j                        5  t        j                         }|j                  ||j                  |j                        \  }}|r|cddd       S t        j                  }t        j                  |||      \  }}|rt        j                   ||      | _         |cddd       S # 1 sw Y   yxY w)zRuns the list command.N)_upgrade_hintCONCEPTSclusterParser
   GkemulticloudEndpointOverridelocationsIdapi_utilNodePoolsClientr   	page_sizelimitr	   AWSr   !generate_node_pool_versions_tableupgrade_hint_node_pool_list)	selfargscluster_refnode_pool_clientitemsis_emptyplatformnode_pool_info_tableend_of_life_flags	            r   RunzList.Run1   s    D--''--/K		4	4[5L5L	M!113(--
t~~tzzoeX 
 
N	M h

4
4 -, 
%AAk
 ") 
N	M	Ms   AC)AC))C2c                     t         t        |   |       | j                  r*t        j
                  j                  | j                         y y )N)superr   Epilogr   r   statusPrint)r(   results_were_displayed	__class__s     r   r4   zList.EpilogK   s9    	$34	jjt))* r   )__name__
__module____qualname____doc__	_EXAMPLESdetailed_helpstaticmethodr   r1   r4   __classcell__)r8   s   @r   r   r   &   s3    4y)-B B"4+ +r   r   N)r<   
__future__r   r   r   .googlecloudsdk.api_lib.container.gkemulticloudr   r!   googlecloudsdk.callioper   (googlecloudsdk.command_lib.container.awsr   2googlecloudsdk.command_lib.container.gkemulticloudr	   r
   r   googlecloudsdk.corer   r=   ReleaseTracksReleaseTrackALPHAGAListCommandr    r   r   <module>rM      sx    > &  ' J ( B H L G #	 D%%++T->->-A-AB'+4 '+ C'+r   