我已经安装了jpcap并将其添加到库中,但我在这行中有错误:
String[] devices = JpcapCaptor.getDeviceList();
我认为我错了,因为它说: 找不到Javadoc。此项目的Javadoc文档不存在,或者您尚未在Java Platform Manager或库管理器中添加指定的Javadoc。
public static void main(String[] args) throws UnknownHostException {
// TODO code application logic here
String[] devices = JpcapCaptor.getDeviceList();
if(args.length<1){
System.out.println("Usage: java SentUDP <device index (e.g., 0, 1..)>");
for(int i=0;i<devices.length;i++)
System.out.println(i+":"+devices[i].name+"("+devices[i].description+")");
System.exit(0);
}