src.org.python.modules._systemrestart Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of jython-installer Show documentation
Show all versions of jython-installer Show documentation
Jython is an implementation of the high-level, dynamic, object-oriented
language Python written in 100% Pure Java, and seamlessly integrated with
the Java platform. It thus allows you to run Python on any Java platform.
package org.python.modules;
import org.python.core.ClassDictInit;
import org.python.core.Py;
import org.python.core.PyException;
import org.python.core.PyObject;
import org.python.core.PyStringMap;
public class _systemrestart implements ClassDictInit {
/**
* Jython-specific exception for restarting the interpreter. Currently
* supported only by jython.java, when executing a file (i.e,
* non-interactive mode).
*
* WARNING: This is highly *experimental* and subject to change.
*/
public static PyObject SystemRestart;
public static void classDictInit(PyObject dict) {
SystemRestart = Py.makeClass(
"_systemrestart.SystemRestart", Py.BaseException,
new PyStringMap() {{
__setitem__("__doc__",
Py.newString("Request to restart the interpreter. " +
"(Jython-specific)"));
}});
dict.__delitem__("classDictInit");
}
}