示例#1
0
 public SpotifySortWorker(ILogger <SpotifySortWorker> logger,
                          IOptions <SpotifySortOptions> sortOptions,
                          IOptions <SpotifyAuthentication> authOptions,
                          ISpotifySort sorter,
                          IServiceScopeFactory scopeFactory)
 {
     this.logger       = logger;
     this.sortOptions  = sortOptions.Value;
     this.authOptions  = authOptions.Value;
     this.sorter       = sorter;
     this.localIp      = this.authOptions.CallbackIp;
     this.semaphore    = new SemaphoreSlim(1, 1);
     this.scopeFactory = scopeFactory;
 }
示例#2
0
 public SorterController(ILogger <SorterController> logger, ISpotifyContext spotifyContext, ISpotifySort spotifySorter)
 {
     this.logger         = logger;
     this.spotifyContext = spotifyContext;
     this.spotifySorter  = spotifySorter;
 }