
    d
                     8   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  \	R                  " \	R                  R                   \	R                  R"                  \	R                  R$                  5       " S
 S\	R&                  5      5       rg)zCommand to create a new folder.    )absolute_import)division)unicode_literals)folders)
operations)base)flags)logc                   .    \ rS rSrSr\S 5       rS rSrg)Create   a  Create a new folder.

Creates a new folder in the given parent folder or organization.

## EXAMPLES

The following command creates a folder with the name `abc` into a
folder with the ID `2345`:

  $ {command} --display-name=abc --folder=2345

The following command creates a folder with the name `abc` into an
organization with ID `1234`:

  $ {command} --display-name=abc --organization=1234
c                 
   [         R                  " U 5        [         R                  " 5       R                  U 5        [        R
                  " SSSS9R                  U 5        [         R                  " 5       R                  U 5        g )Nz--display-nameTz0Friendly display name to use for the new folder.)requiredhelp)r	   AddParentFlagsToParserOperationAsyncFlagAddToParserr   ArgumentTagsFlag)parsers    .lib/surface/resource_manager/folders/create.pyArgsCreate.Args0   s]    	  (	**62MM? k&	NN  (    c           
      ,   [         R                  " U5        [        R                  " 5       n[         R                  " XR
                  R                  5      n[        R                  " 5       R                  UR                  [         R                  " U5      UR                  UR                  US9S95      nUR                  (       a  U$ [        R                  " U5      n[        R                  " UUR
                  5      n[         R"                  " U5        U$ )N)displayNametags)parentfolder)r	   CheckParentFlagsr   FoldersMessagesGetTagsFromFlagsFolder	TagsValueFoldersServicer   (CloudresourcemanagerFoldersCreateRequestGetParentFromFlagsdisplay_nameasync_r   WaitForOperationExtractOperationResponser
   CreatedResource)selfargsmessagesr   	operationfinished_operationresults          r   Run
Create.Run;   s    	4 &&(H!!$(A(ABD&&(//99++D1??t/@/@t?L 	: 	
I {{%66yA223E3;??Df	&!mr    N)	__name__
__module____qualname____firstlineno____doc__staticmethodr   r3   __static_attributes__r5   r   r   r   r      s     " ) )r   r   N)r:   
__future__r   r   r   'googlecloudsdk.api_lib.resource_managerr   r   googlecloudsdk.callioper   +googlecloudsdk.command_lib.resource_managerr	   googlecloudsdk.corer
   ReleaseTracksReleaseTrackALPHABETAGACreateCommandr   r5   r   r   <module>rH      sy    & &  ' ; > ( = # D%%++T->->-C-C%%((*.T .*.r   