Esempio n. 1
0
        private void TestCastToString(Char?x, String expectedValue)
        {
            _Char   column1 = x;
            _String expr    = column1.CastToString();
            var     dbExpr  = (DbCastExpression)expr.DbExpression;

            dbExpr.Verify(column1, typeof(Char?), typeof(String));
            expr.VerifyEval(expectedValue);
        }
Esempio n. 2
0
        private void TestFromChar(Char?x, WeekDay?expectedValue)
        {
            _Char column1 = x;
            var   expr    = (_CharEnum <WeekDay>)column1;
            var   dbExpr  = (DbCastExpression)expr.DbExpression;

            dbExpr.Verify(column1, typeof(Char?), typeof(WeekDay?));
            expr.VerifyEval(expectedValue);
        }
Esempio n. 3
0
        private void TestFromString(String x, Char?expectedValue)
        {
            _String column1 = x;
            _Char   expr    = (_Char)column1;
            var     dbExpr  = (DbCastExpression)expr.DbExpression;

            dbExpr.Verify(column1, typeof(String), typeof(Char?));
            expr.VerifyEval(expectedValue);
        }
Esempio n. 4
0
        private void TestLessThan(Char?x, Char?y, bool?expectedValue)
        {
            _Char column1 = x;
            _Char column2 = y;
            var   expr    = column1 < column2;
            var   dbExpr  = (DbBinaryExpression)expr.DbExpression;

            dbExpr.Verify(BinaryExpressionKind.LessThan, column1, column2);
            expr.VerifyEval(expectedValue);
        }
Esempio n. 5
0
        private void TestGreaterThanOrEqual(Char?x, Char?y, bool?expectedValue)
        {
            _Char column1 = x;
            _Char column2 = y;
            var   expr    = column1 >= column2;
            var   dbExpr  = (DbBinaryExpression)expr.DbExpression;

            dbExpr.Verify(BinaryExpressionKind.GreaterThanOrEqual, column1, column2);
            expr.VerifyEval(expectedValue);
        }
Esempio n. 6
0
        private static void TestConst(char?x)
        {
            _Char column = _Char.Const(x);

            column.VerifyConst(x);
        }
Esempio n. 7
0
        private void TestImplicit(Char?x)
        {
            _Char column = x;

            column.VerifyParam(x);
        }
Esempio n. 8
0
        private void TestParam(Char?x)
        {
            _Char column = _Char.Param(x);

            column.VerifyParam(x);
        }
Esempio n. 9
0
 /// <summary>Creates a column of parameter expression.</summary>
 /// <param name="x">The value of the parameter expression.</param>
 /// <param name="sourceColumn">The value which will be passed to <see cref="DbParamExpression.SourceColumn"/>.</param>
 /// <returns>The column of parameter expression.</returns>
 public static _Char Param(Char?x, _Char sourceColumn = null)
 {
     return(new ParamExpression <Char?>(x, sourceColumn).MakeColumn <_Char>());
 }