How can I imitate the functionality of the ExpandoObject in a .NET 3.5 application with the least overhead? My best lead so far is to use the Lin Fu framework ( http://www.codeproject.com/KB/cs/LinFuPart2.aspx ), but I'm thinking there may be something better.
To give a better idea of what I am going for here, my objective is to dynamically create the type from the parameters of a MethodInfo
. So, basically I want to turn this:
public class ServiceObject
{
public void Execute(string TransformMeIntoAProperty);
}
into
public class ServiceObjectExecuteSignature
{
public string TransformMeIntoAProperty{ get; set;}
}
at runtime. I have to be able to access the Parameters using Reflection, because I am using Linq Expressions.