|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.exolab.jms.net.uri.URIHelper
Helper for operations on URIs.
URI
Method Summary | |
static URI |
convertHostToAddress(URI uri)
Helper to convert the host name portion of a URI to its corresponding IP address. |
static URI |
create(java.lang.String scheme,
java.lang.String host,
int port)
Helper to create an URI. |
static URI |
create(java.lang.String scheme,
java.lang.String host,
int port,
java.lang.String path)
Helper to create an URI. |
static URI |
create(java.lang.String scheme,
java.lang.String host,
int port,
java.lang.String path,
java.util.Map params)
Helper to create an URI. |
static URI |
create(java.lang.String scheme,
java.lang.String host,
int port,
java.lang.String path,
java.lang.String query)
Helper to create an URI. |
static org.exolab.jms.common.security.BasicPrincipal |
getPrincipal(URI uri)
Returns a BasicPrincipal corresponding to the user info specified
in a URI. |
static URI |
getURISansQuery(URI uri)
Returns a URI minus query/fragment. |
static URI |
parse(java.lang.String uri)
Helper to parse a String to an URI. |
static URI |
parse(java.lang.String uri,
java.lang.String scheme)
Helper to parse an URI, verifying that it has the correct scheme. |
static URI |
parseHostPort(java.lang.String uri,
java.lang.String scheme)
Helper to parse an URI, verifying that it has the correct scheme, host and port specification, and no path. |
static java.util.Map |
parseQuery(java.lang.String query)
Parse a query string. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Method Detail |
public static URI create(java.lang.String scheme, java.lang.String host, int port) throws InvalidURIException
scheme
- the URI schemehost
- the hostport
- the portInvalidURIException
- if any argument is invalidpublic static URI create(java.lang.String scheme, java.lang.String host, int port, java.lang.String path) throws InvalidURIException
scheme
- the URI schemehost
- the hostport
- the portpath
- the pathInvalidURIException
- if any argument is invalidpublic static URI create(java.lang.String scheme, java.lang.String host, int port, java.lang.String path, java.util.Map params) throws InvalidURIException
scheme
- the URI schemehost
- the hostport
- the portpath
- the pathparams
- a map of key/value pairs used to construct a query stringInvalidURIException
- if any argument is invalidpublic static URI create(java.lang.String scheme, java.lang.String host, int port, java.lang.String path, java.lang.String query) throws InvalidURIException
scheme
- the URI schemehost
- the hostport
- the portpath
- the pathquery
- the queryInvalidURIException
- if any argument is invalidpublic static URI parse(java.lang.String uri) throws InvalidURIException
"/"
.uri
- the URI to parseInvalidURIException
- if uri
is invalidpublic static URI parse(java.lang.String uri, java.lang.String scheme) throws InvalidURIException
uri
- the URI to parsescheme
- the expected schemeInvalidURIException
- if uri
is invalidpublic static URI parseHostPort(java.lang.String uri, java.lang.String scheme) throws InvalidURIException
uri
- the URI to parsescheme
- the expected schemeInvalidURIException
- if uri
is invalidpublic static URI convertHostToAddress(URI uri)
uri
- the uri to convertpublic static org.exolab.jms.common.security.BasicPrincipal getPrincipal(URI uri)
BasicPrincipal
corresponding to the user info specified
in a URI.uri
- the URI to get the user info fromnull
if none was specifiedpublic static URI getURISansQuery(URI uri)
uri
- the URIuri
if there is
no query/fragmentpublic static java.util.Map parseQuery(java.lang.String query) throws InvalidURIException
query
- the query to parseInvalidURIException
- if query
is invalid
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |