Ë
    €ÏÁ  ã                   óJ   — d Z ddlmZ ddlmZ ddlmZ d„ Zd„ Zd„ Zd„ Zd	„ Z	y
)z0Utilities for `gcloud filestore zones` commands.é    )Úabsolute_import)Údivision)Úunicode_literalsc                 ó<   — t        | j                  d«      «      dk(  S )z2Returns True if the location string is a GCP zone.Ú-é   ©ÚlenÚsplit©Úlocations    ú:lib/googlecloudsdk/command_lib/filestore/locations_util.pyÚIsZonalr      ó   € ä	ˆX^‰^˜CÓ Ó	! QÑ	&Ð&ó    c                 ó<   — t        | j                  d«      «      dk(  S )z4Returns True if the location string is a GCP region.r   é   r	   r   s    r   Ú
IsRegionalr      r   r   c                 óH   — dj                  | j                  d«      dd «      S )z1Returns the GCP region that the input zone is in.r   Néÿÿÿÿ)Újoinr   )Úzones    r   ÚGetRegionFromZoner       s    € à	‰$—*‘*˜S“/ # 2Ð&Ó	'Ð'r   c              #   óp   K  — | D ]-  }||dk  r yt        |j                  «      sŒ"|–— |€Œ)|dz  }Œ/ y­w)a  Extract the regions from a list of GCP locations.

  Args:
    locations: a list of location objects.
    limit: int, The maximum number of records to yield. None if all available
      records should be yielded.

  Yields:
    location objects that represent a GCP region.
  Nr   é   )r   Ú
locationId©Ú	locationsÚlimitr   s      r   Ú'ExtractRegionsFromLocationsListResponser    %   sC   è ø€ ó €hØÐ˜U ašZÙÜ(×%Ñ%Õ&Ø‚nØ	Ñ	Ø‰
‰ñ ùó   ‚$6§6®6c              #   óp   K  — | D ]-  }||dk  r yt        |j                  «      sŒ"|–— |€Œ)|dz  }Œ/ y­w)a  Extract the zones from a list of GCP locations.

  Args:
    locations: a list of location objects.
    limit: int, The maximum number of records to yield. None if all available
      records should be yielded.

  Yields:
    location objects that represent a GCP zone.
  Nr   r   )r   r   r   s      r   Ú%ExtractZonesFromLocationsListResponser#   9   sC   è ø€ ó €hØÐ˜U ašZÙÜˆx×"Ñ"Õ#Ø‚nØ	Ñ	Ø‰
‰ñ ùr!   N)
Ú__doc__Ú
__future__r   r   r   r   r   r   r    r#   © r   r   Ú<module>r'      s,   ðñ 7å &Ý Ý 'ò'ò
'ò
(ò
ó(r   