Sindbad~EG File Manager

Current Path : /usr/local/lib/python3.6/site-packages/jsonschema/__pycache__/
Upload File :
Current File : //usr/local/lib/python3.6/site-packages/jsonschema/__pycache__/_legacy_validators.cpython-36.pyc

3

!��c��@shddlmZddlmZddlmZdd�Zdd�Zdd	�Zd
d�Z	dd
�Z
dd�Zdd�Zdd�Z
dS)�)�_utils)�	iteritems)�ValidationErrorc	cs�|j|d�sdSx�t|�D]�\}}||kr,q|j|d�rZxt|j|||d�D]
}|VqJWq|j|d�r�||kr�td||f�Vqx*|D]"}||kr�d}t|||f�Vq�WqWdS)N�object)�schema_path�stringz%r is a dependency of %r)�is_typer�descendr)	�	validatorZdependencies�instance�schema�property�
dependency�errorZeach�message�r�C/tmp/pip-build-_uu8ur7s/jsonschema/jsonschema/_legacy_validators.py�dependencies_draft3s"
rccs<x6tj|�D](}|j|d|gi�rtd||f�VqWdS)N�typez%r is disallowed for %r)r�ensure_listZis_validr)r
ZdisallowrrZ
disallowedrrr�disallow_draft3srccsf|j|d�r,x|j||�D]
}|VqWdSx4t|�D](\}}x|j|||d�D]
}|VqPWq6WdS)Nr)r)rr	�	enumerate)r
Zextendsrrr�index�	subschemarrr�extends_draft3's
rccs�|j|d�sdS|j|d�rTxxt|�D](\}}x|j|||d�D]
}|Vq@Wq&WnBx@tt|�|�D].\\}}}x |j||||d�D]
}|Vq�WqdWdS)N�arrayr)�path)rr)rrr	�zip)r
�itemsrrr�itemrrrrr�items_draft3_draft41sr ccsR|j|d�sdS|jdd�r*||k}d}n||k}d}|rNtd|||f�VdS)N�numberZexclusiveMinimumFzless than or equal toz	less thanz%r is %s the minimum of %r)r�getr)r
Zminimumrr�failed�cmprrr�minimum_draft3_draft4Asr%ccsR|j|d�sdS|jdd�r*||k}d}n||k}d}|rNtd|||f�VdS)Nr!ZexclusiveMaximumFzgreater than or equal tozgreater thanz%r is %s the maximum of %r)rr"r)r
�maximumrrr#r$rrr�maximum_draft3_draft4Rsr'ccs�|j|d�sdSx�t|�D]�\}}||krRxv|j|||||d�D]
}|VqBWq|jdd�rtd|�}|jd|d||d�|jj|�|jj	|dg�|VqWdS)Nr)rr�requiredFz%r is a required property)r
Zvalidator_valuerr)
rrr	r"rZ_setr�
appendleftr�extend)r
Z
propertiesrrr
rrrrr�properties_draft3cs(r+ccs�tj|�}g}xnt|�D]L\}}|j|d�rTt|j|||d��}|sHdS|j|�q|j||�rdSqWttj||�|d�VdS)Nr)r)�context)	rrrr�listr	r*rZ	types_msg)r
�typesrr�
all_errorsrr�errorsrrr�type_draft3}s
r1N)Z
jsonschemarZjsonschema.compatrZjsonschema.exceptionsrrrrr r%r'r+r1rrrr�<module>s


Sindbad File Manager Version 1.0, Coded By Sindbad EG ~ The Terrorists