Coordinator
To use RxDB, you need to attach the coordinator in your Electron browser process. It handles message dispatch across windows and manages the state of database files when they need to be created before use. Just import it and instantiate one:
import {Coordinator} from 'electron-rxdb';
global._coordinator = new Coordinator();
Constructor Summary
| Public Constructor | ||
| public |
|
|
Method Summary
| Public Methods | ||
| public |
deleteDatabase(databasePath: *, callback: *) |
|
| public |
deleteFileWithRetry(filePath: *, callback: *, retries: number) |
|
| public |
recoverFromFatalDatabaseError(databasePath: *) |
|
| public |
setPhase(phase: *) |
|
Public Constructors
public constructor source
Public Methods
public deleteDatabase(databasePath: *, callback: *) source
Params:
| Name | Type | Attribute | Description |
| databasePath | * | ||
| callback | * |
public deleteFileWithRetry(filePath: *, callback: *, retries: number) source
Params:
| Name | Type | Attribute | Description |
| filePath | * | ||
| callback | * |
|
|
| retries | number |
|
public recoverFromFatalDatabaseError(databasePath: *) source
Params:
| Name | Type | Attribute | Description |
| databasePath | * |
public setPhase(phase: *) source
Params:
| Name | Type | Attribute | Description |
| phase | * |