__ __ __ __ _____ _ _ _____ _ _ _ | \/ | \ \ / / | __ \ (_) | | / ____| | | | | | \ / |_ __\ V / | |__) | __ ___ ____ _| |_ ___ | (___ | |__ ___| | | | |\/| | '__|> < | ___/ '__| \ \ / / _` | __/ _ \ \___ \| '_ \ / _ \ | | | | | | |_ / . \ | | | | | |\ V / (_| | || __/ ____) | | | | __/ | | |_| |_|_(_)_/ \_\ |_| |_| |_| \_/ \__,_|\__\___| |_____/|_| |_|\___V 2.1 if you need WebShell for Seo everyday contact me on Telegram Telegram Address : @jackleetFor_More_Tools:
o
#T_i� � @ s( d dl Z ddlmZ G dd� de�ZdS )� N� )�method_cachec sr e Zd ZdZdd� Zdd� Zdd� Zdd � Zd
d� Z� fdd
�Z dd� Z
e� fdd��Zdd� Z
ddd�Z� ZS )�
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 C s | � � |� � k S �N��lower��self�other� r �//usr/lib/python3.10/importlib/metadata/_text.py�__lt__C � zFoldedCase.__lt__c C s | � � |� � kS r r r r r r �__gt__F r zFoldedCase.__gt__c C s | � � |� � kS r r r r r r �__eq__I r zFoldedCase.__eq__c C s | � � |� � kS r r r r r r �__ne__L r zFoldedCase.__ne__c C s t | �� �S r )�hashr �r r r r �__hash__O s zFoldedCase.__hash__c s t t| ��� �|�� �S r )�superr r �__contains__r �� __class__r r r R s zFoldedCase.__contains__c C s | t |�v S )zDoes self appear in other?)r r r r r �in_U s zFoldedCase.in_c s t t| ��� S r )r r r r r r r r Z s zFoldedCase.lowerc C s | � � �|� � �S r )r �index)r �subr r r r ^ s zFoldedCase.index� r c C s t �t �|�t j�}|�| |�S r )�re�compile�escape�I�split)r �splitter�maxsplit�patternr r r r! a s zFoldedCase.split)r r )�__name__�
__module__�__qualname__�__doc__r
r r r r r r r r r r! �
__classcell__r r r r r s ;r )r �
_functoolsr �strr r r r r �<module> s | Name | Type | Size | Permission | Actions |
|---|---|---|---|---|
| __init__.cpython-310.pyc | File | 36.23 KB | 0644 |
|
| _adapters.cpython-310.pyc | File | 2.29 KB | 0644 |
|
| _collections.cpython-310.pyc | File | 1.48 KB | 0644 |
|
| _functools.cpython-310.pyc | File | 3.04 KB | 0644 |
|
| _itertools.cpython-310.pyc | File | 571 B | 0644 |
|
| _meta.cpython-310.pyc | File | 2.21 KB | 0644 |
|
| _text.cpython-310.pyc | File | 2.99 KB | 0644 |
|