mirror of
https://github.com/samsonjs/media.git
synced 2026-03-28 09:55:48 +00:00
Allow custom ExecutorService to be supplied to the Loader
This commit is contained in:
parent
3f49f5c157
commit
68e65ec884
1 changed files with 8 additions and 2 deletions
|
|
@ -214,8 +214,14 @@ public final class Loader implements LoaderErrorThrower {
|
|||
* component using the loader.
|
||||
*/
|
||||
public Loader(String threadNameSuffix) {
|
||||
this.downloadExecutorService =
|
||||
Util.newSingleThreadExecutor(THREAD_NAME_PREFIX + threadNameSuffix);
|
||||
this(Util.newSingleThreadExecutor(THREAD_NAME_PREFIX + threadNameSuffix));
|
||||
}
|
||||
|
||||
/**
|
||||
* @param downloadExecutorService An {@link ExecutorService} for supplying the loader's thread.
|
||||
*/
|
||||
public Loader(ExecutorService downloadExecutorService) {
|
||||
this.downloadExecutorService = downloadExecutorService;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
Loading…
Reference in a new issue