Core Java| JSP| Servlets| XML| EJB| JEE5| Web Services| J2ME| Glossary| Questions?

 

 

 

 

 

 

 

 

 

 

 

 

 

Search Tutorials

Latest Questions
Comments
 
URL in term of Java Network Programming 
 

A URL (Uniform Resource Locator) is the address of a resource on the Internet.

 

URL in term of Java Network Programming

                         

A URL (Uniform Resource Locator) is the address of a resource on the Internet. In java network programming we can use URLs to connect and retrieve information over the Internet. In this section we will provide the complete information about the way of using URL in java network programming through a full code-example. The example give you the full exposure to network programming e.g. how to open a connection to a URL, how to retrieve information of a given URL.  
                                                                       
Now here we are provide a simple name structure of a URL which addresses the Java Web site hosted by roseindia:

In the above given URL structure there are two main components:

  • Protocol identifier
  • Resource name

In which there is a colon and two forward slashes between protocol identifier and the resource name. The protocol identifier is the name of the protocol which is used in the URL structure to get the resource. Here we use the http which is one of the protocols used to access different types of resources on the net. HTTP is mainly used to serve the hypertext documents.

The second part of the URL is resource name that is the complete address of the resource. The resource name contains one or more of the components listed in the following table :-

Host Name

The name of the machine on which the resource lives.

Filename

The pathname to the file on the machine.

Port Number

The port number to which to connect (typically optional).

Reference

A reference to a named anchor within a resource that usually identifies a specific location within a file (typically optional).

         
In the above given table of the URL structure, for many protocols the host name and the filename are required but in some times the port number and reference are optional.

   

                         

» View all related tutorials
Related Tags: c com forms server orm form network socket io sed request return opera ai for work wait to base pos

Leave your comment:

Name:

Email:

URL:

Title:

Comments:


Enter Code:

Audio Version
Reload Image
 

Note: Emails will not be visible or used in any way, and are not required. Please keep comments relevant. Any content deemed inappropriate or offensive may be edited and/or deleted.

No HTML code is allowed. Line breaks will be converted automatically. URLs will be auto-linked. Please use BBCode to format your text.

Add This Tutorial To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Training Courses
Tell A Friend
Your Friend Name
Software Solutions
Least Viewed
Most Rated
Recently Viewed
Search Tutorials

 

 
 

Home | JSP | EJB | JDBC | Java Servlets | WAP  | Free JSP Hosting  | Search Engine | News Archive | Jboss 3.0 tutorial | Free Linux CD's | Forum | Blogs

About Us | Advertising On RoseIndia.net  | Site Map

India News

Indian Software Development Company | iPhone Development Company in India | Flex Development Company in India | Java Training Delhi | Java Training at Noida |

Send your comments, Suggestions or Queries regarding this site at roseindia_net@yahoo.com.

Copyright © 2008. All rights reserved.