SafetyLocationStyle
public struct SafetyLocationStyleDefines the appearance and behavior of the safety location visualization on the route.
Important
Currently supported safety location types are:- SafetyLocation/SafetyLocationType/speedEnforcement
- SafetyLocation/SafetyLocationType/averageSpeed
- SafetyLocation/SafetyLocationType/mobileRiskZone
- SafetyLocation/SafetyLocationType/trafficLight
- SafetyLocation/SafetyLocationType/mobile
- SafetyLocation/SafetyLocationType/fixedDangerZone
Important
This is a Public Preview API. It may be changed or removed at any time.- 
                  init(speedCameraLineColor:speedCameraOutlineColor: dangerZoneLineColor: dangerZoneOutlineColor: lineWidth: outlineWidth: markerStyleByCategory: areMarkersVisible: ) Initializes SafetyLocationStylewith the given values.Throws StyleConfigurationError/invalidArgumentif:- lineWidthis an empty list, has duplicates or has values not greater than 0.
- outlineWidthis an empty list, has duplicates or has values not greater than 0.
 DeclarationSwift public init( speedCameraLineColor: UIColor = Defaults.speedCameraLineColor, speedCameraOutlineColor: UIColor = Defaults.speedCameraOutlineColor, dangerZoneLineColor: UIColor = Defaults.dangerZoneLineColor, dangerZoneOutlineColor: UIColor = Defaults.dangerZoneOutlineColor, lineWidth: [WidthScene] = Defaults.lineWidth, outlineWidth: [OutlineWidthScene] = Defaults.outlineWidth, markerStyleByCategory: [SafetyLocation.SafetyLocationType: MarkerStyle] = Defaults .markerStyleByCategory, areMarkersVisible: Bool = Defaults.areMarkersVisible ) throwsParametersspeedCameraLineColorThe color of the line for speed cameras representing zones. By default, speedCameraLineColoris used.speedCameraOutlineColorThe outline color of the line for speed cameras representing zones. By default, speedCameraOutlineColoris used.dangerZoneLineColorThe color of the line for danger zones. By default, dangerZoneLineColoris used.dangerZoneOutlineColorThe outline color of the line for danger zones. By default, dangerZoneOutlineColoris used.lineWidthThe width (in point units) of the line for safety location representing zones. By default, lineWidthis used. This parameter must be a non-empty list containing non-negative values for both the width and the zoom level where the width is used. Items in this list must not contain duplicated zoom level values.outlineWidthThe width (in point units) of the line’s outline for safety location representing zones. By default, outlineWidthis used. This parameter must be a non-empty list containing non-negative values for both the width and the zoom level where the width is used. Items in this list must not contain duplicated zoom level values.markerStyleByCategoryThe safety location’s marker style by category. By default, markerStyleByCategoryis used. If the marker style is missing for any of the supported safety locations, a default marker style will be used.areMarkersVisibleDetermines if the safety location markers are visible. By default, areMarkersVisibleis used.
- 
                  
                  Initializes SafetyLocationStylewith values fromDefaults.DeclarationSwift public init()
- 
                  
                  The color of the line for speed cameras representing zones. DeclarationSwift public let speedCameraLineColor: UIColor
- 
                  
                  The outline color of the line for speed cameras representing zones. DeclarationSwift public let speedCameraOutlineColor: UIColor
- 
                  
                  The color of the line for danger zones. DeclarationSwift public let dangerZoneLineColor: UIColor
- 
                  
                  The outline color of the line for danger zones. DeclarationSwift public let dangerZoneOutlineColor: UIColor
- 
                  
                  The width (in point units) of the line for safety location representing zones. This parameter must be a non-empty list containing non-negative values for both the width and the zoom level where the width is used. Items in this list must not contain duplicated zoom level values. DeclarationSwift public let lineWidth: [WidthScene]
- 
                  
                  The width (in point units) of the line’s outline for safety location representing zones. This parameter must be a non-empty list containing non-negative values for both the width and the zoom level where the width is used. Items in this list must not contain duplicated zoom level values. DeclarationSwift public let outlineWidth: [OutlineWidthScene]
- 
                  
                  The safety location’s marker style by category. If the marker style is missing for any of the supported safety locations, a default marker style will be used. DeclarationSwift public let markerStyleByCategory: [SafetyLocation.SafetyLocationType : MarkerStyle]
- 
                  
                  Determines if the safety location markers are visible. Default is true.DeclarationSwift public let areMarkersVisible: Bool
- 
                  
                  Represents the style used to display safety locations markers. Important This stylization API is intended to be used for only the turn-by-turn navigation.See moreImportant This is a Public Preview API. It may be changed or removed at any time.DeclarationSwift public struct TextStyle
- 
                  
                  Provides default values for SafetyLocationStyleproperties.See moreImportant This is a Public Preview API. It may be changed or removed at any time.DeclarationSwift public enum Defaults
- 
                  
                  A container for the start, end, and background images of safety location markers. Important This stylization API is intended to be used for only the turn-by-turn navigation.See moreImportant This is a Public Preview API. It may be changed or removed at any time.DeclarationSwift public struct MarkerStyle
 
         TomTom SDK for iOS (0.53.1)
 
          TomTom SDK for iOS (0.53.1)
         SafetyLocationStyle
          SafetyLocationStyle