Esempio n. 1
0
 public expression(Ioperand ol, comparisonoperator _opdef, Ioperand or)
 {
     /* binary operation */
     operand_l = ol;
     opdef     = _opdef;
     operand_r = or;
 }
Esempio n. 2
0
        public Ioperand operand_r; /* null for non-binary operators */

        public expression(Ioperand ol, comparisonoperator _opdef)
        {
            /* unary: only limited subset of possible operators */
            switch (_opdef)
            {
            case comparisonoperator.coIsnull:
            case comparisonoperator.coNotnull:
            case comparisonoperator.coHastext:
            case comparisonoperator.coHasNoText:
            case comparisonoperator.coExists:
            case comparisonoperator.coNotExists:
                break;

            default:
                throw new ArgumentOutOfRangeException(String.Format("_opdef '{0}' asks for two operands", _opdef.ToString()));
            }
            operand_l = ol;
            opdef     = _opdef;
            /* [rzamponi 20100112] FxCop CA1805:DoNotInitializeUnnecessarily */
            //operand_r = null;
        }
Esempio n. 3
0
 public selectfield(selectfunctiondef func, expression expression, string rowsource_consumeralias, Ioperand literalconst, string fieldname, string asname, selectstatement subqry, sortorder order)
 {
     /* [rzamponi 20100112] FxCop CA1805:DoNotInitializeUnnecessarily */
     //if (func == selectfunctiondef.none) Function = null; else Function = new selectfunction(func);
     if (func != selectfunctiondef.none)
     {
         Function = new selectfunction(func);
     }
     Expression             = expression;
     RowsourceConsumerAlias = rowsource_consumeralias;
     literal   = literalconst;
     Fieldname = fieldname;
     AsName    = asname;
     subquery  = subqry;
     if (order == sortorder.so_asc)
     {
         Ascending = true;
     }
     else if (order == sortorder.so_desc)
     {
         Descending = true;
     }
 }
Esempio n. 4
0
 public selectfield(selectfunctiondef func, string rowsource_consumeralias, Ioperand literalconst, string fieldname, string asname, selectstatement subqry, sortorder order) : this(func, null, rowsource_consumeralias, literalconst, fieldname, asname, subqry, order)
 {
 }