HEX
Server: Apache
System: Linux scp1.abinfocom.com 5.4.0-216-generic #236-Ubuntu SMP Fri Apr 11 19:53:21 UTC 2025 x86_64
User: confeduphaar (1010)
PHP: 8.1.33
Disabled: exec,passthru,shell_exec,system
Upload Files
File: //lib/python3/dist-packages/hamcrest/library/text/__pycache__/stringmatches.cpython-38.pyc
U

�b�V�@sPdZdZdZddlZddlZddlmZddlmZGdd�de�Z	d	d
�Z
dS)z
Chris RosezCopyright 2011 hamcrest.orgzBSD, see License.txt�N)�BaseMatcher)�	hasmethodc@s$eZdZdd�Zdd�Zdd�ZdS)�StringMatchesPatterncCs
||_dS�N��pattern)�selfr�r	�E/usr/lib/python3/dist-packages/hamcrest/library/text/stringmatches.py�__init__szStringMatchesPattern.__init__cCs|�d��|jj��d�dS)Nza string matching '�')Zappend_textr)rZdescriptionr	r	r
�describe_tos

��z StringMatchesPattern.describe_tocCs|j�|�dk	Sr)r�search)r�itemr	r	r
�_matchesszStringMatchesPattern._matchesN)�__name__�
__module__�__qualname__rr
rr	r	r	r
rsrcCst|tj�rt�|�}t|�S)aKMatches if object is a string containing a match for a given regular
    expression.

    :param pattern: The regular expression to search for.

    This matcher first checks whether the evaluated object is a string. If so,
    it checks if the regular expression ``pattern`` matches anywhere within the
    evaluated object.

    )�
isinstance�sixZstring_types�re�compilerrr	r	r
�matches_regexps
r)�
__author__Z
__copyright__Z__license__rrZhamcrest.core.base_matcherrZhamcrest.core.helpers.hasmethodrrrr	r	r	r
�<module>s