Example #1
0
  /** Returns the applicable methods if the URL matches. */
  public ArrayList<String> getMethods(String url) {
    for (int i = 0;
        _webResourceCollectionList != null && i < _webResourceCollectionList.size();
        i++) {
      WebResourceCollection resource = _webResourceCollectionList.get(i);

      if (resource.isMatch(url)) return resource.getMethods();
    }

    return null;
  }
Example #2
0
  /** Returns true if the URL matches. */
  public boolean isMatch(String url) {
    if (_regexp != null && _regexp.matcher(url).find()) {
      return true;
    }

    for (int i = 0;
        _webResourceCollectionList != null && i < _webResourceCollectionList.size();
        i++) {
      WebResourceCollection resource = _webResourceCollectionList.get(i);

      if (resource.isMatch(url)) return true;
    }

    return false;
  }