|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.mobicents.servlet.sip.address.RFC2396UrlDecoder
public class RFC2396UrlDecoder
Copied from Apache Excalibur project. Source code available at http://www.google.com/codesearch?hl=en&q=+excalibur+decodePath+show:sK_gDY0W5Rw:OTjCHAiSuF0:th3BdHtpX20&sa=N&cd=1&ct=rc&cs_p=http://apache.edgescape.com/excalibur/excalibur-sourceresolve/source/excalibur-sourceresolve-1.1-src.zip&cs_f=excalibur-sourceresolve-1.1/src/java/org/apache/excalibur/source/SourceUtil.java
| Constructor Summary | |
|---|---|
RFC2396UrlDecoder()
|
|
| Method Summary | |
|---|---|
static java.lang.String |
decode(java.lang.String uri)
Decode a path. |
static java.lang.String |
encode(java.lang.String s)
Translates a string into x-www-form-urlencoded format. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public RFC2396UrlDecoder()
| Method Detail |
|---|
public static java.lang.String encode(java.lang.String s)
x-www-form-urlencoded format.
s - String to be translated.
String.public static java.lang.String decode(java.lang.String uri)
Interprets %XX (where XX is hexadecimal number) as UTF-8 encoded bytes.
The validity of the input path is not checked (i.e. characters that were not encoded will not be reported as errors).
This method differs from URLDecoder.decode in that it always uses UTF-8 (while URLDecoder uses the platform default encoding, often ISO-8859-1), and doesn't translate + characters to spaces.
uri - the path to decode
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||