Class: GduUserSettingManager
A manager for GDU user settings.
Implements
UserSettingManager
<GduAllUserSettingTypes
>
Constructors
constructor
• new GduUserSettingManager(bus
, gduDefsConfig
): GduUserSettingManager
Creates a new instance of GduUserSettingManager.
Parameters
Name | Type | Description |
---|---|---|
bus | EventBus | The event bus. |
gduDefsConfig | GduDefsConfig | A configuration object which defines GDU options. |
Returns
Defined in
src/workingtitle-instruments-g3x-touch/html_ui/Pages/VCockpit/Instruments/NavSystems/G3XTouch/Shared/Settings/GduUserSettings.ts:43
Properties
gduCount
• Readonly
gduCount: number
The number of GDUs supported by this manager.
Defined in
src/workingtitle-instruments-g3x-touch/html_ui/Pages/VCockpit/Instruments/NavSystems/G3XTouch/Shared/Settings/GduUserSettings.ts:32
Methods
getAliasedManager
▸ getAliasedManager(index
): UserSettingManager
<GduUserSettingTypes
>
Gets a manager for aliased GDU user settings for an indexed GDU.
Parameters
Name | Type | Description |
---|---|---|
index | number | The index of the GDU for which to get an aliased setting manager. |
Returns
UserSettingManager
<GduUserSettingTypes
>
A manager for aliased GDU user settings for the specified GDU.
Throws
RangeError if index
is less than 1 or greater than the number of GDUs supported by this manager.
Defined in
src/workingtitle-instruments-g3x-touch/html_ui/Pages/VCockpit/Instruments/NavSystems/G3XTouch/Shared/Settings/GduUserSettings.ts:100
getAllSettings
▸ getAllSettings(): UserSetting
<UserSettingValue
>[]
Returns
UserSetting
<UserSettingValue
>[]
Inherit Doc
Implementation of
UserSettingManager.getAllSettings
Defined in
src/workingtitle-instruments-g3x-touch/html_ui/Pages/VCockpit/Instruments/NavSystems/G3XTouch/Shared/Settings/GduUserSettings.ts:85
getSetting
▸ getSetting<K
>(name
): UserSetting
<NonNullable
<GduAllUserSettingTypes
[K
]>>
Type parameters
Name | Type |
---|---|
K | extends `gduAdcIndex_${number}_g3x` | `gduAhrsIndex_${number}_g3x` |
Parameters
Name | Type |
---|---|
name | K |
Returns
UserSetting
<NonNullable
<GduAllUserSettingTypes
[K
]>>
Inherit Doc
Implementation of
UserSettingManager.getSetting
Defined in
src/workingtitle-instruments-g3x-touch/html_ui/Pages/VCockpit/Instruments/NavSystems/G3XTouch/Shared/Settings/GduUserSettings.ts:75
mapTo
▸ mapTo<M
>(map
): UserSettingManager
<M
& GduAllUserSettingTypes
>
Type parameters
Name | Type |
---|---|
M | extends UserSettingRecord |
Parameters
Name | Type |
---|---|
map | UserSettingMap <M , GduAllUserSettingTypes > |
Returns
UserSettingManager
<M
& GduAllUserSettingTypes
>
Inherit Doc
Implementation of
UserSettingManager.mapTo
Defined in
src/workingtitle-instruments-g3x-touch/html_ui/Pages/VCockpit/Instruments/NavSystems/G3XTouch/Shared/Settings/GduUserSettings.ts:90
tryGetSetting
▸ tryGetSetting<K
>(name
): K
extends `gduAdcIndex_${number}_g3x` | `gduAhrsIndex_${number}_g3x` ? UserSetting
<GduAllUserSettingTypes
[K
]> : undefined
Type parameters
Name | Type |
---|---|
K | extends string |
Parameters
Name | Type |
---|---|
name | K |
Returns
K
extends `gduAdcIndex_${number}_g3x` | `gduAhrsIndex_${number}_g3x` ? UserSetting
<GduAllUserSettingTypes
[K
]> : undefined
Inherit Doc
Implementation of
UserSettingManager.tryGetSetting
Defined in
src/workingtitle-instruments-g3x-touch/html_ui/Pages/VCockpit/Instruments/NavSystems/G3XTouch/Shared/Settings/GduUserSettings.ts:70
whenSettingChanged
▸ whenSettingChanged<K
>(name
): Consumer
<NonNullable
<GduAllUserSettingTypes
[K
]>>
Type parameters
Name | Type |
---|---|
K | extends `gduAdcIndex_${number}_g3x` | `gduAhrsIndex_${number}_g3x` |
Parameters
Name | Type |
---|---|
name | K |
Returns
Consumer
<NonNullable
<GduAllUserSettingTypes
[K
]>>
Inherit Doc
Implementation of
UserSettingManager.whenSettingChanged
Defined in
src/workingtitle-instruments-g3x-touch/html_ui/Pages/VCockpit/Instruments/NavSystems/G3XTouch/Shared/Settings/GduUserSettings.ts:80