While Activator.CreateInstance is convenient, .NET 4.6.1 offers alternative methods for object creation. Each method strikes a different balance between flexibility and execution speed. 1. Direct Constructor Invoke (Reflection)
Creating objects based on type information found in a serialized stream. Key Methods and Examples activators dotnet 4.6.1
Used primarily by formatters and deserializers, FormatterServices.GetUninitializedObject allocates memory for an object without running its constructor. While Activator
var paramExpr = Expression.Parameter(typeof(object[]), "args"); var argExprs = ctor.GetParameters().Select((p, i) => Expression.Convert(Expression.ArrayIndex(paramExpr, Expression.Constant(i)), p.ParameterType)); var newExpr = Expression.New(ctor, argExprs); var lambda = Expression.Lambda<Func<object[], object>>(newExpr, paramExpr); return lambda.Compile(); While Activator.CreateInstance is convenient