Package com.saperion.ngc.util
Class URLUtil
- java.lang.Object
-
- com.saperion.ngc.util.URLUtil
-
public class URLUtil extends java.lang.Object
This class contains utility methods for URL related operations.
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static java.util.Map<java.lang.String,java.util.List<java.lang.String>>
buildQueryMapFromString(java.lang.String queryString)
static java.lang.String
buildQueryStringFromMapArray(java.util.Map<java.lang.String,java.lang.String[]> parameterMap)
static java.lang.String
buildQueryStringFromMapList(java.util.Map<java.lang.String,java.util.List<java.lang.String>> parameterMap)
static java.lang.String
getContextPath()
Returns the current URL of the Web Client without request path and query string.static java.lang.String
getCurrentUrl()
This method returns the current URL of the Web Client including server name, port, context path and query string.static java.lang.String
getQueryString()
Returns the query string from the current URL.
-
-
-
Method Detail
-
getCurrentUrl
public static java.lang.String getCurrentUrl()
This method returns the current URL of the Web Client including server name, port, context path and query string. This method can only be used form within ZK context.- Returns:
- current URL of the web client
-
getQueryString
public static java.lang.String getQueryString()
Returns the query string from the current URL. If no query string is present, an empty string is returned. The returned query string will begin with "?". This method can only be used form within ZK context.- Returns:
- current query string
-
getContextPath
public static java.lang.String getContextPath()
Returns the current URL of the Web Client without request path and query string. This method can only be used form within ZK context.- Returns:
- current url of the Web Client without request path and query string
-
buildQueryStringFromMapList
public static java.lang.String buildQueryStringFromMapList(java.util.Map<java.lang.String,java.util.List<java.lang.String>> parameterMap)
-
buildQueryStringFromMapArray
public static java.lang.String buildQueryStringFromMapArray(java.util.Map<java.lang.String,java.lang.String[]> parameterMap)
-
buildQueryMapFromString
public static java.util.Map<java.lang.String,java.util.List<java.lang.String>> buildQueryMapFromString(java.lang.String queryString)
-
-