$95 GRAYBYTE WORDPRESS FILE MANAGER $26

SERVER : premium201.web-hosting.com #1 SMP Wed Mar 26 12:08:09 UTC 2025
SERVER IP : 172.67.162.162 | ADMIN IP 216.73.216.174
OPTIONS : CRL = ON | WGT = ON | SDO = OFF | PKEX = OFF
DEACTIVATED : NONE

/lib64/python3.8/importlib/__pycache__/

HOME
Current File : /lib64/python3.8/importlib/__pycache__//resources.cpython-38.pyc
U

e5d@%�	@s�ddlZddlZddlmZddlmZmZddlm	Z	ddl
mZddlm
Z
mZddlmZdd	lmZdd
lmZmZmZmZmZddlmZddlmZmZdd
lmZdddddddddg	Zee efZ!ee ej"fZ#ed�dd�Z$e d�dd�Z%eeej&d�dd�Z'dd �Z(e!e#ed!�d"d�Z)d-e!e#e e ed%�d&d�Z*e!e#e+d!�d'd�Z,d.e!e#e e e d%�d(d�Z-ee!e#eed!�d)d��Z.e!e e/d*�d+d�Z0e!ee d�d,d�Z1dS)/�N�)�abc)�contextmanager�suppress)�
import_module)�ResourceLoader)�BytesIO�
TextIOWrapper)�Path)�
ModuleType)�Iterable�Iterator�Optional�Set�Union)�cast)�BinaryIO�TextIO)�ZipImportError�Package�Resource�contents�is_resource�open_binary�	open_text�path�read_binary�	read_text)�returncCs\t|d�r0|jjdkr*td�|jj���qX|Sn(t|�}|jjdkrTtd�|���n|SdS)z�Take a package name or module object and return the module.

    If a name, the module is imported.  If the passed or imported module
    object is not a package, raise an exception.
    �__spec__Nz{!r} is not a package)�hasattrr�submodule_search_locations�	TypeError�format�namer)�package�module�r'�+/usr/lib64/python3.8/importlib/resources.py�_get_package"s
�r)cCs,tj�|�\}}|r$td�|���n|SdS)z�Normalize a path by ensuring it is a string.

    If the resulting string contains path separators, an exception is raised.
    z{!r} must be only a file nameN)�osr�split�
ValueErrorr#)r�parent�	file_namer'r'r(�_normalize_path6sr/)r%rcCs,|j}t|jd�r(ttj|j�|j��SdS)N�get_resource_reader)rr �loaderr�
resources_abc�ResourceReaderr0r$)r%�specr'r'r(�_get_resource_readerBs�r5cCs&|jjdks|jjs"td|����dS)NzPackage has no location )r�origin�has_location�FileNotFoundError)r%r'r'r(�_check_locationPsr9)r%�resourcerc
Cs�t|�}t|�}t|�}|dk	r*|�|�St|�tj�|jj	�}tj�
|�}tj�||�}zt|dd�WSt
k
r�tt|jj�}d}t|jjd�r�tt
��|�|�}W5QRX|dkr�|jj}d�||�}	t|	��nt|�YSYnXdS)zDReturn a file-like object opened for binary reading of the resource.N�rb)�mode�get_data�{!r} resource not found in {!r})r/r)r5�
open_resourcer9r*r�abspathrr6�dirname�join�open�OSErrorrrr1r rr=r$r#r8r)
r%r:�reader�absolute_package_path�package_path�	full_pathr1�data�package_name�messager'r'r(rUs2

�
�utf-8�strict)r%r:�encoding�errorsrcCs
t|�}t|�}t|�}|dk	r2t|�|�||�St|�tj�|j	j
�}tj�|�}tj�||�}zt
|d||d�WStk
�rtt|j	j�}d}	t|j	jd�r�tt��|�|�}	W5QRX|	dkr�|j	j}
d�||
�}t|��ntt|	�||�YSYnXdS)zBReturn a file-like object opened for text reading of the resource.N�r)r<rNrOr=r>)r/r)r5r	r?r9r*rr@rr6rArBrCrDrrr1r rr=r$r#r8r)r%r:rNrOrErFrGrHr1rIrJrKr'r'r(rts2
�
c
Cs:t|�}t|�}t||��}|��W5QR�SQRXdS)z+Return the binary contents of the resource.N)r/r)r�read)r%r:�fpr'r'r(r�sc
Cs>t|�}t|�}t||||��}|��W5QR�SQRXdS)z�Return the decoded string of the resource.

    The decoding-related arguments have the same semantics as those of
    bytes.decode().
    N)r/r)rrQ)r%r:rNrOrRr'r'r(r�s	c	cst|�}t|�}t|�}|dk	rNzt|�|��VWdStk
rJYqVXnt|�d}|jjdk	r|t|jj�j	}||}|dk	r�|�
�r�|Vnxt||��}|��}W5QRXt
��\}}z$t�||�t�|�t|�VW5zt�|�Wntk
�rYnXXdS)akA context manager providing a file path object to the resource.

    If the resource does not already exist on its own on the file system,
    a temporary file will be created. If the file was created, the file
    will be deleted upon exiting the context manager (no exception is
    raised if the file was deleted prior to the context manager
    exiting).
    N)r/r)r5r
�
resource_pathr8r9rr6r-�existsrrQ�tempfileZmkstempr*�remove�write�close)	r%r:rEZ	file_path�package_directoryrRrI�fdZraw_pathr'r'r(r�s6

)r%r$rc	Cs|t|�}t|�t|�}|dk	r*|�|�Sztt|��}Wnttfk
rTYdSX||krbdSt|j	j
�j|}|��S)zYTrue if 'name' is a resource inside 'package'.

    Directories are *not* resources.
    NF)
r)r/r5r�setr�NotADirectoryErrorr8r
rr6r-�is_file)r%r$rEZpackage_contentsrr'r'r(r�s
cCsTt|�}t|�}|dk	r |��S|jjdks4|jjs8dSt|jj�j}t�	|�SdS)z�Return an iterable of entries in 'package'.

    Note that not all entries are resources.  Specifically, directories are
    not considered resources.  Use `is_resource()` on each entry returned here
    to check if it is a resource or not.
    Nr')
r)r5rrr6r7r
r-r*�listdir)r%rErYr'r'r(r�s)rLrM)rLrM)2r*rU�rr2�
contextlibrr�	importlibr�
importlib.abcr�iorr	�pathlibr
�typesr�typingrr
rrrrZ	typing.iorrZ	zipimportr�__all__�strr�PathLikerr)r/r3r5r9rr�bytesrrr�boolrrr'r'r'r(�<module>sh�

�!��"
��.


Current_dir [ NOT WRITEABLE ] Document_root [ WRITEABLE ]


[ Back ]
NAME
SIZE
LAST TOUCH
USER
CAN-I?
FUNCTIONS
..
--
21 Mar 2024 10.19 AM
root / root
0755
__init__.cpython-38.opt-1.pyc
3.672 KB
17 Oct 2023 6.13 PM
root / root
0644
__init__.cpython-38.opt-2.pyc
3.009 KB
17 Oct 2023 6.13 PM
root / root
0644
__init__.cpython-38.pyc
3.672 KB
17 Oct 2023 6.13 PM
root / root
0644
_bootstrap.cpython-38.opt-1.pyc
27.905 KB
17 Oct 2023 6.13 PM
root / root
0644
_bootstrap.cpython-38.opt-2.pyc
21.305 KB
17 Oct 2023 6.13 PM
root / root
0644
_bootstrap.cpython-38.pyc
27.937 KB
17 Oct 2023 6.13 PM
root / root
0644
_bootstrap_external.cpython-38.opt-1.pyc
44.629 KB
17 Oct 2023 6.13 PM
root / root
0644
_bootstrap_external.cpython-38.opt-2.pyc
33.702 KB
17 Oct 2023 6.13 PM
root / root
0644
_bootstrap_external.cpython-38.pyc
45.065 KB
17 Oct 2023 6.13 PM
root / root
0644
abc.cpython-38.opt-1.pyc
13.257 KB
17 Oct 2023 6.13 PM
root / root
0644
abc.cpython-38.opt-2.pyc
6.605 KB
17 Oct 2023 6.13 PM
root / root
0644
abc.cpython-38.pyc
13.257 KB
17 Oct 2023 6.13 PM
root / root
0644
machinery.cpython-38.opt-1.pyc
0.941 KB
17 Oct 2023 6.13 PM
root / root
0644
machinery.cpython-38.opt-2.pyc
0.805 KB
17 Oct 2023 6.13 PM
root / root
0644
machinery.cpython-38.pyc
0.941 KB
17 Oct 2023 6.13 PM
root / root
0644
metadata.cpython-38.opt-1.pyc
20.391 KB
17 Oct 2023 6.13 PM
root / root
0644
metadata.cpython-38.opt-2.pyc
14.759 KB
17 Oct 2023 6.13 PM
root / root
0644
metadata.cpython-38.pyc
20.391 KB
17 Oct 2023 6.13 PM
root / root
0644
resources.cpython-38.opt-1.pyc
6.359 KB
17 Oct 2023 6.13 PM
root / root
0644
resources.cpython-38.opt-2.pyc
5.046 KB
17 Oct 2023 6.13 PM
root / root
0644
resources.cpython-38.pyc
6.359 KB
17 Oct 2023 6.13 PM
root / root
0644
util.cpython-38.opt-1.pyc
9.076 KB
17 Oct 2023 6.13 PM
root / root
0644
util.cpython-38.opt-2.pyc
6.274 KB
17 Oct 2023 6.13 PM
root / root
0644
util.cpython-38.pyc
9.076 KB
17 Oct 2023 6.13 PM
root / root
0644

GRAYBYTE WORDPRESS FILE MANAGER @ 2025 CONTACT ME
Static GIF