How to get the class name of the java object in python

286 views
Skip to first unread message

Jeff Zhang

unread,
Dec 11, 2015, 4:03:08 AM12/11/15
to Py4J Support and Comments
type function only tell me that it is java object, but I want to know the class name of the this java object. How can I achieve that ? BTW, is there any python api doc for py4j. I didn't find it. Thanks


>>> type(rdd._jrdd)
<class 'py4j.java_gateway.JavaObject'>

Jeff Zhang

unread,
Dec 11, 2015, 4:06:10 AM12/11/15
to Py4J Support and Comments
Never mind, find the solution.

rdd._jrdd.getClass().getSimpleName()



在 2015年12月11日星期五 UTC+8下午5:03:08,Jeff Zhang写道:
Reply all
Reply to author
Forward
0 new messages