See: Description
Class | Description |
---|---|
DL |
A replacement for
System.load(String) with support for POSIX dlopen flags. |
PyLib |
Represents the library that provides the Python interpreter (CPython).
|
PyLib.Diag |
Controls output of diagnostic information for debugging.
|
PyModule |
Represents a Python module.
|
PyObject |
Represents a Python object (of Python/C API type
PyObject* ) in the Python interpreter. |
Enum | Description |
---|---|
PyInputMode |
Source code input modes for compiling/executing Python source code.
|
PyLib.CallableKind |
The kind of callable Python objects.
|
The entry point to the jpy Java API is the PyLib
class which is used to either
detect an already running Python interpreter or to start a new one:
if (!PyLib.isPythonRunning()) { PyLib.startPython(opt1, opt2, ...); }jpy API clients should first call
PyLib.isPythonRunning()
in order to check if a Python interpreter is already available.
If not, PyLib.startPython(String...)
must be called before any other jpy API is used.
Once the Python interpreter in running clients can either execute Python code directly using the PyLib.execScript(String)
method or
load a Python module using PyModule.importModule(String)
. The returned PyModule
object
then is the entry point to access Python variables and invoke functions.
Some PyModule
methods return PyObject
instances. These can be used to
create instances of Python classes, and to access Python class members, attributes and to invoke Python object methods..
Copyright © 2014–2015 Brockmann Consult GmbH. All rights reserved.