Beispiel #1
0
        public object Create(Type requestedType, ParamList constructorArguments = null, bool allowNonPublicConstructor = false)
        {
            ArgumentUtility.DebugCheckNotNull("requestedType", requestedType);

            constructorArguments = constructorArguments ?? ParamList.Empty;

            var typeID = _reflectionService.GetTypeIDForRequestedType(requestedType);

            return(_reflectionService.InstantiateAssembledType(typeID, constructorArguments, allowNonPublicConstructor));
        }