
                             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 r	S r
S	 rS
 rS rSS jrS rS rS rS rS rS rS rg)z?Shared resource flags for `gcloud container attached` commands.    )concepts)deps)concept_parsers)
properties)	resourcesc                  ,    [         R                  " SSS9$ )Nclusterzcluster of the {resource}.name	help_textr    ResourceParameterAttributeConfig     Blib/googlecloudsdk/command_lib/container/attached/resource_args.pyAttachedClusterAttributeConfigr      s    		2	2 <
 r   c                      [         R                  " SS[        R                  " [        R
                  R                  R                  5      /S9$ )z.Gets Google Cloud location resource attribute.locationz)Google Cloud location for the {resource}.)r   r   fallthroughs)r   r   r   PropertyFallthroughr   VALUEScontainer_attachedr   r   r   r   LocationAttributeConfigr      sC    		2	2;

"
"22;;
 r   c                  n    [         R                  " SS[        5       [        5       [         R                  S9$ )N1gkemulticloud.projects.locations.attachedClustersr	   )resource_nameattachedClustersIdlocationsId
projectsId)r   ResourceSpecr   r    DEFAULT_PROJECT_ATTRIBUTE_CONFIGr   r   r   GetAttachedClusterResourceSpecr"   ,   s0    			979)+::
 r   c                  \    [         R                  " SS[        5       [         R                  S9$ )Nz gkemulticloud.projects.locationsr   r   r   r   r   r    r   r!   r   r   r   GetLocationResourceSpecr&   6   s*    			()+::	
 r   c                  \    [         R                  " SS[        5       [         R                  S9$ )N+gkemulticloud.projects.locations.operations	operationr$   r%   r   r   r   GetOperationResourceSpecr*   ?   s*    			3)+::	
 r   c                     U(       a  SOSn[         R                  R                  U[        5       SR	                  U5      SS9R                  U 5        g)zAdds a resource argument for an Attached cluster.

Args:
  parser: The argparse parser to add the resource arg to.
  verb: str, the verb to describe the resource, such as 'to update'.
  positional: bool, whether the argument is positional or not.
r	   z	--clusterzcluster {}.TrequiredN)r   ConceptParserForResourcer"   formatAddToParser)parserverb
positionalr   s       r   AddAttachedClusterResourceArgr5   H   sL     !k$++
$&4 	 , 
 Kr   c                     [         R                  R                  S[        5       SR	                  U5      SS9R                  U 5        g)zAdds a resource argument for Google Cloud location.

Args:
  parser: The argparse parser to add the resource arg to.
  verb: str, the verb to describe the resource, such as 'to update'.
z
--locationzGoogle Cloud location {}.Tr,   N)r   r.   r/   r&   r0   r1   r2   r3   s     r   AddLocationResourceArgr8   Y   sC     ++!((.	 , 
 Kr   c                     [         R                  R                  U R                  R                  R                  5       R                  5       SS9$ )Nr   
collection)r   REGISTRYParseRelativeNameCONCEPTSr	   ParseRelativeNameargss    r   ParseAttachedClusterResourceArgrC   h   sB    				-	-
mm!!#002D 
. 
 r   c                  ,    [         R                  " SSS9$ )Nfleet_membershipzxattached cluster membership of the {resource}, in the form of projects/PROJECT/locations/global/memberships/MEMBERSHIP. r
   r   r   r   r   FleetMembershipAttributeConfigrF   o   s    		2	2H
 r   c                  n    [         R                  " SS[        5       [        5       [         R                  S9$ )Nz%gkehub.projects.locations.membershipsrE   )r   r   membershipsIdr   )r   r    r   rF   r!   r   r   r   GetFleetMembershipResourceSpecrI   y   s0    			-&)+24::
 r   c                     [         R                  R                  S[        5       SSSS0S9R	                  U 5        U R                  SS9  g	)
zpAdds a resource argument for Fleet Membership.

Args:
  parser: The argparse parser to add the resource arg to.
z--fleet-membershipzdMembership of the registered cluster. Membership can be the membership ID or the full resource name.Tr   z--fleet-membership-location)r-   flag_name_overridesglobal)fleet_membership_locationN)r   r.   r/   rI   r1   set_defaults)r2   s    r   AddFleetMembershipResourceArgrO      sV     ++$&'
3 , 	 K9r   c                     [         R                  R                  S[        5       SR	                  U5      SS9R                  U 5        g)zAdds a resource argument for operation on Attached clusters.

Args:
  parser: The argparse parser to add the resource arg to.
  verb: str, the verb to describe the resource, such as 'to update'.
operation_idzoperation {}.Tr,   N)r   r.   r/   r*   r0   r1   r7   s     r   AddOperationResourceArgrR      sC     ++ T"	 , 
 Kr   c                     [         R                  R                  U R                  R                  R                  5       R                  5       SS9$ )Nr(   r:   )r   r<   r=   r>   rQ   r?   r@   rA   s    r   ParseOperationResourceArgrT      sB    				-	-
mm  &&(557> 
. 
 r   N)T)__doc__ googlecloudsdk.calliope.conceptsr   r   (googlecloudsdk.command_lib.util.conceptsr   googlecloudsdk.corer   r   r   r   r"   r&   r*   r5   r8   rC   rF   rI   rO   rR   rT   r   r   r   <module>rY      s]    F 6 1 D * )
":(r   