Quantcast
Viewing all articles
Browse latest Browse all 8156

Reflection.Emit or Pre-compiled Lambda Expression for PropertyDescriptor.SetValue/PropertyDescriptor.GetValue

Hi,

I have a library where I make these calls:
PropertyDescriptor.SetValue() and PropertyDescriptor.GetValue()

because I don't know the properties before run-time, and the properties are added on demand, usingTypeDescriptor.
The problem is that these calls are really slow. How do I emit these call with Reflection Emit (using IL directly), or use  Pre-compiled Lambda Expression to cache method delegate for these calls ?

Thanks in advance.



Viewing all articles
Browse latest Browse all 8156

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>