
    Y                     8   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
dZej                   ej                   ej"                  j$                  ej"                  j&                         G d dej(                                      Zee_        y)zQCommand to remove an IAM policy binding from a Colab Enterprise runtime template.    )runtime_templates)util)base)	constants)endpoint_util)flags)iam_utilzT
        Remove an IAM policy binding from a Colab Enterprise runtime template.
    aT  
        To remove an IAM policy binding of `roles/aiplatform.notebookRuntimeUser` for `someone@example.com`, from the runtime template with id `my-runtime-template` in region `us-central1`, run:

        $ {command} my-runtime-template --region=us-central1 --member=user:someone@example.com --role=roles/aiplatform.notebookRuntimeUser
    )DESCRIPTIONEXAMPLESc                   &    e Zd ZdZed        Zd Zy)RemoveIamPolicyBindingzFRemove an IAM policy binding from a Colab Enterprise runtime template.c                 .    t        j                  |        y)z Register flags for this command.N)r   AddRemoveIamPolicyBindingFlags)parsers    @lib/surface/colab/runtime_templates/remove_iam_policy_binding.pyArgszRemoveIamPolicyBinding.Args*   s     
((0    c                 z   | j                         }t        j                  | j                               }|j                  j                  j                         }|j                         d   }t        j                  t        j                  |      5  t        j                  |      }|j                  }|j                  t        j                  ||            }t!        j"                  ||j$                  |j&                         |j)                  t        j*                  |||            cddd       S # 1 sw Y   yxY w)z9This is what gets called when the user runs this command.locationsId)versionregionN)ReleaseTrackr   GetMessagesCONCEPTSruntime_templateParseAsDictr   AiplatformEndpointOverridesr   BETA_VERSION	GetClient+projects_locations_notebookRuntimeTemplatesGetIamPolicyruntime_templates_util(CreateRuntimeTemplateGetIamPolicyRequestr	   RemoveBindingFromIamPolicymemberroleSetIamPolicy(CreateRuntimeTemplateSetIamPolicyRequest)	selfargsrelease_trackmessagesruntime_template_refr   
api_clientruntime_templates_service
iam_policys	            r   RunzRemoveIamPolicyBinding.Run/   s   %%'M 1 1 34H==99??A!((*=9F		2	2&&v
 >>-0j

@
@   -99
 
I
IHj
 ))

++
))
 '33
 
I
I$#
 
 
s   BD11D:N)__name__
__module____qualname____doc__staticmethodr   r2    r   r   r   r   %   s     O1 1r   r   N)r6   'googlecloudsdk.api_lib.colab_enterpriser   r#   r   googlecloudsdk.callioper   googlecloudsdk.command_lib.air   r   +googlecloudsdk.command_lib.colab_enterpriser   googlecloudsdk.command_lib.iamr	   _DETAILED_HELPDefaultUniverseOnlyReleaseTracksr   GABETACommandr   detailed_helpr8   r   r   <module>rE      s    X _ 8 ( 3 7 = 3		 D%%(($*;*;*@*@A$T\\ $ B $L (6  $r   