Your IP : 18.191.200.151
o
6��f#� � @ s6 d Z dgZdZdZdZddlZddlZddlZddl Zddl
ZddlZddlZddl
Z
ddlZddlZddlZddlZddlZddlZddlZddlZddlZddlZddlmZ ddlmZ dd lmZ d
d� Zdd
� Z dd� Z!dd� Z"dd� Z#dd� Z$dd� Z%dd� Z&dd� Z'dd� Z(dd� Z)d d!� Z*e�+d"ej,�Z-d#d$� Z.d%d&� Z/d'd(� Z0d)d*� Z1d�d+d,�Z2d-d.� Z3d/d0� Z4d1d2� Z5d3d4� Z6i fd5d6�Z7G d7d8� d8e8�Z9d9d:� Z:di fd;d<�Z;G d=d>� d>�Z<G d?d@� d@e�Z=G dAdB� dBe<�Z>G dCdD� dDe�Z?G dEdF� dFe<�Z@G dGdH� dHe@�ZAdIdJ� aBdKdL� ZCdMdN� ZDdOdP� ZEdQdR� ZFdSdT� ZGdUdV� ZHdWdX� ZIdYdZ� ZJd�d[d\�ZKe@� ZLeA� ZMe>� ZNd�d]d^�ZO d�d`da�ZP d�dbdc�ZQd�ddde�ZRd�dgdh�ZSG didj� dj�ZTeT� ZUG dkdl� dl�ZVdmdn� ZWdodp� ZXd�drds�ZYd�dtdudv�dwdx�ZZdydz� Z[d{d|� Z\d}d~� Z]dd�� Z^e_d�k�r�e^� dS dS )�a Generate Python documentation in HTML or text for interactive use.
At the Python interactive prompt, calling help(thing) on a Python object
documents the object, and calling help() starts up an interactive
help session.
Or, at the shell command line outside of Python:
Run "pydoc <name>" to show documentation on something. <name> may be
the name of a function, module, package, or a dotted reference to a
class or function within a module or module in a package. If the
argument contains a path segment delimiter (e.g. slash on Unix,
backslash on Windows) it is treated as the path to a Python source file.
Run "pydoc -k <keyword>" to search for a keyword in the synopsis lines
of all available modules.
Run "pydoc -n <hostname>" to start an HTTP server with the given
hostname (default: localhost) on the local machine.
Run "pydoc -p <port>" to start an HTTP server on the given port on the
local machine. Port number 0 can be used to get an arbitrary unused port.
Run "pydoc -b" to start an HTTP server on an arbitrary unused port and
open a web browser to interactively browse documentation. Combine with
the -n and -p options to control the hostname and port used.
Run "pydoc -w <name>" to write out the HTML documentation for a module
to a file named "<name>.html".
Module docs for core modules are assumed to be in
https://docs.python.org/X.Y/library/
This can be overridden by setting the PYTHONDOCS environment variable
to a different URL or to a local directory containing the Library
Reference Manual pages.
�helpzKa-Ping Yee <ping@lfw.org>z26 February 2001z�Guido van Rossum, for an excellent programming language.
Tommy Burnette, the original creator of manpy.
Paul Prescod, for all his work on onlinehelp.
Richard Chamberlain, for the first implementation of textdoc.
� N)�deque)�Repr)�format_exception_onlyc C s\ g } g }t jD ]$}tj�|pd�}tj�|�}||vr+tj�|�r+| �|� |�|� q| S )zAConvert sys.path into a list of absolute, existing, unique paths.�.)�sys�path�os�abspath�normcase�isdir�append)�dirsZnormdirs�dirZnormdir� r �,/opt/alt/python310/lib64/python3.10/pydoc.py�pathdirsR s
�r c C s t �| �ot| tj� S �N)�inspectZisclass�
isinstance�types�GenericAlias��objectr r r �_isclass^ s r c C sN t j�| j�}|d u r
d S | j�d�d d� D ]}t||�}qt|�s%d S |S )Nr ���)r �modules�get�
__module__�__qualname__�split�getattrr )�func�cls�namer r r �
_findclassa s r% c C s� t �| �r#| jj}| j}t|�rtt||d �d�| ju r|}n�|j}n�t �| �r=| j}t | �}|d u s:t||�| ur<d S nqt �
| �r]| j}| j}t|�rY|jd | | jkrY|}nU|j}nQt| t
�rz| j}|j}t |�}|d u swt||�| uryd S n4t �| �s�t �| �r�| j}| j}t||�| ur�d S t �| �r�t|dd �}t|t�r�||v r�|| S nd S |jD ]}z tt||��}W n ty� Y q�w |d ur�| S q�d S )N�__func__r � __slots__)r �ismethodr&