Java URL toExternalfile() Method

The toExternalfile() method of URL class converts this URL object into a string representation. By calling this method of the stream protocol handler String is created.

Syntax

Returns

A string representation of this object.

Example 1

Output:

http://www.java2s.com/a.htm
.....String repesentation of URL... 
 http://www.java2s.com/a.htm
Next TopicJava URL Class




Latest Courses