The API.RWS namespace is an extension to the Omnicore SDK.
- Source
Classes
Namespaces
Methods
checkIfHeldMastership(type) → {Promise.<boolean>}
Checks if held the mastership.
Parameters:
| Name | Type | Description |
|---|---|---|
type | string | The mastership type, which can be 'edit' or 'motion'. |
- Source
Returns:
- Type:
- Promise.<boolean>
Example
// check if holding edit mastership
await API.RWS.checkIfHeldMastership()(async) executeWithMastership(args, func, type) → {Promise.<any>}
Executes the function with holding the specified mastership.
Parameters:
| Name | Type | Description |
|---|---|---|
args | any | The arguments for function calling. |
func | function | The function to be called. |
type | MastershipType | The mastership type, which can be 'edit' or 'motion'. |
- Source
Returns:
- Type:
- Promise.<any>
getMastershipState(type) → {Promise.<object>}
Parameters:
| Name | Type | Description |
|---|---|---|
type | string | The mastership type, which can be 'edit' or 'motion'. |
- Source
Returns:
- Type:
- Promise.<object>
releaseMastership(type) → {Promise.<any>}
Parameters:
| Name | Type | Default | Description |
|---|---|---|---|
type | MastershipType | edit | The mastership type, which can be 'edit' or 'motion'. |
- Source
Returns:
- Type:
- Promise.<any>
Example
API.RWS.releaseMastership('edit')requestMastership(type) → {Promise.<any>}
Parameters:
| Name | Type | Default | Description |
|---|---|---|---|
type | MastershipType | edit | The mastership type, which can be 'edit' or 'motion'. |
- Source
Returns:
- Type:
- Promise.<any>
Example
API.RWS.requestMastership('edit')Type Definitions
MastershipType
Type:
- 'edit' |
'motion'
- Source