Closed SpaceOgre closed 10 months ago
You could apply “Lambda Injection” to your MapperForDTO
and use ToDTO
directly within your queries.
If you need the “expanded” selectExpression
outside your query, you could use the InjectLambdaVisitor
somehow directly or play with the various Apply
methods.
I can play with it, but I’m on the road right now.
Hi, please feel free to close this if you feel I should ask this somewhere else.
Today I'm using LinqKit to be able to reuse some Expression for selecting from collections, but I would like if I could only use NeinLinq since I want the Apply feature of it. I have tried for a long time now, but I can't figure out how to translate this to NeinLinq:
Base expression that should be reused:
Code to use it for the specified entity:
Code for the second entity using the same base expression:
It might be that I'm just thinking about this the wrong way but any help would be appreciated.