Package org.python.core
Class PyException
java.lang.Object
java.lang.Throwable
java.lang.Exception
java.lang.RuntimeException
org.python.core.PyException
- All Implemented Interfaces:
Serializable
- Direct Known Subclasses:
PySyntaxError
A wrapper for all python exception. Note that the wellknown
python exception are not subclasses of PyException.
Instead the python exception class is stored in the
type
field and value or class instance is stored
in the value
field.- See Also:
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionPyException
(PyObject type) PyException
(PyObject type, String value) PyException
(PyObject type, PyObject value) PyException
(PyObject type, PyObject value, PyTraceback traceback) -
Method Summary
Methods inherited from class java.lang.Throwable
addSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, setStackTrace
-
Field Details
-
type
The python exception class (for class exception) or identifier (for string exception). -
value
The exception instance (for class exception) or exception value (for string exception). -
traceback
-
-
Constructor Details
-
PyException
public PyException() -
PyException
-
PyException
-
PyException
-
PyException
-
-
Method Details
-
instantiate
public void instantiate() -
printStackTrace
public void printStackTrace()- Overrides:
printStackTrace
in classThrowable
-
printStackTrace
- Overrides:
printStackTrace
in classThrowable
-
super__printStackTrace
-
toString
-