示例#1
0
 public IActionResult Index([FromServices] IMyDepedencyService my_DepedencyService)
 {
     //_depedencyService.WriteMessage("this is from index method");
     return(View());
     //return Unauthorized();
     //sreturn Content("IndexPage");
 }
示例#2
0
 public HomeController(ILogger <HomeController> logger, IHostEnvironment hostEnvironment,
                       IMyDepedencyService depedencyService, IMyDepedencyService myDepedencyService)
 {
     _hostEnvironment = hostEnvironment;
     _logger          = logger;
     //depedencyService = new MyDepedencyService();
     _depedencyService = depedencyService;
 }