/** * The query string parameters to match on as a list of Parameter objects where the values or keys of each parameter can be either a string or a regex * (for more details of the supported regex syntax see http://docs.oracle.com/javase/6/docs/api/java/util/regex/Pattern.html) * * @param parameters the list of Parameter objects where the values or keys of each parameter can be either a string or a regex */ public HttpRequest withQueryStringParameters(List<Parameter> parameters) { this.queryStringParameters.withEntries(parameters); return this; }
/** * The query string parameters to match on as a Map<String, List<String>> where the values or keys of each parameter can be either a string or a regex * (for more details of the supported regex syntax see http://docs.oracle.com/javase/6/docs/api/java/util/regex/Pattern.html) * * @param parameters the Map<String, List<String>> object where the values or keys of each parameter can be either a string or a regex */ public HttpRequest withQueryStringParameters(Map<String, List<String>> parameters) { this.queryStringParameters.withEntries(parameters); return this; }
/** * The query string parameters to match on as a varags Parameter objects where the values or keys of each parameter can be either a string or a regex * (for more details of the supported regex syntax see http://docs.oracle.com/javase/6/docs/api/java/util/regex/Pattern.html) * * @param parameters the varags Parameter objects where the values or keys of each parameter can be either a string or a regex */ public HttpRequest withQueryStringParameters(Parameter... parameters) { this.queryStringParameters.withEntries(parameters); return this; }
public Parameters(Parameter... parameters) { withEntries(parameters); }
public Parameters(List<Parameter> parameters) { withEntries(parameters); }
public ParameterBody(Parameter... parameters) { this(new Parameters().withEntries(parameters)); }
public ParameterBody(List<Parameter> parameters) { this(new Parameters().withEntries(parameters)); }
public Parameters clone() { return new Parameters().withEntries(getEntries()); } }
private void setQueryString(HttpRequest httpRequest, HttpServletRequest httpServletRequest) { Parameters parameters = new Parameters(); if (StringUtils.isNotEmpty(httpServletRequest.getQueryString())) { parameters.withEntries(new QueryStringDecoder("?" + httpServletRequest.getQueryString()).parameters()); } httpRequest.withQueryStringParameters(parameters); }
private Parameters parseString(String matched) { return new Parameters().withEntries(new QueryStringDecoder("?" + matched).parameters()); }
private void setQueryString(HttpRequest httpRequest, QueryStringDecoder queryStringDecoder) { Parameters parameters = new Parameters(); try { parameters.withEntries(queryStringDecoder.parameters()); } catch (IllegalArgumentException iae) { mockServerLogger.error(httpRequest, "Exception while parsing query string", iae); } httpRequest.withQueryStringParameters(parameters); }
/** * The query string parameters to match on as a varags Parameter objects where the values or keys of each parameter can be either a string or a regex * (for more details of the supported regex syntax see http://docs.oracle.com/javase/6/docs/api/java/util/regex/Pattern.html) * * @param parameters the varags Parameter objects where the values or keys of each parameter can be either a string or a regex */ public HttpRequest withQueryStringParameters(Parameter... parameters) { this.queryStringParameters.withEntries(parameters); return this; }
/** * The query string parameters to match on as a list of Parameter objects where the values or keys of each parameter can be either a string or a regex * (for more details of the supported regex syntax see http://docs.oracle.com/javase/6/docs/api/java/util/regex/Pattern.html) * * @param parameters the list of Parameter objects where the values or keys of each parameter can be either a string or a regex */ public HttpRequest withQueryStringParameters(List<Parameter> parameters) { this.queryStringParameters.withEntries(parameters); return this; }
/** * The query string parameters to match on as a Map<String, List<String>> where the values or keys of each parameter can be either a string or a regex * (for more details of the supported regex syntax see http://docs.oracle.com/javase/6/docs/api/java/util/regex/Pattern.html) * * @param parameters the Map<String, List<String>> object where the values or keys of each parameter can be either a string or a regex */ public HttpRequest withQueryStringParameters(Map<String, List<String>> parameters) { this.queryStringParameters.withEntries(parameters); return this; }
public Parameters(Parameter... parameters) { withEntries(parameters); }
public Parameters(List<Parameter> parameters) { withEntries(parameters); }
public ParameterBody(Parameter... parameters) { this(new Parameters().withEntries(parameters)); }
private void setQueryString(HttpRequest httpRequest, HttpServletRequest httpServletRequest) { Parameters parameters = new Parameters(); if (StringUtils.isNotEmpty(httpServletRequest.getQueryString())) { parameters.withEntries(new QueryStringDecoder("?" + httpServletRequest.getQueryString()).parameters()); } httpRequest.withQueryStringParameters(parameters); }
public Parameters clone() { return new Parameters().withEntries(getEntries()); } }
private void setQueryString(HttpRequest httpRequest, QueryStringDecoder queryStringDecoder) { Parameters parameters = new Parameters(); try { parameters.withEntries(queryStringDecoder.parameters()); } catch (IllegalArgumentException iae) { mockServerLogger.error(httpRequest, "Exception while parsing query string", iae); } httpRequest.withQueryStringParameters(parameters); }