Ejemplo n.º 1
0
 /// <summary>
 /// constructor
 /// </summary>
 /// <param name="leftOperand">Left operand node.</param>
 /// <param name="rightOperand">Right operand node.</param>
 /// <param name="type">Type name of this item in the mathematical sense.</param>
 /// <param name="anOperator">Code of operator.</param>
 /// <param name="precedenceOverriden">True if the natural precedence of operators is
 /// overridden in the expression represented by this node of the expression tree.</param>
 public ExprBinaryOperator(ExprItem leftOperand, ExprItem rightOperand, string type,
                           OperatorKind anOperator, bool precedenceOverriden)
     : base(type, anOperator, precedenceOverriden)
 {
     this.LeftOperand  = leftOperand;
     this.RightOperand = rightOperand;
 }
Ejemplo n.º 2
0
 protected ExprOperator(string type, OperatorKind anOperator, bool precedenceOverriden)
     : base(type)
 {
     this.Operator            = anOperator;
     this.PrecedenceOverriden = precedenceOverriden;
 }
Ejemplo n.º 3
0
 protected ExprOperator(string type, OperatorKind anOperator, bool precedenceOverriden)
     : base(type)
 {
     this.Operator = anOperator;
     this.PrecedenceOverriden = precedenceOverriden;
 }
Ejemplo n.º 4
0
 /// <summary>
 /// constructor
 /// </summary>
 /// <param name="operand"> Operand node.</param>
 /// <param name="type">Type name of this item in the mathematical sense.</param>
 /// <param name="anOperator">Code of operator.</param>
 /// <param name="precedenceOverriden">True if the natural precedence of operators is 
 /// overridden in the expression represented by this node of the expression tree.</param>
 public ExprUnaryOperator(ExprItem operand, string type, OperatorKind anOperator, bool precedenceOverriden)
     : base(type, anOperator, precedenceOverriden)
 {
     this.Operand = operand;
 }
Ejemplo n.º 5
0
 protected void Validate(OperatorKind operatorKind)
 {
     Invariant(OperatorKind.ValidOperator(operatorKind.Value),
         string.Format(AmValidationStrings.XMustBeValidY, "OperatorKind.Value", "OperatorKind"));
 }
Ejemplo n.º 6
0
 /// <summary>
 /// constructor
 /// </summary>
 /// <param name="operand"> Operand node.</param>
 /// <param name="type">Type name of this item in the mathematical sense.</param>
 /// <param name="anOperator">Code of operator.</param>
 /// <param name="precedenceOverriden">True if the natural precedence of operators is
 /// overridden in the expression represented by this node of the expression tree.</param>
 public ExprUnaryOperator(ExprItem operand, string type, OperatorKind anOperator, bool precedenceOverriden)
     :
     base(type, anOperator, precedenceOverriden)
 {
     this.Operand = operand;
 }