
    R                         d Z ddlmZ ddlmZ ddlmZ ddlZddlmZ ddlmZ ddl	m
Z
 dd	lmZ  G d
 de
j                        Zy)z.Command for bigtable instances get-iam-policy.    )absolute_import)division)unicode_literalsN)	instances)util)base)	argumentsc                   N    e Zd ZdZd ej
                  d      iZed        Zd Z	y)GetIamPolicyz1Get the IAM policy for a Cloud Bigtable instance.EXAMPLESzk          To print the IAM policy for an instance, run:

            $ {command} my-instance-id

          c                 r    t        j                  | dd       t        j                  j	                  |        y)z Register flags for this command.zto get the IAM policy forT)
positionalN)r	   AddInstanceResourceArgr   URI_FLAGRemoveFromParser)parsers    0lib/surface/bigtable/instances/get_iam_policy.pyArgszGetIamPolicy.Args*   s,     $$+>MM""6*    c                 j    t        j                  |j                        }t        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:
      A IAM policy message.
    )r   GetInstanceRefinstancer   r   )selfargsinstance_refs      r   RunzGetIamPolicy.Run1   s)     &&t}}5L!!,//r   N)
__name__
__module____qualname____doc__textwrapdedentdetailed_helpstaticmethodr   r    r   r   r   r      s=    9 
(//  - + +0r   r   )r    
__future__r   r   r   r!   googlecloudsdk.api_lib.bigtabler   r   googlecloudsdk.callioper   #googlecloudsdk.command_lib.bigtabler	   ListCommandr   r%   r   r   <module>r+      s4    5 &  '  5 0 ( 904## 0r   