Package org.globus.util
Class GlobusURL
java.lang.Object
org.globus.util.GlobusURL
This class represents the URLs needed by various Globus services,
including:
- GASS
- GRAM
- FTP
- GSIFTP
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
Compares two urls.getHost()
Returns the host name of an url.getPath()
Returns the url path part of an url.int
getPort()
Returns the port number of an url.static int
Returns the protocol of an url.getPwd()
Returns the password of an url.getURL()
Returns the string representation of an url.getUser()
Returns the user name of an url.int
hashCode()
toString()
-
Field Details
-
protocol
-
host
-
urlPath
-
user
-
pwd
-
url
-
port
protected int port
-
-
Constructor Details
-
GlobusURL
Parses the url and extracts the url parts.- Parameters:
url
- the url to parse.- Throws:
MalformedURLException
- if the url is malformed.
-
GlobusURL
Creates a GlobusURL instance from URL instance.
Note: Not all the url parts are copied.
-
-
Method Details
-
getPort
-
getURL
Returns the string representation of an url.- Returns:
- the url as string.
-
getProtocol
Returns the protocol of an url.- Returns:
- the protocol part of the url.
-
getHost
Returns the host name of an url.- Returns:
- the host name part of the url.
-
getPort
public int getPort()Returns the port number of an url.- Returns:
- the port name of the url. -1 if the port was not specified.
-
getPath
Returns the url path part of an url.- Returns:
- the url path part of the url. Returns null if the url path is not specified.
-
getUser
Returns the user name of an url.- Returns:
- the user name if present in the url, otherwise returns null.
-
getPwd
Returns the password of an url.- Returns:
- the password if present in the url, otherwise returns null.
-
equals
Compares two urls. -
hashCode
public int hashCode() -
toString
-