Methods Summary |
---|
public java.lang.String | getProtocol()Get the beginning of the locator string
up to but not including the first colon.
String protocol = "";
int colonIndex = locatorString.indexOf(':");
// $jdr: Should this throw an exception or
// return an empty string?
if( colonIndex != -1) {
protocol = locatorString.substring(0,colonIndex);
}
return protocol;
|
public java.lang.String | getRemainder()Get the MediaLocator string with the protocol removed.
String remainder = "";
int colonIndex = locatorString.indexOf(":");
if( colonIndex != -1) {
remainder = locatorString.substring(colonIndex + 1);
}
return remainder;
|
public java.net.URL | getURL()Get the URL associated with this MediaLocator .
if( url == null) {
url = new URL(locatorString);
}
return url;
|
public java.lang.String | toExternalForm()Create a string from the URL argument that can
be used to construct the MediaLocator .
return locatorString;
|
public java.lang.String | toString()Used for printing MediaLocators .
return locatorString;
|