예제 #1
0
 public AppNavItemController(
     ILogger <AppNavItemController> logger,
     IAppNavItemRepository repository
     )
 {
     this.logger     = logger ?? throw new ArgumentNullException(nameof(logger));
     this.repository = repository ?? throw new ArgumentNullException(nameof(repository));
 }
예제 #2
0
 protected override void Dispose(bool disposing)
 {
     if (disposing)
     {
         logger     = null;
         repository = null;
     }
     base.Dispose(disposing);
 }
예제 #3
0
 protected override void Dispose(bool disposing)
 {
     if (disposing)
     {
         logger        = null;
         userMgr       = null;
         roleMgr       = null;
         jwt           = null;
         navRepo       = null;
         cache         = null;
         userTokenRepo = null;
         usersCtrl     = null;
         privilegeRepo = null;
         commonOption  = null;
     }
     base.Dispose(disposing);
 }
예제 #4
0
 public AccountController(
     ILogger <AccountController> logger,
     UserManager <AppUser> userMgr,
     RoleManager <AppRole> roleMgr,
     IOptionsSnapshot <JwtOption> jwt,
     IAppNavItemRepository navRepo,
     IDistributedCache cache,
     IAppUserTokenRepository userTokenRepo,
     UsersController usersCtrl,
     IAppPrivilegeRepository privilegeRepo,
     CommonOption commonOption
     )
 {
     this.logger        = logger ?? throw new ArgumentNullException(nameof(logger));
     this.userMgr       = userMgr ?? throw new ArgumentNullException(nameof(userMgr));
     this.roleMgr       = roleMgr ?? throw new ArgumentNullException(nameof(roleMgr));
     this.jwt           = jwt.Value ?? throw new ArgumentNullException(nameof(jwt));
     this.navRepo       = navRepo ?? throw new ArgumentNullException(nameof(navRepo));
     this.cache         = cache ?? throw new ArgumentNullException(nameof(cache));
     this.userTokenRepo = userTokenRepo ?? throw new ArgumentNullException(nameof(userTokenRepo));
     this.usersCtrl     = usersCtrl ?? throw new ArgumentNullException(nameof(usersCtrl));
     this.privilegeRepo = privilegeRepo ?? throw new ArgumentNullException(nameof(privilegeRepo));
     this.commonOption  = commonOption ?? throw new ArgumentNullException(nameof(commonOption));
 }