Methods
(async) applySnapshot(snapshot) → {Promise.<any>}
Restores an application to a given snapshot.
Will overwrite current layout state with that of a snapshot.
The function accepts snapshots taken using getSnapshot
Parameters:
Name | Type | Description |
---|---|---|
snapshot |
any | Snapshot to apply |
- Tutorials:
Returns:
- Type
- Promise.<any>
(async) closeLayout() → {Promise.<any>}
Closes current layout, all its windows, and their views.
- Tutorials:
Returns:
- Type
- Promise.<any>
(async) closeView(viewIdentity, target) → {Promise.<any>}
Closes a specified view in a target window.
Parameters:
Name | Type | Description |
---|---|---|
viewIdentity |
Identity | View identity |
target |
Identity | Owner window identity |
- Tutorials:
Returns:
- Type
- Promise.<any>
(async) createView(viewOptions, target) → {Promise.<any>}
Creates a new view and attaches it to a specified target window.
Parameters:
Name | Type | Description |
---|---|---|
viewOptions |
ViewCreationOptions | View creation options |
target |
Identity | The window to which the new view is to be attached |
- Tutorials:
Returns:
- Type
- Promise.<any>
(async) createWindow(options) → {Promise.<_Window>}
Creates a new Window.
Parameters:
Name | Type | Description |
---|---|---|
options |
Window~options | Window creation options |
- Tutorials:
Returns:
- Type
- Promise.<_Window>
(async) getSnapshot() → {Promise.<any>}
Returns a snapshot of the layout in its current state.
Can be used to restore an application to a previous state.
- Tutorials:
Returns:
- Type
- Promise.<any>