Package nMOLDYN :: Package Core :: Module Misc |
[hide private]
[frames] | no frames]

# Module Misc

source code

    This modules implements the functions and procedures that can not be classified anywhere else in
    the library.

    There should not be too much stuff here in order to not mess up the code.

    Functions:
        * findNestedDirectories : parses recursively a directory tree appending each nested subdirectory found in a list.
        * findExecutable        : searches for an executable in OS dependant classical paths.

Functions | [hide private]
findNestedDirectories(root, dirList) Parses recursively the directory tree starting from directory |rootDir| appending all the subdirectories found in |dirList| list. | source code
string |
findExecutable(name) Searches for an executable in OS dependant classical paths. | source code
determineNumberOfCPUs() Number of virtual or physical CPUs on this system, i.e. | source code
integer |
cpuInfo() Retrieves the total numbers of processors, the number of loaded and free processors on the host machine. | source code

Variables | [hide private]
| scannedDirectories = `[sys.prefix]`

Function Details | [hide private]

### findNestedDirectories(root, dirList) | source code
Parses recursively the directory tree starting from directory |rootDir| appending all the subdirectories found in |dirList| list. Parameters: `root` (string) - a string specifying the directory from which the directory tree will be generated. `dirList` (list) - a complete list of all the subdirectories found starting from directory |rootDir|. Note: take care this is a recursive function.

### findExecutable(name) | source code
Searches for an executable in OS dependant classical paths. Parameters: `name` (string) - a string specifying the name of the executable. Returns: string a string specifying the absolute name of the executable |name] if it could be found an empty string otherwise.

### determineNumberOfCPUs() | source code
Number of virtual or physical CPUs on this system, i.e. user/real as output by time(1) when called with an optimally scaling userspace-only program

### cpuInfo() | source code
Retrieves the total numbers of processors, the number of loaded and free processors on the host machine. Returns: integer the total number of processors on the host machine.