Class SocketChannel
java.lang.Object
edu.jas.util.SocketChannel
SocketChannel provides a communication channel for Java objects using TCP/IP
sockets. Refactored for java.util.concurrent.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final ObjectInputStreamprivate final ObjectOutputStreamprivate final Socket -
Constructor Summary
Constructors -
Method Summary
-
Field Details
-
in
-
out
-
soc
-
-
Constructor Details
-
SocketChannel
Constructs a socket channel on the given socket s.- Parameters:
s- A socket object.- Throws:
IOException
-
-
Method Details
-
getSocket
Get the Socket -
send
-
receive
Receives an object- Throws:
IOExceptionClassNotFoundException
-
close
public void close()Closes the channel. -
toString
-