Java服务器/客户端文件读取问题 [英] Java Server/Client file reading problem
问题描述
所以我要编写一个简单的服务器客户端应用程序,但是我可以创建一个聊天服务器客户端,但是我现在想要做的是使应用程序再次具有客户端服务器应用程序,但是客户端可以在该服务器上创建文件.服务器并阅读它们.
所以客户端有一个textField,一个textArea和一个按钮,现在我想在将文件名输入到textField并按下按钮时要执行的操作,我希望它在textArea中显示该文件,有人可以解释一下吗我该怎么做呢?
So iam writing a simple server client application ,however i can make a chat server client , but what i am trying to do now is to make a application where i have a client server application again however the client can create files on the server and read them .
So the client has a textField , a textArea and a button , now what i want to do it to have when i type files name into the textField and hit the button i would like it to dispaly that file in the textArea , can someone please explain how i can do that ?
推荐答案
似乎您正在尝试本质上使用套接字通过网络传输和读取文件.看看这些链接是否可以帮助您实现所需的目标:
套接字文件 [通过套接字的文件 [
Seems like you are trying to transfer and read files over network essentially using sockets. See if these links help you with what you want:
Sockets files[^]
files over sockets[^]
Hope that helps..Cheers.
这篇关于Java服务器/客户端文件读取问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!