
    	
                         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Zd	Z ej                  ej                  j                  ej                  j                          G d
 dej"                               Zy)zECommand to get the status of a Distributed Cloud Edge Network router.    )absolute_import)division)unicode_literals)routers)base)resource_argszDGet the status of a specified Distributed Cloud Edge Network router.z    To get the status of the Distributed Cloud Edge Network router
    'my-router' in edge zone 'us-central1-edge-den1' , run:

        $ {command} my-router --location=us-central1 --zone=us-central1-edge-den1

   c                   6    e Zd ZdZeedZed        Zd Z	d Z
y)	GetStatuszGet the status of a specified Distributed Cloud Edge Network router.

  *{command}* is used to get the status of a Distributed Cloud Edge Network
  router.
  )DESCRIPTIONEXAMPLESc                 2    t        j                  | dd       y )Nzto get statusT)r   AddRouterResourceArg)parsers    7lib/surface/edge_cloud/networking/routers/get_status.pyArgszGetStatus.Args.   s    &&vE    c                 p    |j                   j                  D ]  }t        |j                        |_         |S )z?Make the nextHopReachable value explicit for each route status.)resultstaticRouteStatusboolnextHopReachable)selfrouter_statusroute_statuss      r   _PreprocessResultzGetStatus._PreprocessResult2   s3    
 &,,>>&*<+H+H&Il# ?r   c                 H   t        j                  | j                               }|j                  j                  j                         }| j                         t        j                  j                  k(  r|j                  |      S | j                  |j                  |            S )N)
r   RoutersClientReleaseTrackCONCEPTSrouterParser   GAr
   r   )r   argsrouters_client
router_refs       r   RunzGetStatus.Run;   s}    **4+<+<+>?N%%++-Jd//222%%j11!!.":"::"FGGr   N)__name__
__module____qualname____doc__r   r   detailed_helpstaticmethodr   r   r&    r   r   r
   r
   $   s2     #.8D-F FHr   r
   N)r*   
__future__r   r   r   4googlecloudsdk.api_lib.edge_cloud.networking.routersr   googlecloudsdk.callioper   0googlecloudsdk.command_lib.edge_cloud.networkingr   r   r   ReleaseTracksr   ALPHAr"   Commandr
   r-   r   r   <module>r5      sy    L &  ' H ( J K  D%%++T->->-A-ABH H CHr   