
                             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\R                  5      rg)z4A command that describes a message from a given API.    )absolute_import)division)unicode_literals)base)
exceptions)flags)	arg_utils)registryc                   .    \ rS rSrSr\S 5       rS rSrg)Describe   z2Describe the details of a proto message in an API.c                     [         R                  R                  U 5        [         R                  R                  U 5        U R	                  SSS9  g )Nmessagez-The name of the message you want to describe.)help)r   API_REQUIRED_FLAGAddToParserAPI_VERSION_FLAGadd_argument)parsers    *lib/surface/meta/apis/messages/describe.pyArgsDescribe.Args    sC    	''/	&&v.
<  >    c                 \   [         R                  " UR                  UR                  S9n [	        UR                  5       UR                  5      n[        R                  " U5      $ ! [         a<    [        R                  " SSR                  UR                  UR                  5      5      ef = f)N)api_versionr   z(Message [{}] does not exist for API [{}])r
   GetAPIapir   getattrGetMessagesModuler   r	   GetRecursiveMessageSpecAttributeErrorr   InvalidArgumentExceptionformat)selfargsr   r   s       r   RunDescribe.Run(   s    
//$((0@0@
AC'--/>g..w77 '//
?FFllDHH&' ''s   9A% %AB+ N)	__name__
__module____qualname____firstlineno____doc__staticmethodr   r&   __static_attributes__r(   r   r   r   r      s    :> >'r   r   N)r-   
__future__r   r   r   googlecloudsdk.callioper   r   $googlecloudsdk.command_lib.meta.apisr   $googlecloudsdk.command_lib.util.apisr	   r
   DescribeCommandr   r(   r   r   <module>r5      s4     ; &  ' ( . 6 : 9't## 'r   