public void validate(
      StreamTypeService streamTypeService,
      MethodResolutionService methodResolutionService,
      ViewResourceDelegate viewResourceDelegate,
      TimeProvider timeProvider,
      VariableService variableService,
      ExprEvaluatorContext exprEvaluatorContext)
      throws ExprValidationException {
    if (this.getChildNodes().size() < 2) {
      throw new ExprValidationException("MinMax node must have at least 2 child nodes");
    }
    evaluators = ExprNodeUtility.getEvaluators(this.getChildNodes());

    for (ExprEvaluator child : evaluators) {
      Class childType = child.getType();
      if (!JavaClassHelper.isNumeric(childType)) {
        throw new ExprValidationException(
            "Implicit conversion from datatype '"
                + childType.getSimpleName()
                + "' to numeric is not allowed");
      }
    }

    // Determine result type, set up compute function
    Class childTypeOne = evaluators[0].getType();
    Class childTypeTwo = evaluators[1].getType();
    resultType = JavaClassHelper.getArithmaticCoercionType(childTypeOne, childTypeTwo);

    for (int i = 2; i < this.getChildNodes().size(); i++) {
      resultType = JavaClassHelper.getArithmaticCoercionType(resultType, evaluators[i].getType());
    }

    ExprNode[] childNodes = this.getChildNodes().toArray(new ExprNode[this.getChildNodes().size()]);
    if (resultType == BigInteger.class) {
      SimpleNumberBigIntegerCoercer[] convertors =
          new SimpleNumberBigIntegerCoercer[childNodes.length];
      for (int i = 0; i < childNodes.length; i++) {
        convertors[i] = SimpleNumberCoercerFactory.getCoercerBigInteger(evaluators[i].getType());
      }
      computer =
          new MinMaxTypeEnum.ComputerBigIntCoerce(
              evaluators, convertors, (minMaxTypeEnum == MinMaxTypeEnum.MAX));
    } else if (resultType == BigDecimal.class) {
      SimpleNumberBigDecimalCoercer[] convertors =
          new SimpleNumberBigDecimalCoercer[childNodes.length];
      for (int i = 0; i < childNodes.length; i++) {
        convertors[i] = SimpleNumberCoercerFactory.getCoercerBigDecimal(evaluators[i].getType());
      }
      computer =
          new MinMaxTypeEnum.ComputerBigDecCoerce(
              evaluators, convertors, (minMaxTypeEnum == MinMaxTypeEnum.MAX));
    } else {
      if (minMaxTypeEnum == MinMaxTypeEnum.MAX) {
        computer = new MinMaxTypeEnum.MaxComputerDoubleCoerce(evaluators);
      } else {
        computer = new MinMaxTypeEnum.MinComputerDoubleCoerce(evaluators);
      }
    }
  }