Пример #1
0
  public static RequestMapping createOrRetrieveRequestMapping(String path, String... parameters) {

    for (RequestMapping requestMapping : Bennu.getInstance().getRequestMappingsSet()) {
      if (requestMapping.getPath().equals(path)) {
        if (Arrays.equals(requestMapping.getParameters().split("&"), parameters)) {
          return requestMapping;
        }
      }
    }

    return new RequestMapping(path, parameters);
  }