public ActiveDirectoryHelper(IRepository <Staff> staffRepository, IPrincipalManager principalManager) { #region Parameter validation // Validate parameters if (null == staffRepository) { throw new ArgumentNullException("staffRepository"); } if (null == principalManager) { throw new ArgumentNullException("principalManager"); } #endregion _staffRepository = staffRepository; _principalManager = principalManager; }
public TokenRequestHandler(IPrincipalManager principalManager) { _principalManager = principalManager ?? throw new System.ArgumentNullException(nameof(principalManager)); }