C# 클래스 Munq.CreateInstanceDelegateFactory

This class provides a method to build a delegate to create a specified type. It is used by Register<TType, TImp>() to build the Func<IDependencyResolver, TImp> need to create the instance to be returned. Also used by the Resolve methods if the type requested is a class, not an interface, and is not currently Registered in the container.
파일 보기 프로젝트 열기: volkanceylan/Serenity 1 사용 예제들

공개 메소드들

메소드 설명
Create ( Type tImpl ) : object>.Func

Build a delegate to return an instance of the specified type given an instance of IocContainer. Finds the public constructor with the most parameters. The resulting method calls the container to resolve each parameter in the constructor.

비공개 메소드들

메소드 설명
BuildExpression ( Type type, System.Linq.Expressions.ParameterExpression container ) : NewExpression
GetConstructorInfo ( Type implType ) : ConstructorInfo

메소드 상세

Create() 공개 정적인 메소드

Build a delegate to return an instance of the specified type given an instance of IocContainer. Finds the public constructor with the most parameters. The resulting method calls the container to resolve each parameter in the constructor.
public static Create ( Type tImpl ) : object>.Func
tImpl System.Type The class to be resolved.
리턴 object>.Func