Package org.apache.cxf.common.util
Class UrlUtils
java.lang.Object
org.apache.cxf.common.util.UrlUtils
Utility class for decoding and encoding URLs
-
Method Summary
Modifier and TypeMethodDescriptionstatic String
Return everything in the path up to the last slash in a URI.Create a map from String to String that represents the contents of the query portion of a URL.static String
pathDecode
(String value) URL path segments may contain '+' symbols which should not be decoded into ' ' This method replaces '+' with %2B and delegates to URLDecoderstatic String
static String
Decodes using URLDecoder - use when queries or form post values are decodedstatic String
static String
-
Method Details
-
urlEncode
-
urlEncode
-
urlDecode
Decodes using URLDecoder - use when queries or form post values are decoded- Parameters:
value
- value to decodeenc
- encoding
-
urlDecode
-
pathDecode
URL path segments may contain '+' symbols which should not be decoded into ' ' This method replaces '+' with %2B and delegates to URLDecoder- Parameters:
value
- value to decode
-
parseQueryString
Create a map from String to String that represents the contents of the query portion of a URL. For each x=y, x is the key and y is the value.- Parameters:
s
- the query part of the URI.- Returns:
- the map.
-
getStem
Return everything in the path up to the last slash in a URI.- Parameters:
baseURI
-- Returns:
- the trailing
-