/opt/alt/python311/lib64/python3.11/importlib/metadata/__pycache__
Edit: /opt/alt/python311/lib64/python3.11/importlib/metadata/__pycache__/_text.cpython-311.opt-1.pyc (4353B)
§
ßêà¤>Eúã ó6 — d dl Z ddlmZ G d„ de¦ « ZdS )é Né )Úmethod_cachec ón ‡ — e Zd ZdZd„ Zd„ Zd„ Zd„ Zd„ Zˆ fd„Z d„ Z
eˆ fd „¦ « Zd
„ Z
dd
„Zˆ xZS )Ú
FoldedCasea{
A case insensitive string class; behaves just like str
except compares equal when the only variation is case.
>>> s = FoldedCase('hello world')
>>> s == 'Hello World'
True
>>> 'Hello World' == s
True
>>> s != 'Hello World'
False
>>> s.index('O')
4
>>> s.split('O')
['hell', ' w', 'rld']
>>> sorted(map(FoldedCase, ['GAMMA', 'alpha', 'Beta']))
['alpha', 'Beta', 'GAMMA']
Sequence membership is straightforward.
>>> "Hello World" in [s]
True
>>> s in ["Hello World"]
True
You may test for set inclusion, but candidate and elements
must both be folded.
>>> FoldedCase("Hello World") in {s}
True
>>> s in {FoldedCase("Hello World")}
True
String inclusion works as long as the FoldedCase object
is on the right.
>>> "hello" in FoldedCase("Hello World")
True
But not if the FoldedCase object is on the left:
>>> FoldedCase('hello') in 'Hello World'
False
In that case, use in_:
>>> FoldedCase('hello').in_('Hello World')
True
>>> FoldedCase('hello') > FoldedCase('Hello')
False
c óV — | ¦ « | ¦ « k S ©N©Úlower©ÚselfÚothers ú?/opt/alt/python311/lib64/python3.11/importlib/metadata/_text.pyÚ__lt__zFoldedCase.__lt__C ó € Ø�zŠz‰|Œ|˜eŸkšk™mœmÒ+Ð+ó c óV — | ¦ « | ¦ « k S r r r s r Ú__gt__zFoldedCase.__gt__F r r c óV — | ¦ « | ¦ « k S r r r s r Ú__eq__zFoldedCase.__eq__I ó € Ø�zŠz‰|Œ|˜uŸ{š{™}œ}Ò,Ð,r c óV — | ¦ « | ¦ « k S r r r s r Ú__ne__zFoldedCase.__ne__L r r c óD — t | ¦ « ¦ « S r )Úhashr
)r s r Ú__hash__zFoldedCase.__hash__O s € Ý�D—J’J‘L”LÑ!Ô!Ð!r c óŽ •— t ¦ « ¦ « | ¦ « ¦ « S r )Úsuperr
Ú__contains__)r r
Ú __class__s €r r zFoldedCase.__contains__R s+ ø€ ݉wŒw�}Š}‰Œ×+Ò+¨E¯KªK©M¬MÑ:Ô:Ð:r c ó$ — | t |¦ « v S )zDoes self appear in other?)r r s r Úin_zFoldedCase.in_U s € à•z %Ñ(Ô(Ð(Ð(r c óD •— t ¦ « ¦ « S r )r r
)r r s €r r
zFoldedCase.lowerZ s ø€ å‰wŒw�}Š}‰ŒÐr c ót — | ¦ « | ¦ « ¦ « S r )r
Úindex)r Úsubs r r$ zFoldedCase.index^ s&