Preview deployment

class DataManager

extends

BaseManager
abstract
export abstract class DataManager<Key, Holds, Resolvable> extends BaseManager

Manages the API methods of a data model along with a collection of instances.

Constructors

constructor(
client: Client<true>
holds: Constructable<Holds>
)

Constructs a new instance of the DataManager class

Type Parameters

Key

Holds

Resolvable

readonly
cache : Collection<Key, Holds>

The cache of items for this manager.

readonly
client : Client

The client that instantiated this Manager

Inherited from: BaseManager

readonly
holds : Constructable<Holds>

The data structure belonging to this manager.

resolve(
idOrInstance: Holds
) : Holds

Resolves a data entry to a data Object.

Returns: An instance from this Manager

resolveId(
idOrInstance: Key | Holds
) : Key

Resolves a data entry to an instance id.

valueOf() : Collection<Key, Holds>