Simple Java example of TCP Client/Server communication

Published: 14 February 2014
on channel: j.Buddy Erik
8,839
3

It's a simple example to implement TCP Client/Server in Java. To test the function, start JavaTCPServer with port number in Terminal. The server will open a ServerSocket and wait for incoming message from client. Then start JavaTCPClient with IP address and port number in another Terminal, then enter anything. The user input will be sent to JavaTCPServer via TCP socket, when JavaTCPServer receive the message, it will echo back to JavaTCPClient, then both JavaTCPServer and JavaTCPClient close the socket.

source code:
http://java-buddy.blogspot.com/2014/0...


On this page of the site you can watch the video online Simple Java example of TCP Client/Server communication with a duration of hours minute second in good quality, which was uploaded by the user j.Buddy Erik 14 February 2014, share the link with friends and acquaintances, this video has already been watched 8,839 times on youtube and it was liked by 3 viewers. Enjoy your viewing!