March 2003
Intermediate to advanced
656 pages
39h 30m
English
get
PyObjectinterp.get(Stringname) Objectinterp.get(Stringname,Classjavaclass)
Fetches the value of the attribute named
name from
interp’s namespace. The
overload with two arguments also converts the value to the specified
javaclass, throwing a Java
PyException exception that wraps a Python
TypeError if the conversion is unfeasible. Either
overload raises a NullPointerException if
name is unbound. Typical use of the
two-argument form might be a Java statement such as:
String s = (String)interp.get("attname", String.class);Read now
Unlock full access