|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.opencms.util.CmsUriSplitter
public class CmsUriSplitter
Splits an URI String into separate components.
An URI is splitted into a prefix, a anchor and a query part.
| Constructor Summary | |
|---|---|
CmsUriSplitter(String uri)
Creates a splitted URI using the default (not strict) parsing mode. |
|
CmsUriSplitter(String uri,
boolean strict)
Creates a splitted URI using the given parsing mode. |
|
| Method Summary | |
|---|---|
boolean |
equals(Object obj)
|
String |
getAnchor()
Returns the anchor part of the uri, for example someanchor,
or null if no anchor is available. |
String |
getPrefix()
Returns the prefix part of the uri, for example http://www.opencms.org/some/path/,
or null if no prefix is available. |
String |
getQuery()
Returns the query part of the uri, for example a=b&c=d,
or null if no query is available. |
String |
getUri()
Returns the URI String passed to this URI splitter. |
int |
hashCode()
|
boolean |
isErrorFree()
Returns true if the URI was parsed error free in 'strict' mode,
or if the simple mode was used. |
| Methods inherited from class java.lang.Object |
|---|
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CmsUriSplitter(String uri)
uri - the URI to split
public CmsUriSplitter(String uri,
boolean strict)
Using 'strict' parsing mode, all requirements for an URI are checked.
If 'strict' is set to false, then only some simple parsing rules are applied,
in which case the result may not be 100% valid (but still usable).
If 'strict' parsing generates an error, then simple parsing is used as a fallback.
uri - the URI to splitstrict - if true, then 'strict' parsing mode is used, otherwise a relaxed URI parsing is done| Method Detail |
|---|
public boolean equals(Object obj)
equals in class ObjectObject.equals(java.lang.Object)public String getAnchor()
someanchor,
or null if no anchor is available.
public String getPrefix()
http://www.opencms.org/some/path/,
or null if no prefix is available.
public String getQuery()
a=b&c=d,
or null if no query is available.
public String getUri()
public int hashCode()
hashCode in class ObjectObject.hashCode()public boolean isErrorFree()
true if the URI was parsed error free in 'strict' mode,
or if the simple mode was used.
true if the URI was parsed error free in 'strict' mode,
or if the simple mode was used
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||