server.JFilesServerThread - rsanchez-wsu/jfiles GitHub Wiki
The main purpose of this class is to handle individual connections. Each new connection is a JFilesServerThread.
Package: server
Constructors
+ JFilesServerThread(JFilesServer parmServer, Socket parmSocket)
Parameters:
parmServer
- The JFilesServer instanceparmSocket
- The client socket.
Member Variables
Private:
JFilesServer server
Socket socket
int id
DataInputStream streamIn
DataOutputStream streamOut
Functions
+ int getid()
Returns the client socket's port number.
+ void send(String msg)
Sends the message msg
to the client.
+ void open() throws IOException
Opens the streamIn and streamOut from the client's socket.
+ void close()
Closes the streamIn and streamOut from the client's socket.
+ void run()
Takes input in from socket and calls JFilesServer.handle()