/** * Returns one parameter value. */ public ParameterValue getParameter(String name) { if (!getParameters().containsKey(name)) { return buildParameterValue(); } return getParameters().get(name); }
@Override public Map<String, String[]> getRequestParameters() { Map<String, ParameterValue> parameters = getRequest().getParameters(); final Map<String, String[]> result = new HashMap<>(); parameters.forEach((s, parameterValue) -> result.put(s, parameterValue.getValues())); return result; }
if (getParameters().containsKey(parameterName)) { if (!field.isAccessible()) { field.setAccessible(true); value = getParameters().get(parameterName).toSet(genericClass, pattern); } else if (List.class == fieldClass) { value = getParameters().get(parameterName).toList(genericClass, pattern); } else if (fieldClass.isInterface()) { throw new PippoRuntimeException("Field '{}' collection '{}' is not a supported type!", } else { Class<? extends Collection> collectionClass = (Class<? extends Collection>) fieldClass; value = getParameters().get(parameterName).toCollection(collectionClass, genericClass, pattern); value = getParameters().get(parameterName).to(fieldClass, pattern); value = getParameters().get(parameterName).convert(converterClass, pattern);