403Webshell
Server IP : 178.105.222.151  /  Your IP : 216.73.216.38
Web Server : nginx/1.28.3
System : Linux MNK 7.0.0-15-generic #15-Ubuntu SMP PREEMPT_DYNAMIC Wed Apr 22 16:06:43 UTC 2026 x86_64
User : www-data ( 33)
PHP Version : 8.5.4
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : OFF
Directory :  /lib/python3/dist-packages/markdown_it/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /lib/python3/dist-packages/markdown_it/__pycache__/tree.cpython-314.pyc
+
�
�i�,���Rt^RIHt^RIHtHt^RIt^RIHtH	t	H
t
Ht^RIH
t
!RR]	4t]
!RR	R
7t!RR	4tRR
ltR#)zyA tree representation of a linear markdown-it token stream.

This module is not part of upstream JavaScript markdown-it.
)�annotations)�	Generator�SequenceN)�Any�
NamedTuple�TypeVar�overload)�Tokenc�,�]tRt^t$R]R&R]R&RtR#)�
_NesterTokensr	�opening�closing�N)�__name__�
__module__�__qualname__�__firstlineno__�__annotations__�__static_attributes__r��2/usr/lib/python3/dist-packages/markdown_it/tree.pyrrs��
�N�
�Nrr�	_NodeType�SyntaxTreeNode)�boundc���]tRt^tRtRKRR/RRllltRRlt]RR	l4t]R
Rl4tRR
ltRRlt	]
RRl4t]PRRl4t]
RRl4t
]
PRRl4t
]
RRl4t]
RRl4t]
RRl4t]
RRl4t]
R R!l4t]
R"R#l4tR$R%ltR&R'ltR(^R)R*R+^/R,R-lltR.R/R/R0lltR1R2lt]
R3R4l4t]
R5R6l4tR7R8lt]
R9R:l4t]
R;R<l4t]
R=R>l4t]
R?R@l4t]
RARBl4t ]
RCRDl4t!]
RERFl4t"]
RGRHl4t#RIt$RJ#)LraEA Markdown syntax tree node.

A class that can be used to construct a tree representation of a linear
`markdown-it-py` token stream.

Each node in the tree represents either:
  - root of the Markdown document
  - a single unnested `Token`
  - a `Token` "_open" and "_close" token pair, and the tokens nested in
      between
�create_rootTc�$�V^8�dQhRRRRRR/#)��tokens�Sequence[Token]r�bool�return�Noner)�formats"r�__annotate__�SyntaxTreeNode.__annotate__#s$��(9�(9�%�(9�<@�(9�	
�(9rc
���RVnRVnRVn.VnV'dVP	V4R#V'g\R4h\
V4^8Xd^V^,pVP'd\R4hW0nVP'dVP	VP4R#R#\V^,VR,4VnVP	V^R4R#)zsInitialize a `SyntaxTreeNode` from a token stream.

If `create_root` is True, create a root node for the document.
NzGCan only create root from empty token sequence. Set `create_root=True`.z;Unequal nesting level at the start and end of token stream.���)
�token�
nester_tokens�_parent�	_children�_set_children_from_tokens�
ValueError�len�nesting�childrenr)�selfrr�inline_tokens&&$ r�__init__�SyntaxTreeNode.__init__#s���$(��
�48���!���%'�����*�*�6�2����+��
���[�A�
�!�!�9�L��#�#�#� �Q���&�J��$�$�$��.�.�|�/D�/D�E�%�"/�v�a�y�&��*�!E�D���*�*�6�!�B�<�8rc��V^8�dQhRR/#�rr!�strr)r#s"rr$r%Ms��5�5�#�5rc	�L�\V4PRVPR2#)�(�))�typer�r1s&r�__repr__�SyntaxTreeNode.__repr__Ms$���t�*�%�%�&�a��	�	�{�!�4�4rc�$�V^8�dQhRRRRRR/#)rr1r�item�intr!r)r#s"rr$r%Qs!����)��3��9�rc	��R#�Nr�r1r@s&&r�__getitem__�SyntaxTreeNode.__getitem__P���rc�$�V^8�dQhRRRRRR/#)rr1rr@�slicer!�list[_NodeType]r)r#s"rr$r%Us!����)��5��_�rc	��R#rCrrDs&&rrErFTrGrc�$�V^8�dQhRRRRRR/#)rr1rr@zint | slicer!z_NodeType | list[_NodeType]r)r#s"rr$r%Xs"��#�#�)�#�;�#�;V�#rc	�(�VPV,#rC)r0rDs&&rrErFXs���}�}�T�"�"rc� �V^8�dQhRRRR/#)rr1rr!�list[Token]r)r#s"rr$r%[s����	��k�rc
�.a�RV3Rllo.pS!W4V#)z Recover the linear token stream.c�$�V^8�dQhRRRRRR/#)r�noder�
token_listrOr!r"r)r#s"rr$�.SyntaxTreeNode.to_tokens.<locals>.__annotate__^s"��	>�	>�9�	>�+�	>�RV�	>rc�<�VPR8XdVPFpS!W!4K
	R#VP'dVPVP4R#VP'gQhVPVPP
4VPFpS!W!4K
	VPVPP4R#)�rootN)r;r0r(�appendr)rr
)rRrS�child�recursive_collect_tokenss&& �rrY�:SyntaxTreeNode.to_tokens.<locals>.recursive_collect_tokens^s�����y�y�F�"�!�]�]�E�,�U�?�+������!�!�$�*�*�-��)�)�)�)�)��!�!�$�"4�"4�"<�"<�=�!�]�]�E�,�U�?�+��!�!�$�"4�"4�"<�"<�=rr)r1rrYs& @r�	to_tokens�SyntaxTreeNode.to_tokens[s!���	>�	>�!�� ��.��
rc� �V^8�dQhRRRR/#)rr1rr!rJr)r#s"rr$r%ps����y��_�rc	��VP#rC�r+r<s&rr0�SyntaxTreeNode.childrenos���~�~�rc�$�V^8�dQhRRRRRR/#)rr1r�valuerJr!r"r)r#s"rr$r%ts!����y����T�rc	��WnR#rCr_�r1rbs&&rr0r`ss���rc� �V^8�dQhRRRR/#�rr1rr!�_NodeType | Noner)r#s"rr$r%xs����Y��#3�rc	��VP#rC�r*r<s&r�parent�SyntaxTreeNode.parentws���|�|�rc�$�V^8�dQhRRRRRR/#)rr1rrbrgr!r"r)r#s"rr$r%|s"����Y��'7��D�rc	��WnR#rCrirds&&rrjrk{s���rc��V^8�dQhRR/#�rr!r r)r#s"rr$r%�s��6�6��6rc
�L�VP;'g
VP'*#)z Is the node a special root node?)r(r)r<s&r�is_root�SyntaxTreeNode.is_roots���J�J�4�4�$�"4�"4�5�5rc��V^8�dQhRR/#ror)r#s"rr$r%�s��(�(�4�(rc
�,�\VP4#)z�Is this node nested?.

Returns `True` if the node represents a `Token` pair and tokens in the
sequence between them, where `Token.nesting` of the first `Token` in
the pair is 1 and nesting of the other `Token` is -1.
)r r)r<s&r�	is_nested�SyntaxTreeNode.is_nested�s���D�&�&�'�'rc� �V^8�dQhRRRR/#)rr1rr!zSequence[_NodeType]r)r#s"rr$r%�s��$�$�y�$�%8�$rc
�X�VP'gV.#VPP#)zMGet siblings of the node.

Gets the whole group of siblings, including self.
)rjr0r<s&r�siblings�SyntaxTreeNode.siblings�s$���{�{�{��6�M��{�{�#�#�#rc��V^8�dQhRR/#r6r)r#s"rr$r%�s��
G�
G�c�
Grc
��VP'dR#VP'dVPP#VP'gQh\	VPP
PR4#)z�Get a string type of the represented syntax.

- "root" for root nodes
- `Token.type` if the node represents an unnested token
- `Token.type` of the opening token, with "_open" suffix stripped, if
    the node represents a nester token pair
rV�_open)rqr(r;r)�
_removesuffixrr<s&rr;�SyntaxTreeNode.type�sX���<�<�<���:�:�:��:�:�?�?�"��!�!�!�!�!��T�/�/�7�7�<�<�g�F�Frc� �V^8�dQhRRRR/#rfr)r#s"rr$r%�s����9��)9�rc
��VPPV4pV^,\VP48dVPV^,,#R#)z\Get the next node in the sequence of siblings.

Returns `None` if this is the last sibling.
N)ry�indexr.�r1�
self_indexs& r�next_sibling�SyntaxTreeNode.next_sibling�sC���]�]�(�(��.�
���>�C��
�
�.�.��=�=��a��0�0�rc� �V^8�dQhRRRR/#rfr)r#s"rr$r%�s����y��-=�rc
��VPPV4pV^,
^8�dVPV^,
,#R#)zaGet the previous node in the sequence of siblings.

Returns `None` if this is the first sibling.
N)ryr�r�s& r�previous_sibling�SyntaxTreeNode.previous_sibling�s:���]�]�(�(��.�
���>�Q���=�=��a��0�0�rc� �V^8�dQhRRRR/#�rrrr!r"r)r#s"rr$r%�s��$�$��$�
�$rc
�n�\V4!VRR7pWnVPPV4R#)zMake a child node for `self`.F)rN)r;rjr0rW)r1rrXs&& r�
_add_child�SyntaxTreeNode._add_child�s+��
�T�
�6�u�5�����
�
���U�#rc� �V^8�dQhRRRR/#r�r)r#s"rr$r%�s��+�+��+�D�+rc
���\\V44pV'd�VP4pVP'gVP	V.4K>VP^8wd\R4hV.p^pV'd>V'd6VP4pVP
V4WSP,
pKEV'd\RV^,24hVP	V4K�R#)z_Convert the token stream to a tree structure and set the resulting
nodes as children of `self`.zInvalid token nestingzunclosed tokens starting N)�list�reversed�popr/r�r-rW)r1r�reversed_tokensr(�
nested_tokensr/s&&    rr,�(SyntaxTreeNode._set_children_from_tokens�s����x��/�0���#�'�'�)�E��=�=�=������(���}�}��!� �!8�9�9�"�G�M��G�!�g�'�+�+�-���$�$�U�+��=�=�(��� �#<�]�1�=M�<N�!O�P�P��O�O�M�*�%r�indent�	show_textF�_currentc�(�V^8�dQhRRRRRRRR/#)rr�rAr�r r�r!r7r)r#s"rr$r%�s,������-1��EH��	�rc	
��RV,pVRVP2,pVP'gQVP'd?VRRPRVPP	444,,
pVR,
pV'dsVP'gaVPR9dPVP
'd>VR\P!VP
VRV,,4,,
pVPF*pVRVPWW1,R7,,
pK,	V#)z'Create an XML style string of the tree.� �<c3�6"�TFwrVRV:2x�K	R#5i)�=Nr)�.0�k�vs&  r�	<genexpr>�(SyntaxTreeNode.pretty.<locals>.<genexpr>�s���"O�<N�D�A�a�S��!��<�<N�s��>�
)r�r�r�)�text�text_special)
r;rq�attrs�join�items�content�textwrapr�r0�pretty)r1r�r�r��prefixr�rXs&$$$   rr��SyntaxTreeNode.pretty�s����x����!�D�I�I�;��'���|�|�|��
�
�
��C�#�(�(�"O�D�J�J�<L�<L�<N�"O�O�O�O�D�������L�L�L��	�	�5�5������D�8�?�?�4�<�<��#��,�9N�O�O�O�D��]�]�E��D�5�<�<��X�=N�(���
�D�#��r�include_selfc�$�V^8�dQhRRRRRR/#)rr1rr�r r!z Generator[_NodeType, None, None]r)r#s"rr$r%�s$��5�5��5�*.�5�	)�5rc#
�"�V'dVx�VPFpVPRR7Rjx�L
K	R#L
5i)z�Recursively yield all descendant nodes in the tree starting at self.

The order mimics the order of the underlying linear token
stream (i.e. depth first).
T)r�N)r0�walk)r1r�rXs&$ rr��SyntaxTreeNode.walk�s4�����J��]�]�E��z�z�t�z�4�4�4�#�4�s�1A�>�Ac��V^8�dQhRR/#)rr!r	r)r#s"rr$r%s��O�O�%�Orc
��VP'd
VP#VP'dVPP#\R4h)zTReturn the `Token` that is used as the data source for the
properties defined below.z.Root node does not have the accessed attribute)r(r)r�AttributeErrorr<s&r�_attribute_token�SyntaxTreeNode._attribute_tokensA���:�:�:��:�:�������%�%�-�-�-��M�N�Nrc��V^8�dQhRR/#r6r)r#s"rr$r%s��+�+�S�+rc
�6�VP4P#)zhtml tag name, e.g. "p" )r��tagr<s&rr��SyntaxTreeNode.tags���$�$�&�*�*�*rc��V^8�dQhRR/#)rr!zdict[str, str | int | float]r)r#s"rr$r%s��-�-�3�-rc
�6�VP4P#)zHtml attributes.)r�r�r<s&rr��SyntaxTreeNode.attrs����$�$�&�,�,�,rc� �V^8�dQhRRRR/#)r�namer7r!zNone | str | int | floatr)r#s"rr$r%s��5�5�C�5�$<�5rc
�@�VP4PV4#)z@Get the value of attribute `name`, or null if it does not exist.)r��attrGet)r1r�s&&rr��SyntaxTreeNode.attrGets���$�$�&�.�.�t�4�4rc��V^8�dQhRR/#)rr!ztuple[int, int] | Noner)r#s"rr$r%#s����+�rc
�`�VP4PpV'd\V4#R#)z8Source map info. Format: `tuple[ line_begin, line_end ]`N)r��map�tuple)r1�map_s& rr��SyntaxTreeNode.map"s(���$�$�&�*�*�����;��rc��V^8�dQhRR/#)rr!rAr)r#s"rr$r%,s��-�-�s�-rc
�6�VP4P#)z(nesting level, the same as `state.level`)r��levelr<s&rr��SyntaxTreeNode.level+r�rc��V^8�dQhRR/#r6r)r#s"rr$r%1s��/�/��/rc
�6�VP4P#)zUIn a case of self-closing tag (code, html, fence, etc.), it
has contents of this tag.)r�r�r<s&rr��SyntaxTreeNode.content0s���$�$�&�.�.�.rc��V^8�dQhRR/#r6r)r#s"rr$r%7s��.�.��.rc
�6�VP4P#)z5'*' or '_' for emphasis, fence string for fence, etc.)r��markupr<s&rr��SyntaxTreeNode.markup6s���$�$�&�-�-�-rc��V^8�dQhRR/#r6r)r#s"rr$r%<s��,�,�c�,rc
�6�VP4P#)zfence infostring)r��infor<s&rr��SyntaxTreeNode.info;����$�$�&�+�+�+rc��V^8�dQhRR/#)rr!zdict[Any, Any]r)r#s"rr$r%As��,�,�n�,rc
�6�VP4P#)z/A place for plugins to store an arbitrary data.)r��metar<s&rr��SyntaxTreeNode.meta@r�rc��V^8�dQhRR/#ror)r#s"rr$r%Fs��-�-�t�-rc
�6�VP4P#)z5True for block-level tokens, false for inline tokens.)r��blockr<s&rr��SyntaxTreeNode.blockEr�rc��V^8�dQhRR/#ror)r#s"rr$r%Ks��.�.��.rc
�6�VP4P#)zZIf it's true, ignore this element when rendering.
Used for tight lists to hide paragraphs.)r��hiddenr<s&rr��SyntaxTreeNode.hiddenJs���$�$�&�-�-�-r)r+r*r)r(N)r)%rrrr�__doc__r3r=rrEr[�propertyr0�setterrjrqruryr;r�r�r�r,r�r�r�r�r�r�r�r�r�r�r�r�r�r�rrrrrrs*��
�(9�CG�(9�(9�T5���������#��(�����_�_���������]�]�����6��6��(��(��$��$��
G��
G���������$�+�0� ��49��KL��,5�15�5�,O��+��+��-��-�5������-��-��/��/�
�.��.��,��,��,��,��-��-��.��.rc�$�V^8�dQhRRRRRR/#)r�stringr7�suffixr!r)r#s"rr$r$Qs!����#��s��s�rc�b�V'd'VPV4'dVR\V4)#V#)zuRemove a suffix from a string.

Replace this with str.removesuffix() from stdlib when minimum Python
version is 3.9.
N)�endswithr.)r�r�s&&rr~r~Qs-���&�/�/�&�)�)��n��V���%�%��Mr)r��
__future__r�collections.abcrrr��typingrrrrr(r	rrrr~rrr�<module>r�sK���#�/��5�5���J��

�K�'7�8�	�x.�x.�v	r

Youez - 2016 - github.com/yon3zu
LinuXploit