Class ModelCache

A singleton cache for parsed and loaded models, indexed by name

Constructors

Properties

Accessors

Methods

Constructors

Properties

cache: Map<string, Model>
_instance: ModelCache

Accessors

Methods

  • Add a model to the cache, using the model name as key

    Parameters

    Returns void

  • Return a model from the cache by name

    Parameters

    • name: string

      Name of model without extension

    • warn: boolean = true

      If true, log a warning if model not found

    Returns undefined | Model

Generated using TypeDoc