%PDF- %PDF-
Mini Shell

Mini Shell

Direktori : /usr/lib/python3/dist-packages/chardet/__pycache__/
Upload File :
Create Path :
Current File : //usr/lib/python3/dist-packages/chardet/__pycache__/sjisprober.cpython-312.pyc

�

�d���r�ddlmZddlmZddlmZddlmZmZddl	m
Z
ddlmZddl
mZGd	�d
e�Zy)�)�Union�)�SJISDistributionAnalysis)�CodingStateMachine)�MachineState�ProbingState)�SJISContextAnalysis)�MultiByteCharSetProber)�
SJIS_SM_MODELc�~��eZdZd	�fd�Zd	�fd�Zedefd��Zedefd��Zde	e
efdefd�Z
defd�Z�xZS)
�
SJISProber�returnc���t�|��tt�|_t�|_t�|_|j�y�N)
�super�__init__rr�	coding_smr�distribution_analyzerr	�context_analyzer�reset��self�	__class__s ��4/usr/lib/python3/dist-packages/chardet/sjisprober.pyrzSJISProber.__init__'s9���
����+�M�:���%=�%?��"� 3� 5����
�
��c�V��t�|��|jj�yr)rrrrs �rrzSJISProber.reset.s���
��
�����#�#�%rc�.�|jjSr)r�charset_name�rs rrzSJISProber.charset_name2s���$�$�1�1�1rc��y)N�Japanese�rs r�languagezSJISProber.language6s��r�byte_strc��|j�J�|j�J�t|�D�]�\}}|jj|�}|tj
k(rJ|jjd|j|j|�tj|_�n|tjk(rtj|_n�|tjk(s��|jj!�}|dk(rc||j"d<|j$j'|j"d|z
d|�|jj'|j"|���?|j$j'||dz|z
|dz|z
|�|jj'||dz
|dz|����|d|j"d<|j(tj*k(rL|j$j-�r2|j/�|j0kDrtj|_|j(S)Nz!%s %s prober hit error at byte %srr�����)rr�	enumerate�
next_stater�ERROR�logger�debugrr#r�NOT_ME�_state�ITS_ME�FOUND_IT�START�get_current_charlen�
_last_charr�feed�state�	DETECTING�got_enough_data�get_confidence�SHORTCUT_THRESHOLD)rr$�i�byte�coding_state�char_lens      rr5zSJISProber.feed:s����~�~�)�)�)��)�)�5�5�5� ��*�	W�G�A�t��>�>�4�4�T�:�L��|�1�1�1����!�!�7��%�%��M�M��	�+�1�1�����|�2�2�2�*�3�3�����|�1�1�1��>�>�=�=�?����6�)-�D�O�O�A�&��)�)�.�.�����H���7����.�.�3�3�D�O�O�X�N��)�)�.�.� ��Q���!1�A��E�H�4D�E�x���.�.�3�3�H�Q��U�Q��U�4K�X�V�5	W�8&�b�\�������:�:��/�/�/��$�$�4�4�6��#�#�%��(?�(?�?�*�3�3����z�z�rc��|j�J�|jj�}|jj�}t||�Sr)rrr9�max)r�context_conf�distrib_confs   rr9zSJISProber.get_confidencedsI���)�)�5�5�5��,�,�;�;�=���1�1�@�@�B���<��.�.r)rN)�__name__�
__module__�__qualname__rr�property�strrr#r�bytes�	bytearrayrr5�floatr9�
__classcell__)rs@rr
r
&sm����&��2�c�2��2���#����(�U�5�)�#3�4�(��(�T/��/rr
N)�typingr�chardistributionr�codingstatemachiner�enumsrr�jpcntxr	�mbcharsetproberr
�mbcssmrr
r"rr�<module>rSs+��8�6�2�-�'�3�!�C/�'�C/r

Zerion Mini Shell 1.0