Skip to content

Tag Archives: Java-URL

URL is an acronym of Uniform resource locater. It is a pointer to locate resource in www (World Wide Web). A resource can be anything… Read More
Prior to discussing the differences lets quickly recap all three methods getPath() Method getAbsolutePath() Method getCanonicalPath() Method 1. getPath() Method getPath() is a method of… Read More
Given a URL as a character string str of size N.The task is to check if the given URL is valid or not.Examples :  Input… Read More
The getFile() function is a part of URL class. The function getFile() returns the file name of a specified URL. The getFile() function returns the… Read More
The getPath() function is a part of URL class. The function getPath() returns the Path name of a specified URL. Function Signature: public String getPath()… Read More
The getUserInfo() function is a part of URL class. The function getUserInfo() returns the UserInfo part of a specified URL. Function Signature: public String getUserInfo()… Read More
The getQuery() function is a part of URL class. The function getQuery() returns the Query of a specified URL. Function Signature: public String getQuery() Syntax:… Read More
The getRef() function is a part of URL class. The function getRef() returns the Reference or anchor part of a specified URL. Function Signature: public… Read More
The toExternalForm() function is a part of URL class. The function toExternalForm() returns the string representation of a specified URL. The string is created by… Read More
The getPort() function is a part of URL class. The function getPort() returns the port of a specified URL. The function returns the port number… Read More
The getProtocol() function is a part of URL class. The function getProtocol() returns the Protocol of a specified URL. Function Signature public String getProtocol() Syntax… Read More
The getAuthority() function is a part of URL class. The function getAuthority() returns the authority of a specified URL. The Authority part of the URL… Read More
getHost() function is a part of URL class. The function getHost() returns the Host of a specified URL. The Host part of the URL is… Read More
The getURI() function of URL class converts the URL object to a URI object. Any URL which compiles with RFC 2396 can be converted to… Read More
The sameFile() function of Java.net.URL class is used to compare two URLs excluding the fragment part. This method returns true if both the URL are… Read More