2biD* 2 S SK Jr S SKrS SKrS SKrS SKrS SKrS SKrS SKrS SK r SSK
Jr SSKJ
r
JrJr \R " \5 rSq " S S\5 r " S S \5 r " S
S\5 r " S S
\5 r " S S\5 r " S S\5 r\" S5 \\ R8 \0r S SKr\\\RD ' \\\RF ' \\\RH ' CS r&0 r'S r(\RR " \*" S5 5 r+S r,g! \ a S SK!r N^f = f! \ \%4 a N>f = f) )unicode_literalsN )DistlibException)cached_propertyget_cache_baseCachec 8 ^ \ rS rSrSU 4S jjrS rS rSrU =r$ )
ResourceCache c > Uc1 [ R R [ 5 [ S5 5 n[
[ U ] U5 g )Nzresource-cache)ospathjoinr strsuperr
__init__)selfbase __class__s ڏ/builddir/build/BUILDROOT/alt-python313-pip-23.3.1-3.el8.x86_64/opt/alt/python313/lib/python3.13/site-packages/pip/_vendor/distlib/resources.pyr ResourceCache.__init__ s4 <77<< 0#6F2GHD
mT+D1 c g)z
Is the cache stale for the given resource?
:param resource: The :class:`Resource` being cached.
:param path: The path of the resource in the cache.
:return: True if the cache is stale.
T r resourcer s r is_staleResourceCache.is_stale" s r c z UR R U5 u p#Uc UnU$ [ R R U R
U R
U5 U5 n[ R R U5 n[ R R U5 ( d [ R " U5 [ R R U5 ( d SnOU R X5 nU( a2 [ US5 nUR UR 5 SSS5 U$ U$ ! , ( d f U$ = f)z
Get a resource into the cache,
:param resource: A :class:`Resource` instance.
:return: The pathname of the resource in the cache.
NTwb)finderget_cache_infor
r r r
prefix_to_dirdirnameisdirmakedirsexistsr openwritebytes)r r prefixr resultr$ stalefs r getResourceCache.get- s 55h?>F
WW\\$))T-?-?-GNFggoof-G77==))G$77>>&))
h5&$'1GGHNN+ (
v
('
s D++
D:r N) __name__
__module____qualname____firstlineno__r r r/ __static_attributes__
__classcell__r s @r r
r
s 2 r r
c \ rS rSrS rSrg)ResourceBaseG c Xl X l g r1 r! name)r r! r> s r r ResourceBase.__init__H s r r= N)r2 r3 r4 r5 r r6 r r r r: r: G s r r: c R \ rS rSrSrSrS r\S 5 r\S 5 r \S 5 r
Srg )
ResourceM z
A class representing an in-package resource, such as a data file. This is
not normally instantiated by user code, but rather by a
:class:`ResourceFinder` which manages the resource.
Fc 8 U R R U 5 $ )zr
Get the resource as a stream.
This is not a property to make it obvious that it returns a new stream
each time.
)r!
get_streamr s r as_streamResource.as_streamU s {{%%d++r c N [ c
[ 5 q [ R U 5 $ r1 )cacher
r/ rE s r file_pathResource.file_path^ s =!OEyyr c 8 U R R U 5 $ r1 )r! get_bytesrE s r r* Resource.bytese s {{$$T**r c 8 U R R U 5 $ r1 )r! get_sizerE s r size
Resource.sizei s {{##D))r r N)r2 r3 r4 r5 __doc__is_containerrF r rJ r* rQ r6 r r r rA rA M sO
L, + + * *r rA c ( \ rS rSrSr\S 5 rSrg)ResourceContainern Tc 8 U R R U 5 $ r1 )r!
get_resourcesrE s r resourcesResourceContainer.resourcesq s {{((..r r N)r2 r3 r4 r5 rT r rZ r6 r r r rV rV n s L/ /r rV c \ rS rSrSr\R R S5 ( a SrOSrS r S r
S rS rS
r
S rS rS
rS rS rS r\" \R, R. 5 rS rSrg)ResourceFinderv z,
Resource finder for file system resources.
java).pyc.pyoz.class)r` ra c Xl [ USS 5 U l [ R R [ USS5 5 U l g )N
__loader____file__ )modulegetattrloaderr
r r$ r )r rf s r r ResourceFinder.__init__ s4 flD9GGOOGFJ$CD r c @ [ R R U5 $ r1 )r
r realpathr r s r _adjust_pathResourceFinder._adjust_path s ww%%r c [ U[ 5 ( a SnOSnUR U5 nUR SU R 5 [
R R " U6 nU R U5 $ )N //r )
isinstancer* splitinsertr r
r r rm )r
resource_nameseppartsr, s r
_make_pathResourceFinder._make_path s` mU++CC##C(
Q "u% ((r c @ [ R R U5 $ r1 )r
r r' rl s r _findResourceFinder._find s ww~~d##r c S UR 4$ r1 )r r r s r r" ResourceFinder.get_cache_info s X]]""r c U R U5 nU R U5 ( d S nU$ U R U5 ( a [ X5 nO[ X5 nX#l U$ r1 )rx r{
_is_directoryrV rA r )r ru r r, s r findResourceFinder.find s\ }-zz$F
!!$''*4?!$6K
r c . [ UR S5 $ Nrb)r( r r~ s r rD ResourceFinder.get_stream s HMM4((r c [ UR S5 nUR 5 sS S S 5 $ ! , ( d f g = fr )r( r read)r r r. s r rM ResourceFinder.get_bytes s'
(--
&!668 '
&
&s 1
?c T [ R R UR 5 $ r1 )r
r getsizer~ s r rP ResourceFinder.get_size s wwx}}--r c ^ U 4S jn[ [ R " UR 5 Vs/ s H o2" U5 ( d M UPM sn5 $ s snf )Nc \ > U S:g =( a U R TR 5 ( + $ )N__pycache__)endswithskipped_extensions)r. r s r allowed-ResourceFinder.get_resources.