1 / 6

Networking with Sockets

Networking with Sockets . Java Networking . Java’s networking capabilities are declared by the classes and interfaces of package java.net , through which Java offers stream-based communications that enable applications to view networking as streams of data.

nanji
Télécharger la présentation

Networking with Sockets

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Networking with Sockets

  2. Java Networking • Java’s networking capabilities are declared by the classes and interfaces of package java.net, through which Java offers stream-based communications that enable applications to view networking as streams of data. • The classes and interfaces of package java.net also offer packet-based communications for transmitting individual packets of information—commonly used to transmit data images, audio and video over the Internet.

  3. client/server relationship • The client requests that some action be performed, and the server performs the action and responds to the client. A common implementation of the request-response model is between web browsers and web servers. When a user selects a website to browse through a browser (the client application), • a request is sent to the appropriate web server (the server application). The server normally responds to the client by sending an appropriate web page to be rendered by the browser.

  4. A Stream socket A process establishes a connection to another process. While the Connection is in place, data flows between the processes in continuous streams

  5. A socket address  Is the combination of an IP address and a port number, much like one end of a telephone connection is the combination of a phone number and a particular extension. Based on this address, internet sockets deliver incoming data packets to the appropriate application process

  6. 1-Datagramsocket (UDP) also known as connectionless sockets, which use UserDatagram protocol (UDP). 2-Stream socket (TCP) also known as connection-oriented sockets, which use Transmission control protocol(TCP) or Stream control Transmission protocol(SCTP). :Socket types

More Related