Compiled query using list of class objects in C#
Posted
by Sukan
on Stack Overflow
See other posts from Stack Overflow
or by Sukan
Published on 2010-03-23T11:32:49Z
Indexed on
2010/04/07
9:13 UTC
Read the original article
Hit count: 316
Hello ,
Can somebody help me out in creating compiled queries where input is to be a list of class objects? I have seen examples where Func<DataContext, somematchobject, IQueryable<T>> is created and compiled.
But can I do something like Func<List<T>, matchObject, T>, and compile it?
Basically I want an object(T) meeting certain conditions (as in matchObject) to be returned from a list of objects(List<T>).
Will CompiledQuery.Compile help me in this?
Please help me experts!!
© Stack Overflow or respective owner