public decimal MakeCalculation(decimal x, decimal y, OperationType type) { if (type == OperationType) { return(Calculate(x, y)); } if (Next != null) { return(Next.MakeCalculation(x, y, type)); } throw new Exception("Calculation not possible."); }