LocalModel
Extends:
Constructor Summary
Public Constructor | ||
public |
constructor(id: *, data: *) |
Inherited Summary
From class PrioritisedObject | ||
public get |
dataSource: * |
|
public get |
id: * |
|
public set |
id: * |
|
public get |
priority: * Priority (positioning) of the object in the dataSource |
|
public set |
priority: * |
|
public |
disableChangeListener(): void Disables pushes of local changes to the dataSource, and stops event emits that refer to the model's data. |
|
public |
enableChangeListener(): void Enables pushes of local changes to the dataSource, and enables event emits that refer to the model's data. The change listener is active by default, so you'll only need to call this method if you've previously called disableChangeListener(). |
|
public |
Removes subscription to events emitted by this PrioritisedArray. |
|
public |
Subscribes to events emitted by this PrioritisedArray. |
|
public |
Subscribes to the given event type exactly once; it automatically unsubscribes after the first time it is triggered. |
|
public |
remove(): void Deletes the current object from the dataSource, and clears itself to free memory. |
|
public |
transaction(method: Function): void Allows multiple modifications to be made to the model without triggering dataSource pushes and event emits for each change. |
From class Model | ||
public |
Check if the model has been synchonized with the database |
Public Constructors
public constructor(id: *, data: *) source
Override:
Model#constructorParams:
Name | Type | Attribute | Description |
id | * | ||
data | * |