This commit is contained in:
sunkaixuan
2017-01-14 20:44:17 +08:00
parent 1a5f662a0a
commit e6422a5792
18 changed files with 41 additions and 12 deletions

View File

@@ -28,11 +28,21 @@ namespace OrmTest.ExpressionTest
private static void Multiple()
{
Expression<Func<Student,School, object>> exp = (it,school) => new Student() { Name = "a", Id = it.Id, SchoolId = school.Id };
ExpressionContext expContext = new ExpressionContext(exp, ResolveExpressType.WhereSingle);
expContext.ResolveType = ResolveExpressType.SelectMultiple;
expContext.Resolve();
var selectorValue = expContext.Result.GetString();
var pars = expContext.Parameters;
}
private static void MultipleDynamic()
{
Expression<Func<Student, School, object>> exp = (it, school) => new{ Name = "a", Id = it.Id, SchoolId = school.Id };
ExpressionContext expContext = new ExpressionContext(exp, ResolveExpressType.WhereSingle);
expContext.ResolveType = ResolveExpressType.SelectMultiple;
expContext.Resolve();
var selectorValue = expContext.Result.GetString();
var pars = expContext.Parameters;
}
private static void single()
{

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.