Class ReferenceCollection<K, V>

Asynchronous implementation of AbstractReferenceCollection that requires the client to provide a value factory, used to service the acquire() function. That factory may return a Promise if the value cannot be created immediately.

Type Parameters

Hierarchy (view full)

Constructors

Properties

_keys: Map<string, K> = ...
_values: Map<string, V> = ...
factory: ((key) => MaybePromise<V>)

Type declaration

onDidCreate: Event<V> = ...
onDidCreateEmitter: Emitter<V> = ...
onWillDispose: Event<V> = ...
onWillDisposeEmitter: Emitter<V> = ...
pendingValues: Map<string, MaybePromise<V>> = ...
references: Map<string, DisposableCollection> = ...
toDispose: DisposableCollection = ...

Methods