SocketWithoutNetwork11Example -- communicating
across a socket using the "loopback" address.
This class manages a server socket listening on port 7834, and
its partner class, ClientWithoutNetwork11, runs
a client for that server socket.
To see this example in action:
- Compile the Java source file, SocketWithoutNetwork11Example.java:
javac SocketWithoutNetwork11Example.java
- Run the class:
java SocketWithoutNetwork11Example
- Run the server socket class in one command-line shell:
java SocketWithoutNetwork11Example
- Run the client socket class in a different command-line shell:
java ClientWithoutNetwork11
- Run a second client socket after the first one completes:
java ClientWithoutNetwork11
The source.