Your IP : 3.138.102.163
o
6��f: � @ s d dl mZ d dlmZmZ d dlmZmZmZm Z m
Z
e� fdd�Ze� fdd�ZdgZ
d Zer6d d
lZd d
lZd d
lZejjsOdejv rOejd �d�Z
[d
Zejd
d� dkrjej�e�rjej�e��d�Z
ddd�Zejd
d� dkrdd� Z[d
S dd� Z[d
S )� )�InputSource)�ContentHandler�ErrorHandler)�SAXException�SAXNotRecognizedException�SAXParseException�SAXNotSupportedException�SAXReaderNotAvailablec C s( t � }|�|� |�|� |�| � d S )N)�make_parser�setContentHandler�setErrorHandler�parse)�source�handler�errorHandler�parser� r �7/opt/alt/python310/lib64/python3.10/xml/sax/__init__.pyr
s
r
c C sp dd l }|d u rt� }t� }|�|� |�|� t� }t| t�r)|�|� | �� n|�
|�| �� |�|� d S )N� )
�ior r
r r r �
isinstance�strZsetCharacterStream�StringIOZ
setByteStream�BytesIOr
)�stringr r r r Zinpsrcr r r �parseString# s
r zxml.sax.expatreaderr NZ
PY_SAX_PARSER�,zpython.xml.sax.parser� �javar c C sb t | �t D ]$}zt|�W S ty# dd l}||jv r!� Y q ty+ Y qw tdd ��)Nr zNo parsers found)�list�default_parser_list�_create_parser�ImportError�sys�modulesr )Zparser_list�parser_namer# r r r r
F s
��
r
c C s$ ddl m} |�| dt� �}|�� S )Nr )�imp)Zorg.python.corer&