Download as pdf or txt
Download as pdf or txt
You are on page 1of 5

Course Title: Computer Networking Lab

Course Code: CSE 312


Experiment No: 04
Experiment Name: Implementation of Socket Programming in
Java.

Submitted by : Submitted to :

Name: Suraya Yesmin TANPIA TASNIM


ID: 182015050 Lecturer
Section: EA Department of CSE
Department of CSE Green University of Bangladesh
Green University of Bangladesh

Date of Submission: 10-12-2020


Experiment Name: Implementation of Socket Programming in Java.
Introduction
I create two classes Our Server. java and Our Client. java. The first class (Our Server .java) is for the
server and the second class (Our Client. java) is for the client. When we run our program it shows the
communication between both the client and the server, when we run the client program a message is
generated on the server side that indicates the connection between them.

Screenshot
Discussion
In this article, we discuss socket programming in Java. Socket Programming is used for communication
between machines using a Transfer Control Protocol (TCP). It can be connectionless or connection-
oriented. Server Socket and Socket classes are used for connection-oriented socket programming. After
creating a connection, the server develops a socket object on its end of the connection. The server and
client now starts communicating by writing to and reading from the socket.

You might also like