org.tm4j.net
Interface URILocator

All Superinterfaces:
Locator

public interface URILocator
extends Locator

Defines a locator that represents a Uniform Resource Identifier (URI).

Since:
0.6.0
Author:
Kal Ahmed
See Also:
URILocatorHelper

Method Summary
 java.lang.String getAuthority()
          Returns the authority associated with the URI.
 java.lang.String getFragment()
          Returns a string indicating an identifier of a fragment of the object that the URI represents.
 java.util.List getPath()
          Returns a list of strings composing the full path of the object that the URI represents.
 java.lang.String getPathString()
          Returns a string indicating the full path to the object that the URI represents.
 java.lang.String getQuery()
          Returns a query string associated with the object that the URI represents.
 java.lang.String getScheme()
          Returns the scheme associated with the URI.
 
Methods inherited from interface org.tm4j.net.Locator
copy, equals, getAddress, getFactory, getNotation, hashCode, initialise, resolveRelative, resolveRelative, setFactory
 

Method Detail

getScheme

public java.lang.String getScheme()
Returns the scheme associated with the URI. For an HTTP URL, this would be "http".

Returns:
A string representing the URI's scheme.

getAuthority

public java.lang.String getAuthority()
Returns the authority associated with the URI. For an HTTP URL, this would be a host name, e.g. "www.topicmaps.org".

Returns:
A string representing the URI's authority.

getPath

public java.util.List getPath()
Returns a list of strings composing the full path of the object that the URI represents. For an HTTP URL, this would be the list of directories, subdirectories, and the file name on the server.

Returns:
A list representing the URI's full path.

getPathString

public java.lang.String getPathString()
Returns a string indicating the full path to the object that the URI represents. For an HTTP URL, this would be a file path, e.g. "xtm/1.0/index.html".

Returns:
A string representing the URI's full path.

getQuery

public java.lang.String getQuery()
Returns a query string associated with the object that the URI represents. For an HTTP URL, this could be a set of CGI parameters, e.g. "id=358&display=print".

Returns:
A string representing the URI's query.

getFragment

public java.lang.String getFragment()
Returns a string indicating an identifier of a fragment of the object that the URI represents. For an HTTP URL, this could be an HTML document anchor, e.g. "elt-topic".

Returns:
A string representing the URI's object fragment.