관리-도구
편집 파일: readers.cpython-312.opt-2.pyc
� �Q�f� � �� � d dl Z d dlZd dlZd dlZd dlZddlmZ ddlmZ d� Z G d� dej � Z G d� d ej � Z G d � dej � Z G d� d ej � Zy)� N� )�abc)�onlyc �R � t t j j | � � S �N)�iter�collections�OrderedDict�fromkeys)�itemss �B/opt/alt/python312/lib64/python3.12/importlib/resources/readers.py�remove_duplicatesr s � ���'�'�0�0��7�8�8� c � � e Zd Zd� Zd� Zd� Zy)� FileReaderc �` � t j |j � j | _ y r )�pathlib�Path�path�parent)�self�loaders r �__init__zFileReader.__init__ s � ��L�L����-�4�4�� r c �L � t | j j |� � S r ��strr �joinpath�r �resources r � resource_pathzFileReader.resource_path �# � � � �4�9�9�%�%�h�/�0�0r c � � | j S r �r �r s r �fileszFileReader.files � � ��y�y�r N��__name__� __module__�__qualname__r r r% � r r r r s � �5�1�r r c �0 � � e Zd Zd� Z� fd�Zd� Zd� Z� xZS )� ZipReaderc � � |j d� \ }}}|j j dd� |z dz | _ |j | _ y )N�.�\�/)� rpartition�prefix�replace�archive)r r �module�_�names r r zZipReader.__init__! sE � ��&�&�s�+� ��1�d��m�m�+�+�D�#�6��=��C����~�~��r c �v �� t �| � |� S # t $ r}t |j d � �d }~ww xY w�Nr )�super� open_resource�KeyError�FileNotFoundError�args)r r �exc� __class__s �r r<