| Server IP : 46.245.81.90 / Your IP : 216.73.216.133 Web Server : Apache System : Linux server3ir.xdlhost.com 4.18.0-553.30.1.lve.el8.x86_64 #1 SMP Tue Dec 3 01:21:19 UTC 2024 x86_64 User : gmparts ( 1037) PHP Version : 8.1.34 Disable Function : exec,passthru,shell_exec,system MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /usr/lib64/python3.6/site-packages/zope/interface/__pycache__/ |
Upload File : |
3
��[! � @ s| d Z ddlmZmZ ddlmZ ddlmZmZ ddlm Z m
Z
mZ ddlZefZ
ddd�Zdd d
�Zddd�Zd
d� ZdS )z!Verify interface implementations
� )�BrokenImplementation�DoesNotImplement)�BrokenMethodImplementation)�FunctionType�
MethodType)�
fromMethod�fromFunction�MethodNc
C sh |dkr| j }n| j}| r.||� r.t| ���x2| jd�D �]"\}}yt||�}W n4 tk
r� t|t� rz|dkrzw<t| |��Y nX t|t�s�q<t|t �r�t
jd dkr�t|t�r�|dkr�t
|| |dd�}nt
|| |d�}nVt|t�o�t|j�t k�r
t|| |�}n.t|t��r$|dk�r$q<nt|�s<t|d��q<|j� }|j� }t||�} | r<t|| ��q<W dS ) a� Verify that 'candidate' might correctly implements 'iface'.
This involves:
o Making sure the candidate defines all the necessary methods
o Making sure the methods have the correct signature
o Making sure the candidate asserts that it implements the interface
Note that this isn't the same as verifying that the class does
implement the interface.
If optional tentative is true, suppress the "is implemented by" test.
�c� r � )�nameZimlevel)r
zNot a methodT)Z
implementedByZ
providedByr ZnamesAndDescriptions�getattr�AttributeError�
isinstancer r r �sys�version_info�typer �MethodTypes�__func__r �property�callabler ZgetSignatureInfo� _incompat)
�iface� candidate� tentative�vtypeZtesterr
Zdesc�attr�methZmess� r �/usr/lib64/python3.6/verify.py�_verify sB
r! c C s t | ||dd�S )Nr
)r )r! )r r r r r r �verifyClassh s r"