org.python.core
Class ContextGuard
java.lang.Object
org.python.core.ContextGuard
- All Implemented Interfaces:
- ContextManager
public class ContextGuard
- extends Object
- implements ContextManager
Straightens the call path for some common cases
__enter__
public PyObject __enter__(ThreadState ts)
- Specified by:
__enter__
in interface ContextManager
__exit__
public boolean __exit__(ThreadState ts,
PyException exception)
- Specified by:
__exit__
in interface ContextManager
getManager
public static ContextManager getManager(PyObject manager)
makeManager
public static PyObject makeManager(PyObject object)
Jython homepage