Exemplo n.º 1
0
  public Object parse(Expression<?> path, ConditionOperator conditionOperator, JsonNode fieldValue)
      throws QueryInfoException {
    Object result;
    Class<?> javaType = path.getJavaType();

    boolean isEitherInOperator = ConditionOperator.isEitherInOperator(conditionOperator);

    if (isEitherInOperator) {
      result = parseIn(path, fieldValue);
    } else if (Date.class.isAssignableFrom(javaType)) {
      result = parseDate(fieldValue);
    } else {
      result = parseType(fieldValue, javaType);
    }

    return result;
  }