class PagingUtil {

  public static Map<String, String> parseLinkHeader(String linkHeader) {
    if (isNullOrEmpty(linkHeader)) {
      return emptyMap();
    }
    final Map<String, String> res = new HashMap<>();
    for (String part : linkHeader.split(LINK_HEADER_SEPARATOR)) {
      final Matcher matcher = LINK_HEADER_REGEX.matcher(part);
      if (matcher.matches()) {
        res.put(matcher.group("rel"), matcher.group("href"));
      }
    }
    return res;
  }

  private  PagingUtil();

}