EncodedTransaction
A simple object implementing parts of the Transaction's class. It is used to keep track of modifications on a persistent index and to apply them all at once. This class is to be used only internally.
Constructor Summary
Public Constructor | ||
public |
Create a new IndexTransaction. |
Member Summary
Public Members | ||
public get |
modified: Map<string, *> |
|
public get |
removed: Set<string> |
|
public get |
tableName: string |
|
public get |
truncated: boolean |
Method Summary
Public Methods | ||
public |
get(key: string): * Get a value from the encoded transaction. |
|
public |
put(key: string, value: *) Put a key-value pair into the transaction. |
|
public |
remove(key: string) Remove a key-value pair from the transaction. |
|
public |
truncate() Empty the index transaction. |
Public Constructors
Public Members
public get modified: Map<string, *> source
public get removed: Set<string> source
public get tableName: string source
public get truncated: boolean source
Public Methods
public get(key: string): * source
Get a value from the encoded transaction.
Params:
Name | Type | Attribute | Description |
key | string | The key. |
Return:
* | value The value. |
public put(key: string, value: *) source
Put a key-value pair into the transaction.
Params:
Name | Type | Attribute | Description |
key | string | The key. |
|
value | * | The value. |
public remove(key: string) source
Remove a key-value pair from the transaction.
Params:
Name | Type | Attribute | Description |
key | string | The key to remove. |