public IKernel GetKernel(ResolverModuleType mType) { IKernel result; switch (mType) { case ResolverModuleType.Bl: { result = NiInjectKernel.GetBlKernel(); } break; case ResolverModuleType.Dal: { result = NiInjectKernel.GetDalKernel(); } break; case ResolverModuleType.Web: { result = NiInjectKernel.GetWebKernel(); } break; default: result = NiInjectKernel.GetWebKernel(); break; } return(result); }
public T ResolveByType <T>(ResolverModuleType mType) { return(GetKernel(mType).Get <T>()); }