public static String getServletPathFromLocation(final HttpServletRequest request, final String location) {
    return location.replace(getPathInfoFromLocation(request, location), StringUtils.EMPTY);
  }
public static String getServletPathFromLocation(final HttpServletRequest request, final String location) {
    return location.replace(getPathInfoFromLocation(request, location), StringUtils.EMPTY);
  }
public static String getServletPathFromLocation ( final HttpServletRequest request , final String location ) { return location . replace ( getPathInfoFromLocation ( request , location ) , StringUtils . EMPTY ) ; }
Retrieve servletPath from a given location.

@param location
where to search the servletPath.
@return ServletPath string value.
Retrieve servletPath from a given location .