epydoc.imports

Package epydoc :: Module imports |
[show private | hide private]
[frames | no frames]

## Module epydoc.imports

Module import support for epydoc.

Function Summary
`list` of `string` | ``find_modules`(dirname)` If `dirname` contains a package, then return the filenames for the package, its modules, and all of its descendant packages and modules.
`list` of `module` | ``import_module`(name_or_filename)` Return the module with the given module name or filename.

Function Details

### find_modules(dirname) If `dirname` contains a package, then return the filenames for the package, its modules, and all of its descendant packages and modules. If `dirname` does not contain a package, then return an empty list. Parameters: `dirname` - The directory name to search. (type=`string`) Returns: The filenames for the package in `dirname`, its modules, and all of its descendant packages and modules. (type=`list` of `string`)

### import_module(name_or_filename) Parameters: `name_or_filename` - The module name or filename specifying which module to import. (type=`string`) Returns: The module with the given module name or filename. If `name_or_filename` is the name of a module (such as `os.path`), then return that module. If `name_or_filename` is the name of a file (such as `epytext.py` or `multiarray.so`), then return the module defined by that file. If `name_or_filename` names both a file and a module, then `import_module` will treat it as a file name. (type=`list` of `module`) Raises: `ImportError` - If there was any problem importing the given object. In particular, an `ImportError` is raised if the given file does not exist; if the given file name does not name a valid module; or if importing the module causes any exception to be raised.

Generated by Epydoc 2.1 on Sat Mar 20 17:46:16 2004 | http://epydoc.sf.net