Ejemplo n.º 1
0
            public ExpressionInfo(UncompiledExpression expr, CompiledDomain domain = null)
            {
                if (expr is UncompiledStandardExpression)
                {
                    var stdExpr = expr as UncompiledStandardExpression;
                    Expression = new StandardExpression(expr.Slot, expr.Type, stdExpr.Expression, domain);
                }
                else if (expr is UncompiledParametricExpression)
                {
                    var paraExpr = expr as UncompiledParametricExpression;
                    Expression = new ParametricExpression(expr.Slot, paraExpr.XExpression, paraExpr.YExpression, domain);
                }
                else
                {
                    throw new ArgumentException("expr");
                }

                OriginalUncompiled = expr;
                Enabled = true;
            }
 private bool Equals(UncompiledExpression other)
 {
     if (ReferenceEquals(null, other)) return false;
     if (ReferenceEquals(this, other)) return true;
     return Slot == other.Slot && Type == other.Type;
 }