1j. d Z ddlZddlZddlZddlZddlZddlZddlZddlZddl Z ddl mZ ddlm Z ddlmZ dgZd Zd Zej Z d Z G d d Z G d dee j Z G d de ZddZ G d d ZdS )z A Path-like interface for zipfiles. This codebase is shared between zipfile.Path in the stdlib and zipp in PyPI. See https://github.com/python/importlib_metadata/wiki/Development-Methodology for more detail. N )save_method_args) text_encoding) TranslatorPathc H t j t | dd S )a2 Given a path with elements separated by posixpath.sep, generate all parents of that path. >>> list(_parents('b/d')) ['b'] >>> list(_parents('/b/d/')) ['/b'] >>> list(_parents('b/d/f/')) ['b/d', 'b'] >>> list(_parents('b')) [] >>> list(_parents('')) [] r N) itertoolsislice _ancestry)paths r/builddir/build/BUILD/cloudlinux-venv-1.0.11/venv/lib/python3.11/site-packages/setuptools/_vendor/zipp/__init__.py_parentsr s IdOOQ555 c # K | t j } | t j r<| V t j | \ } }| t j :dS dS )a Given a path with elements separated by posixpath.sep, generate all elements of that path. >>> list(_ancestry('b/d')) ['b/d', 'b'] >>> list(_ancestry('/b/d/')) ['/b/d', '/b'] >>> list(_ancestry('b/d/f/')) ['b/d/f', 'b/d', 'b'] >>> list(_ancestry('b')) ['b'] >>> list(_ancestry('')) [] Multiple separators are treated like a single. >>> list(_ancestry('//b//d///f//')) ['//b//d///f', '//b//d', '//b'] N)rstrip posixpathsepsplit)r tails r r r . sy * ;;y}%%D ++im $ $ + _T** d ++im $ $ + + + + +r c P t j t | j | S )zZ Return items in minuend not in subtrahend, retaining order with O(1) lookup. )r filterfalseset__contains__)minuend subtrahends r _differencer M s Z!=wGGGr c B e Zd ZdZe fd Zd Z fdZ xZS )InitializedStatez? Mix-in to save the initialization state for pickling. c : t j |i | d S Nsuper__init__)selfargskwargs __class__s r r# zInitializedState.__init__Z s% $)&)))))r c 2 | j j | j j fS r )_saved___init__r% r&