How to create a new dial connection in java?

核能气质少年 提交于 2019-12-25 01:33:43

问题


In my application user has to create a new dial up network connection in windows but i want to do this programmatically.Is there any API present in java that can help me for creating new network connection.


回答1:


There is no way to create a Windows dial-up networking connection using pure Java. You might consider using Java to call built-in Windows command line programs though. See this as a starting point: http://support.microsoft.com/kb/555935




回答2:


What do you need the network connection for? If you want to talk to another client of your application or a server written in Java, you can use the Socket class.




回答3:


Sun used to have a phone/telecom API that might help, but I think it has not been developed on in years... since probably about the same time dial-up died. :-)

Your best option may be to look for a native API that does what you want and write a JNI wrapper around it. Alternately, if you are lucky some google searching might come up with someone who has already done that.

Good luck.



来源:https://stackoverflow.com/questions/3988421/how-to-create-a-new-dial-connection-in-java

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!