简体   繁体   English

如何通过Java中的网关PC访问其他网络中的PC文件夹?

[英]How to access folder of PC in other network via gateway pc in Java?

I want to read files from a network share with Java.我想用 Java 从网络共享中读取文件。 Using jcifs works fine when accessing computers within the same network.访问同一网络中的计算机时,使用 jcifs 工作正常。

Now I need to read files from a computer in another network that is only accessible via a "gateway" pc:现在我需要从另一个网络中的计算机读取文件,该计算机只能通过“网关”PC 访问:
在此处输入图片说明

Is this possible?这可能吗? If yes: how?如果是:如何? (All computers run with Windows.) (所有计算机都运行 Windows。)

I'm not sure if there exists something already implemented that does what you want, but if I was going to develop this from scratch, probably I would develop some piece of software on the "gateway pc" for forwarding the requests from "my pc" to the "target pc".我不确定是否存在已经实现的功能可以满足您的要求,但是如果我要从头开始开发它,可能我会在“网关电脑”上开发一些软件来转发来自“我的电脑”的请求”到“目标电脑”。

Maybe you can use NFS4J, it works like a charm.也许您可以使用 NFS4J,它的作用就像一个魅力。

https://github.com/dCache/nfs4j https://github.com/dCache/nfs4j

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM