Exemplo n.º 1
0
 protected MathOperator(MathToken token, int precedence, ICalculatorProxy proxy, CalculatorProxy.SingleBinaryOperation operation)
     : base(token.Token, token.Index)
 {
     this.Precedence = precedence;
     this.proxy = proxy;
     this.operation = operation;
 }
Exemplo n.º 2
0
 public DivideOperator(MathToken token, ICalculatorProxy proxy, ICalculator calculator)
     : base(token, 2, proxy, calculator.Divide)
 {
 }
Exemplo n.º 3
0
 public MultiplyOperator(MathToken token, ICalculatorProxy proxy, ICalculator calculator)
     : base(token, 2, proxy, calculator.Multiply)
 {
 }
Exemplo n.º 4
0
 public OperatorFactory(ICalculatorProxy proxy, ICalculator calculator)
 {
     this.proxy = proxy;
     this.calculator = calculator;
 }
Exemplo n.º 5
0
 public AddOperator(MathToken token, ICalculatorProxy proxy, ICalculator calculator)
     : base(token, 1, proxy, calculator.Add)
 {
 }
Exemplo n.º 6
0
 public SubstractOperator(MathToken token, ICalculatorProxy proxy, ICalculator calculator)
     : base(token, 1, proxy, calculator.Substract)
 {
 }