TieredStoFactory
Factory generates information for a tiered sto entity
Hierarchy
Factory‹TieredSto, Params, UniqueIdentifiers›
↳ TieredStoFactory
Index
Constructors
constructor
Properties
Entity
cache
context
Methods
create
fetch
generateProperties
refresh
update
Constructors
constructor
+ new TieredStoFactory(context
: Context): TieredStoFactory
Overrides Factory.constructor
Create an instance of the tiered sto factory
Parameters:
Name
Type
context
Returns: TieredStoFactory
Properties
Entity
• Entity: EntityClass‹Params, UniqueIdentifiers›
Inherited from Factory.Entity
entity class that this Factory is in charge of generating and caching
cache
• cache: object
Inherited from Factory.cache
Type declaration:
[ key: string]: TieredSto | undefined
context
• context: Context
Inherited from Factory.context
Methods
create
▸ create(uid
: string, params
: Params): EntityType
Inherited from Factory.create
Get an entity from the cache. Creates it if it isn't cached, updates it if it is
Parameters:
Name
Type
Description
uid
string
unique identifier for the entity
params
constructor data for the entity
Returns: EntityType
fetch
▸ fetch(uid
: string): Promise‹EntityType›
Inherited from Factory.fetch
Get an entity from the cache. Fetches the necessary data to create it if it isn't cached, refreshes it if it is
Parameters:
Name
Type
Description
uid
string
unique identifier for the entity
Returns: Promise‹EntityType›
Protected
generateProperties
Protected
generateProperties▸ generateProperties(uid
: string): Promise‹object›
Overrides void
Parameters:
Name
Type
uid
string
Returns: Promise‹object›
refresh
▸ refresh(uid
: string): Promise‹void›
Inherited from Factory.refresh
Fetch the data for an entity and updates its properties
Parameters:
Name
Type
Description
uid
string
unique identifier for the entity
Returns: Promise‹void›
update
▸ update(uid
: string, params
: Partial‹Params›): Promise‹void›
Inherited from Factory.update
Update an entity's properties in place
Parameters:
Name
Type
Description
uid
string
unique identifier for the entity
params
properties that should be updated
Returns: Promise‹void›
Last updated
Was this helpful?