문제

Can anybody explain what does JdClient is in this code:

public JdClient client = new DefaultJdClient("some args")

and how to implement this in python with Jpype

도움이 되었습니까?

해결책

It creates a public variable named client of type JdClient by calling the DefaultJdClient constructor with some arguments.

To use it in Python would be something along these lines, although can't be certain as I just did a cursory glances over the documentation, and I have no idea where JdClient comes from so there might be a need to import that Java library and reference it as needed, like one would do java.lang.System.out.println('hello world')

from jpype import *
startJVM("d:/tools/j2sdk/jre/bin/client/jvm.dll", "-ea")
client = DefaultJdClient("hello world")
shutdownJVM() 
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top