Class URLUtil

java.lang.Object
com.saperion.ngc.util.URLUtil

public class URLUtil extends Object
This class contains utility methods for URL related operations.
  • Method Details

    • getCurrentUrl

      public static 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 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 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 String buildQueryStringFromMapList(Map<String,List<String>> parameterMap)
    • buildQueryStringFromMapArray

      public static String buildQueryStringFromMapArray(Map<String,String[]> parameterMap)
    • buildQueryMapFromString

      public static Map<String,List<String>> buildQueryMapFromString(String queryString)