Class: WaypointDisplayBuilder
A class that builds a configuration for the waypoint display.
Hierarchy
WaypointDisplayBuilder
Constructors
constructor
• new WaypointDisplayBuilder(iconFactory
, labelFactory
, waypointRenderer
): WaypointDisplayBuilder
Creates an instance of the WaypointDisplayBuilder.
Parameters
Name | Type | Description |
---|---|---|
iconFactory | MapSystemIconFactory | The icon factory to use with this builder. |
labelFactory | MapSystemLabelFactory | The label factory to use with this builder. |
waypointRenderer | MapSystemWaypointsRenderer | The waypoint renderer to use with this builder. |
Returns
Defined in
src/sdk/components/mapsystem/WaypointDisplayBuilder.ts:23
Properties
facilityWaypointCache
• Protected
facilityWaypointCache: undefined
| FacilityWaypointCache
Defined in
src/sdk/components/mapsystem/WaypointDisplayBuilder.ts:15
iconFactory
• Protected
Readonly
iconFactory: MapSystemIconFactory
The icon factory to use with this builder.
Defined in
src/sdk/components/mapsystem/WaypointDisplayBuilder.ts:23
isCenterTarget
• Protected
isCenterTarget: boolean
= false
Defined in
src/sdk/components/mapsystem/WaypointDisplayBuilder.ts:14
labelFactory
• Protected
Readonly
labelFactory: MapSystemLabelFactory
The label factory to use with this builder.
Defined in
src/sdk/components/mapsystem/WaypointDisplayBuilder.ts:23
roleGroup
• Protected
roleGroup: string
= MapSystemWaypointRoles.Normal
Defined in
src/sdk/components/mapsystem/WaypointDisplayBuilder.ts:13
waypointRenderer
• Protected
Readonly
waypointRenderer: MapSystemWaypointsRenderer
The waypoint renderer to use with this builder.
Defined in
src/sdk/components/mapsystem/WaypointDisplayBuilder.ts:24
Methods
addDefaultIcon
▸ addDefaultIcon<T
>(role
, config
): this
Adds a default icon configuration to the waypoint display system, if no other configuration is found.
Type parameters
Name | Type |
---|---|
T | extends Waypoint |
Parameters
Name | Type | Description |
---|---|---|
role | string | number | The role to add this waypoint display config for. |
config | (waypoint : T ) => MapWaypointIcon <T > | The waypoint icon factory to add as a configuration. |
Returns
this
The modified builder.
Defined in
src/sdk/components/mapsystem/WaypointDisplayBuilder.ts:44
addDefaultLabel
▸ addDefaultLabel<T
>(role
, config
): this
Adds a label configuration to the waypoint display system.
Type parameters
Name | Type |
---|---|
T | extends Waypoint |
Parameters
Name | Type | Description |
---|---|---|
role | string | number | The role to add this waypoint display config for. |
config | (waypoint : T ) => MapCullableLocationTextLabel | The waypoint label factory to add as a configuration. |
Returns
this
The modified builder.
Defined in
src/sdk/components/mapsystem/WaypointDisplayBuilder.ts:67
addIcon
▸ addIcon<T
>(role
, type
, config
): this
Adds a icon configuration to the waypoint display system.
Type parameters
Name | Type |
---|---|
T | extends Waypoint |
Parameters
Name | Type | Description |
---|---|---|
role | string | number | The role to add this waypoint display config for. |
type | string | The type of waypoint to add an icon for. |
config | (waypoint : T ) => MapWaypointIcon <T > | The waypoint icon factory to add as a configuration. |
Returns
this
The modified builder.
Defined in
src/sdk/components/mapsystem/WaypointDisplayBuilder.ts:33
addLabel
▸ addLabel<T
>(role
, type
, config
): this
Adds a label configuration to the waypoint display system.
Type parameters
Name | Type |
---|---|
T | extends Waypoint |
Parameters
Name | Type | Description |
---|---|---|
role | string | number | The role to add this waypoint display config for. |
type | string | The type of waypoint to add an label for. |
config | (waypoint : T ) => MapCullableLocationTextLabel | The waypoint label factory to add as a configuration. |
Returns
this
The modified builder.
Defined in
src/sdk/components/mapsystem/WaypointDisplayBuilder.ts:56
getIsCenterTarget
▸ getIsCenterTarget(): boolean
Gets if the waypoint search is using the map target with offset as the search center.
Returns
boolean
True if the search center is the map target, false if it is the map center.
Defined in
src/sdk/components/mapsystem/WaypointDisplayBuilder.ts:138
getRoleId
▸ getRoleId(role
): number
Gets the ID of a role in the waypoint display system.
Parameters
Name | Type | Description |
---|---|---|
role | string | The name of the role to get the ID for. |
Returns
number
The ID of the role.
Throws
An error if an invalid role name is supplied.
Defined in
src/sdk/components/mapsystem/WaypointDisplayBuilder.ts:109
getWaypointCache
▸ getWaypointCache(): undefined
| FacilityWaypointCache
Gets the currently set facility waypoint cache.
Returns
undefined
| FacilityWaypointCache
The currently set facility waypoint cache.
Defined in
src/sdk/components/mapsystem/WaypointDisplayBuilder.ts:156
registerRole
▸ registerRole(name
): this
Registers a waypoint display role for use with the flight plan rendering system.
Parameters
Name | Type | Description |
---|---|---|
name | string | The name of the role to register. |
Returns
this
The modified builder.
Defined in
src/sdk/components/mapsystem/WaypointDisplayBuilder.ts:97
withSearchCenter
▸ withSearchCenter(center
): this
Configures the center for waypoint searches for this display.
Parameters
Name | Type | Description |
---|---|---|
center | "center" | "target" | If center, then waypoint searches will use the map center. If target, waypoint searches will use the map target with offset. |
Returns
this
The modified builder.
Defined in
src/sdk/components/mapsystem/WaypointDisplayBuilder.ts:124
withWaypointCache
▸ withWaypointCache(cache
): this
Configures the facility waypoint cache to use with the waypoint display.
Parameters
Name | Type | Description |
---|---|---|
cache | undefined | FacilityWaypointCache | The facility waypoint cache to use, or undefined to use the default. |
Returns
this
The modified builder.
Defined in
src/sdk/components/mapsystem/WaypointDisplayBuilder.ts:147