eric7/Documentation/Source/eric7.Utilities.ClassBrowsers.__init__.html

Fri, 17 Sep 2021 19:04:07 +0200

author
Detlev Offenbach <detlev@die-offenbachs.de>
date
Fri, 17 Sep 2021 19:04:07 +0200
branch
eric7
changeset 8611
0b1a09e47e98
parent 8596
d64760b2da50
permissions
-rw-r--r--

Virtual Environments
- added a standalone variant of the Virtual Environments Manager

<!DOCTYPE html>
<html><head>
<title>eric7.Utilities.ClassBrowsers.__init__</title>
<meta charset="UTF-8">
<link rel="stylesheet" href="styles.css">
</head>
<body>
<a NAME="top" ID="top"></a>
<h1>eric7.Utilities.ClassBrowsers.__init__</h1>

<p>
Package implementing class browsers for various languages.
</p>
<p>
Currently it offers class browser support for the following
programming languages.
</p>
<p>
<ul>
<li>CORBA IDL</li>
<li>JavaScript</li>
<li>ProtoBuf</li>
<li>Python 3</li>
<li>Ruby</li>
</ul>
</p>
<h3>Global Attributes</h3>

<table>
<tr><td>IDL_SOURCE</td></tr><tr><td>JS_SOURCE</td></tr><tr><td>PROTO_SOURCE</td></tr><tr><td>PTL_SOURCE</td></tr><tr><td>PY_SOURCE</td></tr><tr><td>RB_SOURCE</td></tr><tr><td>SUPPORTED_TYPES</td></tr><tr><td>__extensions</td></tr>
</table>
<h3>Classes</h3>

<table>
<tr><td>None</td></tr>
</table>
<h3>Functions</h3>

<table>

<tr>
<td><a href="#find_module">find_module</a></td>
<td>Module function to extend the Python module finding mechanism.</td>
</tr>
<tr>
<td><a href="#readmodule">readmodule</a></td>
<td>Read a source file and return a dictionary of classes, functions, modules, etc.</td>
</tr>
</table>
<hr />
<hr />
<a NAME="find_module" ID="find_module"></a>
<h2>find_module</h2>
<b>find_module</b>(<i>name, path, isPyFile=False</i>)

<p>
    Module function to extend the Python module finding mechanism.
</p>
<p>
    This function searches for files in the given list of paths. If the
    file name doesn't have an extension or an extension of .py, the normal
    Python search implemented in the imp module is used. For all other
    supported files only the paths list is searched.
</p>
<dl>

<dt><i>name</i> (str)</dt>
<dd>
file name or module name to search for
</dd>
<dt><i>path</i> (list of str)</dt>
<dd>
search paths
</dd>
<dt><i>isPyFile</i> (bool)</dt>
<dd>
flag indicating a Python file
</dd>
</dl>
<dl>
<dt>Return:</dt>
<dd>
tuple of the open file, pathname and description. Description
        is a tuple of file suffix, file mode and file type)
</dd>
</dl>
<dl>
<dt>Return Type:</dt>
<dd>
tuple
</dd>
</dl>
<dl>

<dt>Raises <b>ImportError</b>:</dt>
<dd>
The file or module wasn't found.
</dd>
</dl>
<div align="right"><a href="#top">Up</a></div>
<hr />
<hr />
<a NAME="readmodule" ID="readmodule"></a>
<h2>readmodule</h2>
<b>readmodule</b>(<i>module, path=None, isPyFile=False</i>)

<p>
    Read a source file and return a dictionary of classes, functions, modules,
    etc. .
</p>
<p>
    The real work of parsing the source file is delegated to the individual
    file parsers.
</p>
<dl>

<dt><i>module</i> (str)</dt>
<dd>
name of the source file
</dd>
<dt><i>path</i> (list of str)</dt>
<dd>
list of paths the file should be searched in
</dd>
<dt><i>isPyFile</i> (bool)</dt>
<dd>
flag indicating a Python file
</dd>
</dl>
<dl>
<dt>Return:</dt>
<dd>
the resulting dictionary
</dd>
</dl>
<dl>
<dt>Return Type:</dt>
<dd>
dict
</dd>
</dl>
<div align="right"><a href="#top">Up</a></div>
<hr />
</body></html>

eric ide

mercurial