ó
    €Ïn
  ã                   ó®   • S r SSKrSSKJr  SSKJr  SSKJr  \R                  " S5      r	S r
S\
0r\R                   " S	 S
\R                  5      5       rg)z;Implementation of list command for Insights dataset config.é    N)Úinsights_api)Úbase)Úflagszlocations/(.*)/.*/c                 ó”   • [         R                  " [        U S   5      nU(       a#  UR                  S5      b  UR                  S5      $ g)NÚnameé   zN/A-Misformated Value)ÚreÚsearchÚLOCATION_REGEX_PATTERNÚgroup)Údataset_configÚmatched_results     Ú4lib/surface/storage/insights/dataset_configs/list.pyÚ_transform_locationr      s?   € Ü—9’9Ô3°^ÀFÑ5KÓL€.Þ˜×,Ñ,¨QÓ/Ñ;Ø×Ñ Ó"Ð"à"ó    Úlocation_transformc                   ó8   • \ rS rSrSrSSS.r\S 5       rS rSr	g	)
ÚListé&   zAList returns all the Insights dataset configs for given location.z:
      List Cloud storage Insights dataset configs.
      a£  

      List all dataset configs in all locations:

          $ {command}

      List all dataset configs for location "us-central1":

          $ {command} --location=us-central1

      List all dataset configs with a page size of "20":

          $ {command} --location=us-central1 --page-size=20

      List all dataset configs with JSON formatting:

          $ {command} --location=us-central1 --format=json
      )ÚDESCRIPTIONÚEXAMPLESc                 ó¢   • [         R                  " U SS9  U R                  R                  S5        U R                  R	                  [
        5        g )NF)Úis_requireda–  
        table(
            uid:label=DATASET_CONFIG_ID,
            name.basename():label=DATASET_CONFIG_NAME,
            location_transform():label=LOCATION,
            sourceProjects.projectNumbers:label=SOURCE_PROJECTS,
            organizationNumber:label=ORGANIZATION_NUMBER,
            retentionPeriodDays:label=RETENTION_PERIOD_DAYS,
            datasetConfigState:label=STATE
        )
        )r   Ú add_dataset_config_location_flagÚdisplay_infoÚ	AddFormatÚAddTransformsÚ_TRANSFORMS)Úparsers    r   ÚArgsÚ	List.ArgsB   sA   € ä	×*Ò*¨6¸uÒEØ
×Ñ×!Ñ!ð 
#ô 
ð ×Ñ×%Ñ%¤kÕ2r   c                 óp   • [         R                  " 5       R                  UR                  UR                  S9$ )N)ÚlocationÚ	page_size)r   ÚInsightsApiÚlist_dataset_configr#   r$   )ÚselfÚargss     r   ÚRunÚList.RunR   s0   € Ü×#Ò#Ó%×9Ñ9Ø—‘¨$¯.©.ð :ð ð r   © N)
Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__Ú__doc__Údetailed_helpÚstaticmethodr    r)   Ú__static_attributes__r+   r   r   r   r   &   s/   † áIð
ð
ñ	€-ð0 ñ3ó ð3õr   r   )r0   r	   Úgooglecloudsdk.api_lib.storager   Úgooglecloudsdk.callioper   Ú"googlecloudsdk.command_lib.storager   Úcompiler   r   r   ÚDefaultUniverseOnlyÚListCommandr   r+   r   r   Ú<module>r:      s`   ðñ  Bã 	å 7Ý (Ý 4àŸšÐ$9Ó:Ð ò#ð $Ð%8Ð9€ð ×Ñô.ˆ4×Ñó .ó ñ.r   