Skip to main content

class

ActivityTracker​

Extends: Hashable
public static func == (lhs: ActivityTracker, rhs: ActivityTracker) -> Bool

Returns a Boolean value indicating whether two values are equal.
This documentation comment was inherited from .

public convenience init(
platformContext: Context,
model: Model,
speedBound: Double = 4.2,
timeThreshold: TimeInterval = 20
)

Navigation extension that monitors user activity and gives a signal when the user has stopped using the navigator and it can be turned off.

Parameters

platformContext

Context.

model

Model of the navigator status of which is being tracked.

speedBound

Upper limit of speed in m/s, if exceeded in the Finished state of the navigator, it is considered that the navigator is active, i.e. the movement continues.

timeThreshold

TimeInterval

Time during which in the Finished state of the navigator the speed is tracked below the threshold for determining the inactive state of the navigator. If during this time the speed is less than the set threshold or there is no location and speed data, the navigator is considered inactive.

Methods
public func hash(into hasher: inout Hasher)

Hashes the essential components of this value by passing them to the given hasher.

Parameters

hasher

Hasher

Hasher to use when combining the components of this instance.

Properties

var stopChannel​

StatefulChannel<Bool>

Flag the active state of which indicates that the navigator must be stopped. If in the Finished state the navigation stops, i.e. the movement stops or its speed becomes lower than the threshold value, and if this state persists for some time, the flag is set to true, otherwise it is set to false.

var stop​

Flag the active state of which indicates that the navigator must be stopped. If in the Finished state the navigation stops, i.e. the movement stops or its speed becomes lower than the threshold value, and if this state persists for some time, the flag is set to true, otherwise it is set to false.

AlternativeRouteSelector​

Alternative route selection.

Extends: Hashable
public static func == (lhs: AlternativeRouteSelector, rhs: AlternativeRouteSelector) -> Bool

Returns a Boolean value indicating whether two values are equal.

Methods
public func hash(into hasher: inout Hasher)

Hashes the essential components of this value by feeding them into the given hasher.

Parameters

hasher

Hasher

The hasher to use when combining the components of this instance.

public nonisolated func selectAlternativeRoute(
trafficRoute: TrafficRoute
)

Alternative route selection. If a passed route does not equal any of the current alternative routes, nothing happens. Otherwise, a corresponding alternative route becomes the current active route.

Parameters

trafficRoute

Alternative route that must be selected as the current active route.

AlternativeRoutesProviderSettings​

Settings of searching for alternative routes and a better route.

Extends: Hashable
public static func == (lhs: AlternativeRoutesProviderSettings, rhs: AlternativeRoutesProviderSettings) -> Bool

Returns a Boolean value indicating whether two values are equal.

Methods
public func hash(into hasher: inout Hasher)

Hashes the essential components of this value by passing them to the given hasher.

Parameters

hasher

Hasher

Hasher to use when combining the components of this instance.

Properties

var alternativeRoutesEnabled​

Flag to enable/disable the suggestion of alternative routes. By default, suggestion of alternative routes is enabled.

var betterRouteEnabled​

Flag to enable/disable the suggestion of a better route. By default, the better route suggestion is enabled.

var routeSearchDelay​

Delay before searching for alternative routes when starting a trip on a route or after switching to another route. Must be at least 5 seconds. The default is 20 seconds.

var onAlternativeRoutesSuggestedRouteSearchDelay​

Delay before the next route search right after alternative routes are suggested to the user. The delay resets if, after the alternative routes are suggested, the user switches to any route other than one of the suggested alternatives.

var betterRouteTimeCostThreshold​

Minimum difference in travel time between the original route and the alternate route at which the alternate route is considered a better route.

var betterRouteLengthThreshold​

Minimum cumulative length of route edges that differ between the original route and the alternate route, at which the alternate route is considered the better route.

var routerType​

Type of a search engine for finding alternative routes.

AnimationSettings​

Settings of map object animations. Applied to style layers with a model source specified. For example, layers of the "3D model" and "Directional model" type.

Extends: Hashable
public static func == (lhs: AnimationSettings, rhs: AnimationSettings) -> Bool

Returns a Boolean value indicating whether two values are equal.

Methods
public func hash(into hasher: inout Hasher)

Hashes the essential components of this value by feeding them into the given hasher.

Parameters

hasher

Hasher

The hasher to use when combining the components of this instance.

Properties

var animationIndex​

Int32?

Gets the index of the current model animation. If null, the value from styles is used.

var animationName​

Name of the current model animation. If null, the value from styles is used. If the value is not specified in styles, the animation is not played.

var sceneIndex​

Int32?

Gets the index of the current model scene. If null, the value from styles is used.

var sceneName​

Gets the title of the current model scene. If null, the value from styles is used.

var animationRepeatCount​

Int32?

Gets the number of the model animation repetitions. If null, the value from styles is used.

var animationSpeed​

Float?

Gets the speed of playing the model animation. If null, the value from styles is used.

Attributes​

Interface for managing map object attributes.

Extends: Hashable
public static func == (lhs: Attributes, rhs: Attributes) -> Bool

Returns a Boolean value indicating whether two values are equal.

Methods
public func hash(into hasher: inout Hasher)

Hashes the essential components of this value by passing them to the given hasher.

Parameters

hasher

Hasher

Hasher to use when combining the components of this instance.

public nonisolated func setAttributeValue(
name: String,
value: AttributeValue
)

Setting an attribute.

Parameters

name

Property name.

value

public nonisolated func setAttributeValues(
values: [String: AttributeValue],
attributesToRemove: [String] = []
)

Sets a set of attributes.

Parameters

values

String[ : ]

Set of “name”:“value” pairs for added properties.

attributesToRemove

List of property names to delete.

public nonisolated func removeAttribute(
name: String
)

Removes an attribute.

Parameters

name

Name of a property to delete.

public nonisolated func getAttributeValue(
name: String
) -> AttributeValue

Gets an attribute.

Parameters

name

Name of a property to retrieve.

Returns
Properties

var attributeNames​

Retrieving a list of properties.

var changed​

Channel<[String]>

Gets a channel notifying about the change of the properties.

AudioSettings​

Class for managing the sound.
All methods can be called from any thread.

Extends: Hashable
public static func == (lhs: AudioSettings, rhs: AudioSettings) -> Bool

Returns a Boolean value indicating whether two values are equal.
This documentation comment was inherited from .

Methods
public func hash(into hasher: inout Hasher)

Hashes the essential components of this value by feeding them into the given hasher.
This documentation comment was inherited from .

Parameters

hasher

Hasher

The hasher to use when combining the components of this instance.

public static nonisolated func `get`(
context: Context
) -> AudioSettings?

Obtains an object for managing application sound. Returns Null value if the audio driver is unavailable.

Parameters

context

Returns
Properties

var volume​

Sound volume level (0-100).

var mute​

Sound playing is disabled.

var audioFocusPolicy​

Behavior of other applications sounds with the requested focus.

BaseCamera​

Camera.

Extends: Hashable
public static func == (lhs: BaseCamera, rhs: BaseCamera) -> Bool

Returns a Boolean value indicating whether two values are equal.

Methods
public func hash(into hasher: inout Hasher)

Hashes the essential components of this value by passing them to the given hasher.

Parameters

hasher

Hasher

Hasher to use when combining the components of this instance.

public nonisolated func clone() -> BaseCamera

Creates a copy of the current camera.

Returns
public nonisolated func setPosition(
position: CameraPosition
) throws

Sets a new camera position.
The call interrupts flyover and gesture handling, and resets the tracking mode.

Parameters
public nonisolated func changePosition(
positionChange: CameraPositionChange
) throws

Changes only certain parameters of the camera position.
The call interrupts flyover and gesture handling and resets following changed parameters. If coordinates are changed, following the style scaling level and bearing is also reset.

Parameters

positionChange

public nonisolated func setZoomRestrictions(
zoomRestrictions: CameraZoomRestrictions
) throws

Sets a new range of zoom level limits.

Parameters

zoomRestrictions

New range of zoom-level restrictions.

public nonisolated func setPositionPoint(
positionPoint: CameraPositionPoint
) throws

Sets the new position relative to the area of the screen limited by the paddings.

Parameters

positionPoint

New position relative to the area of the screen bounded by the paddings.

public nonisolated func setViewPoint(
viewPoint: CameraViewPoint?
) throws

Sets the new viewpoint relative to the full size of the map viewport.

Parameters

viewPoint

New viewpoint relative to the full size of the map viewport. If nil is passed, follows the point of camera position.

Properties

var projection​

Projection.

var position​

Gets the current camera position.

var zoomRestrictions​

Gets the current zoom level limits.

var deviceDensity​

Gets the DPI ratio to the base DPI of the device.

var size​

Gets the viewport size.

var padding​

Gets the current padding from the edges of the screen.

var positionPoint​

Screen point to which the camera position is anchored is set with the padding.

var viewPoint​

Viewpoint relative to the full size of the map viewport.

var visibleArea​

Intersection area between the camera's visibility pyramid and the map surface.

var visibleRect​

Volume rectangle of the visible area of the map.

var maxTiltRestriction​

(any StyleZoomToTiltRelation)?

Gets the current function of the dependence of the maximum camera tilt angle on the style zoom level.

var viewportRestriction​

Gets the viewport restrictions.

var changed​

Channel<CameraChange>

Reasons for camera state changes.
Changed properties are available in the corresponding channels.

BearingFollowController​

Controller following the map bearing.

public convenience init(
bearingSource: BearingSource,
animationDuration: TimeInterval = 1,
valueThreshold: Bearing = Bearing