我在 Linux 中开发了一个应用程序,它调用 DDS 磁带驱动器。在 Linux 中,我使用一个路径来调用磁带驱动器,即/dev/st0
应用程序是用 Java 编写的,它使用 JNI 调用其 native 函数
我尝试在 Windows 8.1 上运行我的应用程序,但显然我收到错误:
java.io.IOException: The system cannot find the path specified.
你知道如何解决这个问题吗?
这是触发问题的 Java 代码:
public TapeJNI(String pathName){
fd = new FileDescriptor();
System.out.print("Opening device...");
System.out.flush();
try {
tapeOpen(pathName); //here it is
} catch (IOException e) {
System.err.print(e);
}
System.out.println("done!");
}
最佳答案
如果您只有一个磁带驱动器,则设备路径将为“\\.\Tape0”
关于java - Windows 8.1 上的磁带机目录路径,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/23778814/