
                             S r SSKJr  SSKJr  SSKJr  SSKJr  \R                   " S S\R                  5      5       rg)	zQImplementation of update command for updating storage intelligence configuration.    )storage_intelligence_api)base)flags)logc                   8    \ rS rSrSrSSS.r\S 5       rS rSr	g	)
Update   z+Updates storage intelligence configuration.a  
          Update storage intelligence configuration for the organization, sub-folder
          or project. The command sets `STANDARD` edition by default if no other
          edition flags like ``--trial-edition`` or ``--inherit-from-parent``
          are specified.
      a  
          To limit buckets in the storage intelligence configuration, Use the following
          command with ``--include-bucket-id-regexes'' flag.
          to specify list of bucket ids and bucket id regexes.,

            $ {command} --organization=my-org --include-bucket-id-regexes=my-bucket-.*

          To apply location based filters in the storage intelligence configuration, Use
          ``--include-locations'' or ``--exclude-locations'' flags to specify allowed
          list of locations or excluded list of locations. The following
          command updates storage intelligence configuration of sub-folder `123456` with the
          specified list of excluded locations.,

            $ {command} --sub-folder=123456 --exclude-locations=us-east1,us-west1

          The following command updates storage intelligence for the given project by
          inheriting existing storage intelligence configuration from the hierarchical parent
          resource.,

            $ {command} --project=my-project --inherit-from-parent

          To clear included locations from the project storage intelligence, Use the
          following command.,

            $ {command} --project=my-project --include-locations=

      )DESCRIPTIONEXAMPLESc                     UR                  S5        [        R                  " U5        UR                  SSSS9nUR	                  SSSS9  UR                  S	S
9n[        R
                  " U5        g )NFUPDATET)categorymutexrequiredz--inherit-from-parent
store_truezBSpecifies storage intelligence config to be inherited from parent.)actionhelpSETTINGS)r   )SetSortArgsr   ,add_storage_intelligence_configs_level_flags	add_groupadd_argument/add_storage_intelligence_configs_settings_flags)clsparserupdate_groupsettingss       2lib/surface/storage/intelligence_configs/update.pyArgsUpdate.Args=   s{    
u	66v>## $ L P	   %%z%:H	99(C    c           
      
   [         R                  " 5       nUR                  (       a\  UR                  UR                  UR                  UR
                  UR                  UR                  UR                  UR                  S9nOUR                  (       a\  UR                  UR                  UR                  UR
                  UR                  UR                  UR                  UR                  S9nO[UR                  UR                  UR                  UR
                  UR                  UR                  UR                  UR                  S9n[        R                  R!                  SR#                  UR$                  5      5        U$ )N)inherit_from_parenttrial_editioninclude_locationsexclude_locationsinclude_bucket_id_regexesexclude_bucket_id_regexesz7Successfully updated storage intelligence plan for {}.
)r   StorageIntelligenceApiproject"update_project_intelligence_configr#   r$   r%   r&   r'   r(   
sub_folder%update_sub_folder_intelligence_config'update_organization_intelligence_configorganizationr   statusPrintformatname)selfargsclientintelligence_configs       r   Run
Update.RunN   sT   %<<>F||

3
3ll"&":": .. $ 6 6 $ 6 6(,(F(F(,(F(F 4   
"HH
//"66** 22 22$($B$B$($B$B I  #JJ


"66** 22 22$($B$B$($B$B K  JJBII$$	

 r!    N)
__name__
__module____qualname____firstlineno____doc__detailed_helpclassmethodr   r8   __static_attributes__r:   r!   r   r   r      s2    3

-@ D D )r!   r   N)r?   googlecloudsdk.api_lib.storager   googlecloudsdk.callioper   "googlecloudsdk.command_lib.storager   googlecloudsdk.corer   DefaultUniverseOnlyCommandr   r:   r!   r   <module>rI      s?    X C ( 4 #
 ]T\\ ] ]r!   