struct
Address
Address as a set of individual components.
public init(
drillDown: [AddressAdmDiv],
components: [AddressComponent],
buildingName: String?,
postCode: String?,
buildingCode: String?,
addressComment: String?
)
Parameters
drillDown
components
buildingName
postCode
buildingCode
addressComment
Properties
var drillDown
Set of administrative division objects in which the object being described is located.
var components
Complete address of an object may contain several separate address components.
var buildingName
Name of the building.
var postCode
ZIP code.
var buildingCode
The unique ZIP code of the building.
var addressComment
Address comment. Example: “office 301; floor 9”.
AddressAdmDiv
Administrative unit object.
AddressLocation
Applies to components that are hard to describe with a specific address.
Properties
var comment
Verbal description of the location of a building.
AddressNumber
Some localities designate only the house number, without the street (e.g., Krasnoobsk).
Properties
var number
Building number, including fractions and letters. Possibly a proper name, if that is the custom.
AddressStreet
Normal address, there is a street and house number.
Anchor
Image anchor point (0, 0) - upper left corner, (1, 1) - lower right corner.
public init(
x: Float = 0.5,
y: Float = 0.5
)
Parameters
x
Float
y
Float
Properties
var x
Float
var y
Float
ApartmentRange
Range of apartments.
Properties
var start
Range start/Stored value. Currently only numeric values are supported, apartments with suffixes are not yet available in the data.
var end
End of range. If absent, the range consists of a single start value. Otherwise it is an arithmetic progression from start to end in steps of 1.
ApiKeyOptions
Key settings for working with 2GIS SDK.
Properties
Attribute
Additional attribute. Example: { tag: “hotel_room_internet”, name: “Free internet in the rooms” }.
AudioOptions
Sound settings.
public init(muteOtherSounds: Bool, audioVolume: AudioVolume)
Parameters
Properties
static let `default`
Default settings. Mutes the sound of other applications and maximizes the playback volume.
AuthorInfo
Information about the author of the event or photo.
Properties
var type
Content author category.
var name
String containing the name of the user who added the event or photo.
BatteryOptions
Battery condition monitoring settings. Used to configure the battery condition monitoring service needed to optimize power consumption when the charge level is low or to activate power saving mode.
public init(lowBatteryThreshold: Int, delegate: IBatteryManagerDelegate?)
Parameters
Properties
var lowBatteryThreshold
Percentage of battery charge starting at and below which the charge is considered low. When the battery charge is low, aggressive power saving tools may be activated and warnings may be displayed. Value range: 0...100.
var delegate
Delegate of the battery monitoring service. Required to control turning on and off the battery status monitoring (see `UIDevice.isBatteryMonitoringEnabled`), which allows you to automatically enable power optimization.
static let `default`
Default settings. The low battery limit is 15%. Battery status monitoring is disabled. Power optimization is not automatically enabled.
Bearing
Angle between the direction to one object and another object or between the direction to the object and north. The angle is counted clockwise. The value range is [0°, 360°].
public init(floatLiteral value: Double)
Creates an instance initialized to the specified floating-point value.
Parameters
value
Value to create.
Properties
var value
BetterRouteInfo
Information on available alternative route.
public init(
trafficRoute: TrafficRoute,
startPoint: RoutePoint
)
Parameters
Properties
var trafficRoute
Alternative route.
var startPoint
Point on the alternative route from which traffic starts if you switch to this route.
BicycleBriefRouteInfo
Basic cycling route information.
Properties
BicycleInstructionCrossroad
Description of maneuvers when passing through an intersection or crosswalk.
public init(
landmark: BicycleInstructionCrossroadLandmark = BicycleInstructionCrossroadLandmark.`none`,
maneuvers: [BicycleInstructionCrossroadManeuver]
)
Parameters
Properties
var landmark
Landmark.
var maneuvers
Chain of sequential maneuvers.
BicycleInstructionCrossroadManeuver
public init(
direction: BicycleInstructionCrossroadManeuverDirection = BicycleInstructionCrossroadManeuverDirection.straight,
turnAngle: Int32 = 0
)
Parameters
Properties
var direction
Direction of travel.
var turnAngle
Int32
Turning angle in degrees [-180, 180].
BicycleInstructionFinish
End of the cycling part of the route.
public init()
BicycleInstructionStart
The beginning of the cycling part of the route.
public init()
BicycleRouteSearchOptions
Bicycle route search options.
public init(
avoidCarRoads: Bool = false,
avoidStairways: Bool = false,
avoidUnderpassesAndOverpasses: Bool = false,
excludedAreas: [ExcludedArea] = []
)
Parameters
Properties
var avoidCarRoads
Avoid roads.
var avoidStairways
Avoid stairs.
var avoidUnderpassesAndOverpasses
Avoid underpasses and overpasses.
var excludedAreas
Excluded areas (not more than 25).
BoolRouteLongEntry
Extended route element - segment and value on it.
public init(
point: RoutePoint,
length: RouteDistance,
value: Bool
)
Parameters
Properties
BriefRoadEvent
public init(
id: UInt64 = 0,
eventType: RoadEventType = RoadEventType.other,
lanes: LaneOptionSet
)
Parameters
Properties
BriefRouteInfo
Basic route information.
public init(
duration: TimeInterval,
extraInfo: BriefExtraRouteInfo
)
Parameters
Properties
var duration
Time of travel along the route.
var extraInfo
Additional route information for a specific vehicle type.
BriefRouteInfoSearchPoints
Points to query for basic route information search.
public init(
startPoint: RouteSearchPoint,
finishPoint: RouteSearchPoint
)
Parameters
Properties
var startPoint
Starting point of the route.
var finishPoint
Finish point of the route.
BuildingId
BuildingLevels
Information about the floor plans of the building.
public init(
defaultLevelId: LevelId,
levels: [LevelInfo]
)
Parameters
Properties
var defaultLevelId
Default floor plan identifier.
var levels
All floor plans of the building.
CalloutMapPosition
Route bubble position.
public init(
mapId: MapId,
calloutPosition: GeoPoint?,
routePoint: RoutePoint?
)
Parameters
Properties
var mapId
Identifier of the map for which the position is given.
var calloutPosition
Position on the map.
var routePoint
Lane bubble position on the route.
CameraBehaviour
Camera tracking mode.
public init(
position: FollowPosition?,
transitionType: TransitionType = TransitionType.smooth
)
Parameters
Properties
CameraBehaviourChange
Changes tracking mode.
public init(
newBehaviour: CameraBehaviour,
changeReason: CameraBehaviourChangeReason
)
Parameters
Properties
var newBehaviour
New tracking mode.
var changeReason
Reason for changing tracking mode.
CameraPosition
Camera position.
Properties
var point
Terrain point that is located at the camera position point (see ICamera::position_point()).
var zoom
Zoom level. 0 is the entire world inscribed in a square of 256x256 logical pixels (see LogicalPixel).
var tilt
Tilt angle of the gaze direction vertically.<br/>0 is nadir (vertically downward), maximum value is 60 degrees.
var bearing
Angle of rotation of the view direction horizontally relative to the north direction. Counted clockwise, in degrees.
CameraPositionPoint
Relative screen position of the point to which the camera is linked.
public init(
x: Float = 0.5,
y: Float = 0.5
)
Parameters
x
Float
y
Float
Properties
var x
Float
var y
Float
CameraProgressInfo
Information about the progress of the camera zone.
public init(
camera: RouteCamera,
position: RoutePoint,
progress: Float = 0
)
Parameters
Properties
var camera
Camera for the area for which progress is being tracked.
var position
Camera position on the route.
var progress
Float
Progress of the camera area, [0, 1].
CameraPurposeOptionSet
public init(rawValue: UInt32)
Creates a new option set from the given raw value.
Parameters
rawValue
Raw value of the option set to create. Each bit of `rawValue` potentially represents an element of the option set, though raw values may include bits that are not defined as distinct values of the `OptionSet` type.
Properties
var rawValue
Corresponding value of the raw type.
static let speedControl
Recording of exceeding the speed limit.
static let averageSpeedControl
Recording of exceeding the average speed on the section.
static let publicTransportLaneMovementControl
Recording of movement on the dedicated lane for public transport.
static let roadMarkingsCrossingControl
Recording of crossing the solid line of road markings, driving on the side of the road.
static let trafficLightsViolationControl
Recording of passing at the forbidden signal of traffic lights.
static let stopLineCrossingControl
Recording of driving over the stop line, driving without stopping the stop sign, driving to the intersection during a jam.
static let oncomingTrafficLaneMovementControl
Recording driving in the oncoming lane.
static let pedestrianAdvantageViolationControl
Recording failure to give priority to pedestrians.
static let laneDisciplineControl
Recording of violation of lane rotation at the intersection.
static let noStoppingViolationControl
Recording of violation of prohibition of stopping.
static let dummy
Fake item.
static let truck
Platon system camera, truck restriction control camera.
CameraRouteEntry
Route element - a point and a value in it.
Properties
CameraZoomRestrictions
Allowed range of zoom level variation.
CarBriefRouteInfo
Basic information about the automobile route.
public init(
length: RouteDistance,
landmark: String,
trafficSpeed: CarBriefRouteInfoTrafficSpeed
)
Parameters
Properties
var length
Route length.
var landmark
Landmark.
var trafficSpeed
Travel speed.
CarInstructionCrossroad
Description of maneuvers at the intersection.
public init(
direction: CarInstructionCrossroadDirection = CarInstructionCrossroadDirection.straight,
turnAngle: Int32 = 0,
landmark: CarInstructionCrossroadLandmark = CarInstructionCrossroadLandmark.`none`,
exitName: String
)
Parameters
direction
turnAngle
Int32
landmark
exitName
Properties
var direction
Direction of traffic at the intersection.
var turnAngle
Int32
Turning angle in degrees [-180, 180].
var landmark
Landmark.
var exitName
Exit name.
CarInstructionFinish
End of the automobile part of the route.
public init()
CarInstructionRoundabout
Description of maneuvers at a traffic circle intersection.
public init(
type: CarInstructionRoundaboutType = CarInstructionRoundaboutType.entry,
turnAngle: Int32 = 0,
exitNumber: UInt32 = 0,
exitName: String
)
Parameters
Properties
var type
Type of instruction.
var turnAngle
Int32
Turning angle in degrees [-180, 180].
var exitNumber
Exit number - [1, inf] or 0 if the exit number is unknown.
var exitName
Exit name.
CarInstructionStart
Start of the automobile part of the route.
public init()
CarInstructionUTurn
U-turn on the road (not at an intersection).<br/>U-turn at an intersection is described by the Crossroad instruction.
Properties
var exitName
Exit name.
CarRouteSearchOptions
Route search parameters in a passenger car.
public init(
avoidTollRoads: Bool = false,
avoidUnpavedRoads: Bool = false,
avoidFerries: Bool = false,
avoidLockedRoads: Bool = true,
routeSearchType: RouteSearchType = RouteSearchType.jam,
excludedAreas: [ExcludedArea] = []
)
Parameters
avoidTollRoads
avoidUnpavedRoads
avoidFerries
avoidLockedRoads
routeSearchType
excludedAreas
Properties
var avoidTollRoads
Avoid toll roads.
var avoidUnpavedRoads
Avoid unpaved roads.
var avoidFerries
Avoid ferry crossings.
var avoidLockedRoads
Avoid closed roads. If true, the route search will not take into account road closures. If false is set, the route can be created through roadblocks if you cannot build a route without passing through roadblocks.
var routeSearchType
Route search type.
var excludedAreas
Excluded areas (not more than 25).
CircleOptions
Parameters for creating a geometric map object of the Circle type.
public init(
position: GeoPoint,
radius: Meter,
color: Color = Color(),
strokeWidth: LogicalPixel = LogicalPixel(value: 0),
strokeColor: Color = Color(),
visible: Bool = true,
userData: Any = (),
zIndex: ZIndex = ZIndex(value: 0),
levelId: LevelId? = nil
)
Parameters
Properties
var position
Geographic position.
var radius
Radius in meters.
var color
Fill color.
var strokeWidth
Circle border line width.
var strokeColor
Color of the circle boundary line.
var visible
Visibility flag.
var userData
Any
User data. (not used inside SDK, only for API users).
var zIndex
Object drawing level.
var levelId
Binding to the floor plan of the building.
ClusterOptions
Cluster marker parameters.
public init(
attributes: [String: AttributeValue],
userData: Any = ()
)
Parameters
attributes
String[ : ]
Properties
var attributes
[String : AttributeValue]
Cluster attributes.
var userData
Any
User data returned to IClusterObject.
Color
Color.
init(
red: CGFloat,
green: CGFloat,
blue: CGFloat,
alpha: CGFloat
)
Parameters
Properties
var argb
ContactInfo
Way to contact the organization.
Properties
DashedPolylineOptions
Parameters of the dotted polyline.
public init(
dashLength: LogicalPixel = LogicalPixel(value: 5),
dashSpaceLength: LogicalPixel = LogicalPixel(value: 2)
)
Parameters
Properties
DayTime
Time moment within a day.
public static func < (lhs: DayTime, rhs: DayTime) -> Bool
Returns a Boolean value indicating whether the value of the first argument is less than that of the second argument.
DeviceDensity
Multiplier that is calculated as the ratio of DPI to the base DPI of the device.<br/>Must be positive.
public init(
value: Float = 0
)
Parameters
value
Float
Properties
var value
Float
DevicePpi
Resolution of the device display, in pixels per inch.<br/>Must be positive.
public init(
value: Float = 0
)
Parameters
value
Float
public init(floatLiteral value: Float)
Creates an instance initialized to the specified floating-point value.
Parameters
value
Float
The value to create.
Properties
var value
Float
static let autodetected
PPI of the head unit screen. For example, for a smartphone connected to CarPlay, this is the PPI of the smartphone screen. The value is `nil` if the current device has an unknown PPI (unsupported device, e.g. from future). In such cases, you need to set the PPI yourself using the entry in `Map.devicePpi`.
static let defaultForFailedAutodetection
This PPI is used by default in cases where it was not possible to automatically determine from the device model. See `.autodetected'.
DgisObjectId
DirectoryFilter
Filters for the directory.
public init(
workTime: WorkTimeFilter?,
dynamic: [DynamicFilter]
)
Parameters
Properties
DoubleRouteEntry
Route element - a point and a value in it.
Properties
DynamicRouteInfo
public init(
roadEvents: RoadEventRouteAttribute,
traffic: Traffic
)
Parameters
Properties
Elevation
Non-negative elevation of the point above the surface, in meters.
public init(
value: Float = 0
)
Parameters
value
Float
public init(floatLiteral value: Float)
Creates an instance initialized to the specified floating-point value.
Parameters
value
Float
Value to create.
Properties
var value
Float
EntranceGeometry
Geometries for displaying the entrance on the map.
public init(
entrancePoints: [GeoPoint],
entrancePolylines: [[GeoPoint]]
)
Parameters
Properties
var entrancePoints
Entrance location.
var entrancePolylines
Geometries for arrows pointing to the entrance.
EntranceInfo
Information about the entrance to the building.
public init(
id: DgisObjectId,
buildingNumber: String?,
porchName: String?,
porchNumber: String?,
apartmentRanges: [ApartmentRange],
geometry: EntranceGeometry?
)
Parameters
id
buildingNumber
porchName
porchNumber
apartmentRanges
geometry
Properties
var id
Input object ID.
var buildingNumber
Number of the house to which the entrance belongs.
var porchName
Non-empty entrance name. Filled in for entrances only. Can take values of the entrance name (e.g. "Entrance 1 ") or building number if the entrance has its own address.
var porchNumber
Non-empty entrance number. Filled in for entrances only. Can take values of entrance number (e.g. "1 ") or building number if the entrance has its own address.
var apartmentRanges
Apartment numbers pertaining to the entryway.
var geometry
Geometries for displaying the entrance on the map.
ExcludedArea
Excluded area to be avoided when building a route.
public init(
type: ExcludedAreaType = ExcludedAreaType.point,
severity: ExcludedAreaSeverity = ExcludedAreaSeverity.soft,
extent: RouteDistance,
points: [GeoPoint]
)
Parameters
Properties
var type
Type of the excluded area.
var severity
Priority of area exclusion.
var extent
Size of the excluded area (not more than 25 km).
var points
Coordinates of the points of the excluded area (not more than 500).
FlagFilter
Flag filter.
FloatRouteLongEntry
Extended route element - a segment and a value on it.
public init(
point: RoutePoint,
length: RouteDistance,
value: Float
)
Parameters
Properties
FloorInfo
Information about the floor plan for the marker - element of the search output.
Properties
FollowPosition
Tracking settings for direction, tilt, and zoom level.
public init(
bearing: FollowBearing = FollowBearing.off,
tilt: FollowTilt = FollowTilt.off,
styleZoom: FollowStyleZoom = FollowStyleZoom.off
)
Parameters
Properties
FollowValueOptionSet
public init(rawValue: UInt32)
Creates a new option set from the given raw value.
Parameters
rawValue
Raw value of the option set to create. Each bit of `rawValue` potentially represents an element of the option set, though raw values may include bits that are not defined as distinct values of the `OptionSet` type.
Properties
var rawValue
Corresponding value of the raw type.
static let coordinates
static let satelliteBearing
static let magneticBearing
static let tilt
static let styleZoom
static let accuracy
FormattedAddress
A human-readable representation of the address.
Properties
var drilldownAddress
Address from a drill-down. Example: “Novosibirsk, Kirovsky district”.
var streetAddress
Address inside a settlement. Example: “Nikolaeva str., 11”.
var addressComment
Address comment. Example: “office 301; floor 9”.
var postCode
Postal code of the object with a building code, if any. Example: “630088”, “630007/XBVJF8”.
GeoPoint
Point in a spherical coordinate system that, together with a geodetic coordinate system (e.g., WGS84), points to a point on the Earth's surface. This structure is not bound to a specific geodetic coordinate system. But this module contains free functions that operate with this structure already in a specific coordinate system (see the documentation to the functions).
init(latitude: CLLocationDegrees, longitude: CLLocationDegrees)
Parameters
Methods
func bearing(point: GeoPoint) -> Bearing
Calculates the bearing (the angle between the geographic north direction and the direction of movement, counted clockwise) between two points.
Parameters
func distance(point: GeoPoint) -> Meter
Calculates the minimum distance (along a great circle) between two points.
Parameters
GeoPointRouteEntry
Route element - a point and a value in it.
Properties
GeoPointWithElevation
Point in a geographic coordinate system (latitude, longitude, elevation).<br/>Elevation is defined in meters above the surface, not above the sea level.
public init(
latitude: Latitude,
longitude: Longitude,
elevation: Elevation = Elevation(value: 0)
)
Parameters
init(
latitude: CLLocationDegrees,
longitude: CLLocationDegrees,
elevation: CLLocationDistance
)
Parameters
init(
coordinate: CLLocationCoordinate2D,
elevation: CLLocationDistance
)
Parameters
Methods
func bearing(point: GeoPoint) -> Bearing
Calculates the bearing (the angle between the geographic north direction and the direction of movement, counted clockwise) for the projection of a point on the map and for a given point.
Parameters
func distance(point: GeoPoint) -> Meter
Calculates the minimum distance (along a great circle) between two points.
Parameters
func move(bearing: Bearing, meter: Meter) -> GeoPointWithElevation
Calculates the point obtained by moving the source point in the specified direction by the specified distance.
Parameters
GeoRect
Rectangular area in a spherical coordinate system (e.g. WGS84). This structure is not tied to a specific geodetic coordinate system.
Methods
func contains(
point: GeoPoint
) -> Bool
Whether the rectangle contains the point. Points on the border are also considered to belong to the rectangle.
Parameters
func intersects(
rect2: GeoRect
) -> Bool
Whether the rectangles intersect, i.e. have common points. The rectangles with common points located only on the boundary are also considered intersecting.
Parameters
Properties
var southWestPoint
Southwest point, bottom left border of rectangle.
var northEastPoint
Northeast point, top right of rectangle.
var isValid
Checks rectangle for correctness.
var isDegenerate
Checks the rectangle for degeneracy. If the points in the rectangle are equal, the rectangle is degenerate to a point. A degenerate rectangle is a correct rectangle. An incorrect rectangle is not degenerate.
GLContextError
Implements: ISDKError
GradientPolylineOptions
Parameters of the gradient polyline.
public init(
borderWidth: LogicalPixel = LogicalPixel(value: 0),
secondBorderWidth: LogicalPixel = LogicalPixel(value: 0),
gradientLength: LogicalPixel = LogicalPixel(value: 1),
borderColor: Color = Color(),
secondBorderColor: Color = Color(),
colors: [Color],
colorIndices: Data
)
Parameters
borderWidth
secondBorderWidth
gradientLength
borderColor
secondBorderColor
colors
colorIndices
Data
Properties
var borderWidth
Line border width.
var secondBorderWidth
Width of the second line border.
var gradientLength
Gradient line length.
var borderColor
Outline color.
var secondBorderColor
Color of the second outline.
var colors
Gradient polyline color palette.
var colorIndices
Data
Gradient polyline color indexes. The number of indexes must be 1 less than the number of polyline points.
HttpHeader
HTTPOptions
Keys for accessing 2GIS services.
public init(
timeout: TimeInterval,
cacheOptions: CacheOptions?
)
Parameters
timeout
TimeInterval
cacheOptions
CacheOptions?
Properties
let timeout
Network protocol wait time. Defaults to 15 seconds.
let cacheOptions
HTTPOptions.CacheOptions?
Caching mode. If `nil`, no cache is used. The default is to use the disk cache in the user's cache directory (`NSCachesDirectory`).
static let `default`
Default settings. Maximum cache size: 300 MB.
HttpRequest
public init(
url: String,
method: HttpMethod = HttpMethod.gET,
headers: [HttpHeader] = [],
body: Data? = nil
)
Parameters
Properties
HttpResponse
public init(
statusCode: HttpStatusCode,
headers: [HttpHeader]
)
Parameters
Properties
HttpStatusCode
public init(
value: Int32 = 0
)
Parameters
value
Int32
Properties
var value
Int32
ImageData
Image data: size, format, and binary data.
public init(
size: ScreenSize,
format: ImageFormat,
data: Data
)
Parameters
Properties
IndoorControlOptions
Settings for the floor control element in the building.
public init(visibilityBehavior: VisibilityBehavior)
Parameters
visibilityBehavior
VisibilityBehavior
init(
visibilityBehavior: VisibilityBehavior,
markingByRoute: MarkingByRoute
)
Parameters
visibilityBehavior
VisibilityBehavior
markingByRoute
MarkingByRoute
Properties
var visibilityBehavior
IndoorControlOptions.VisibilityBehavior
static let `default`
Default settings. Automatic visibility control.
InstructionRouteEntry
Route element - a point and a value in it.
public init(
point: RoutePoint,
value: RouteInstruction
)
Parameters
Properties
IntRouteEntry
Route element - a point and a value in it.
Properties
IsOpenNow
Open now.
public init()
LaneOptionSet
public init(rawValue: UInt32)
Creates a new option set from the given raw value.
Parameters
rawValue
Raw value of the option set to create. Each bit of `rawValue` potentially represents an element of the option set, though raw values may include bits that are not defined as distinct values of the `OptionSet` type.
Properties
var rawValue
Corresponding value of the raw type.
static let left
Left lane.
static let center
Middle lane.
static let right
Right lane.
LanesCalloutMapPosition
Position of the lane bubble for the route.
public init(
mapId: MapId,
routePoint: RoutePoint,
geoPoint: GeoPoint
)
Parameters
Properties
var mapId
Identifier of the map for which the position is given.
var routePoint
The lane callout position on the route.
var geoPoint
Position of the lane bubble on the map.
LaneSignRouteLongEntry
Extended route element - a segment and a value on it.
public init(
point: RoutePoint,
length: RouteDistance,
value: RouteLaneSign
)
Parameters
Properties
Latitude
Geographic latitude.
public init(floatLiteral value: Double)
Creates an instance initialized to the specified floating-point value.
Parameters
value
Value to create.
Properties
var value
LevelId
LevelInfo
Building floor information.
Locale
Locale identifier in the format `[language designer]-[region designer]`. Where `language designer` is the language code described in ISO 639-1, `region designer` is the country code described in ISO 3166-1.
public init(stringLiteral value: String)
Creates an instance initialized to the given string value.
Parameters
value
Value of the new instance.
Properties
var description
Textual representation of this instance.
LocalizationOptions
Application localization settings. Allows you to set the set of locales used to localize the map and guide.
public init(locales: [Locale], systemLocales: [Locale])
Parameters
public init(locales: [Locale])
Localization settings constructor.<br/>The `systemLocales` parameter is a list of the user's preferred languages.
Parameters
locales
List of locales supported by the application.
Properties
let locales
List of locales supported by the application. If an empty list is passed, system locales are used.
let systemLocales
List of system locales. If an empty list is passed, `en-EN` is used.
static let `default`
Default settings. Using the list of user's preferred languages.
Location
Geoposition.
public init(
coordinates: LocationCoordinates,
altitude: LocationFuzzyDouble?,
course: LocationCourse?,
groundSpeed: LocationFuzzyDouble?,
source: String,
timestamp: TimeInterval
)
Parameters
coordinates
altitude
course
groundSpeed
source
timestamp
TimeInterval
Properties
var coordinates
coordinates::value - geoposition coodinates. coordinates::accuracy - horizontal accuracy of geopositioning coordinates (DRMS), m. https://en.wikipedia.org/wiki/Circular_error_probable Value range: >= 0.
var altitude
altitude::value - altitude above the WGS84 reference ellipsoid, m. altitude::accuracy - standard deviation of the altitude measurement error, m. nil means that the platform does not provide this field. https://en.wikipedia.org/wiki/Standard_deviation Value range: (nil, > 0).
var course
course::value - bearing (direction of travel along the Earth's surface. The angle is measured relative to geographic north). course::accuracy - standard deviation of the error of the bearing measurement. nil means that the platform does not provide this field. https://en.wikipedia.org/wiki/Standard_deviation Value range: (nil, > 0).
var groundSpeed
ground_speed - speed along the Earth surface, m/s. Value range: >= 0. ground_speed::accuracy - mean square deviation of the speed measurement error, m/s. nil means that the platform does not provide this field. https://en.wikipedia.org/wiki/Rayleigh_distribution Value range: (nil, > 0).
var source
Name of the geoposition source.<br/>The timestamps between different geoposition sources are not synchronized, so you cannot compare the timestamps of geopositions that are derived from different sources.
var timestamp
Time point at which the geoposition was determined. This point is not attached to any specific date and is used solely to calculate the time between two geopositioning measurements obtained from one geopositioning source in one session. This field should increase monotonically (even when the system is in sleep mode).
LocationCoordinates
LocationCourse
LocationFuzzyDouble
LogicalPixel
Pixel the size of which is independent of screen density.
public init(
value: Float = 0
)
Parameters
value
Float
public init(floatLiteral value: Float)
Creates an instance initialized to the specified floating-point value.
Parameters
value
Float
Value to create.
Properties
var value
Float
LogMessage
Message being logged.
LogOptions
SDK logging settings.
Properties
var osLogLevel
Minimum level of errors that go into the system log (os_log).
var customLogLevel
Minimal level of errors in the user's logging receiver.
var customSink
Custom logging receiver.
static let `default`
Default settings. Warnings and more critical events are logged.
Longitude
Geographic longitude.
public init(floatLiteral value: Double)
Creates an instance initialized to the specified floating-point value.
Parameters
value
Value to create.
Properties
var value
MapDirection
Angle of the object relative to the north direction, in degrees, counted clockwise.
Properties
var value
MapGestureViewFactory
Default gesture processing factory.
Implements: IMapGestureViewFactory
Methods
public func makeGestureView(
map: Map,
eventProcessor: IMapEventProcessor,
coordinateSpace: IMapCoordinateSpace
) -> UIView & IMapGestureView
Creates a gesture handling layer.
Parameters
MapGestureViewOptions
Default gesture layer settings.
public init(
doubleTapScalingCenter: ScalingCenter,
twoFingerTapScalingCenter: ScalingCenter,
pinchScalingCenter: ScalingCenter
)
Parameters
doubleTapScalingCenter
ScalingCenter
twoFingerTapScalingCenter
ScalingCenter
pinchScalingCenter
ScalingCenter
Properties
var doubleTapScalingCenter
MapGestureViewOptions.ScalingCenter
var twoFingerTapScalingCenter
MapGestureViewOptions.ScalingCenter
var pinchScalingCenter
MapGestureViewOptions.ScalingCenter
static let `default`
Default settings. For double tap and two-finger tap gestures, zooming is relative to the location of the gesture.
MapId
Identifier of the map instance, unique within the process.
public init(
value: Int32 = 0
)
Parameters
value
Int32
Properties
var value
Int32
MapOptions
Initial map properties that can be set during its initialization. A property set to nil will not be applied, so the default value will be used.
Properties
var devicePPI
Number of physical screen points in a line 2.54 cm long.
var deviceDensity
Multiplier that is calculated as the ratio of devicePPI to the device's base DPI. The multiplier value corresponds to the nativeScale of the target screen.
var position
Camera location relative to the map.
var positionPoint
Relative location of the map location point in the camera view space.
var zoomRestrictions
Boundaries of the map zoom.
var sources
Map data sources.
var sourceDescriptors
Set<MapOptions.SourceDescriptor>?
Simplified way to specify map data sources.
var styleFuture
Future<Style>?
Initial map style with delayed loading. The style can be loaded using an `IStyleFactory` instance, see. `Container.styleFactory'. Use `Future.makeReadyValue(style)` if the style is already loaded.
var gestureViewFactory
Gesture processing layer factory. If `nil`, gestures are not processed until the `IMapView.gestureView` property is set.
var appearance
Selection of a theme within the selected map style, taking into account the environment.
var maxFps
Maximum allowable map refresh frequency.
var powerSavingMaxFps
Maximum allowable map refresh frequency in energy saving mode.
var backgroundColor
Backgroud color for loading styles.
var mapRendererType
Map renderer type.
static var `default`
Initial settings set when creating map objects. The DPI is determined based on the main device screen (see `DevicePpi.autodetected`). If autodetected fails, `DevicePpi.defaultForFailedAutodetection` is used.
MarkedUpText
Span text.
public init(
text: String,
matchedParts: [MarkedUpTextSpan]
)
Parameters
Properties
var text
Text.
var matchedParts
Set of non-overlapping Span, in order, in a text string describing parts that match the user's query.
MarkedUpTextSpan
Describes a subset of bytes of the string text.
MarkerOptions
Marker settings.
public init(
position: GeoPointWithElevation,
icon: Image?,
iconMapDirection: MapDirection? = nil,
anchor: Anchor = Anchor(x: 0.5, y: 0.5),
text: String? = nil,
textStyle: TextStyle? = nil,
iconOpacity: Opacity = Opacity(value: 1),
visible: Bool = true,
draggable: Bool = false,
iconWidth: LogicalPixel = LogicalPixel(value: 0),
userData: Any = (),
zIndex: ZIndex = ZIndex(value: 0),
animatedAppearance: Bool = true,
levelId: LevelId? = nil,
iconAnimationMode: AnimationMode = AnimationMode.normal
)
Parameters
position
icon
iconMapDirection
anchor
text
textStyle
iconOpacity
visible
draggable
iconWidth
zIndex
animatedAppearance
levelId
iconAnimationMode
Properties
var position
var icon
var iconMapDirection
var anchor
var text
var textStyle
var iconOpacity
var visible
var draggable
var iconWidth
Target width used for scaling.
var userData
Any
var zIndex
Object drawing level.
var animatedAppearance
Whether to animate the appearance.
var levelId
Binding to the floor plan of the building.
var iconAnimationMode
Animation mode.
MeasurementFormatterOutput
Result of the formatting of the measurement.
Meter
Length/distance in meters.
public init(
value: Float = 0
)
Parameters
value
Float
public init(floatLiteral value: Float)
Creates an instance initialized to the specified floating-point value.
Parameters
value
Float
Value to create.
Properties
var value
Float
MillisecondsRouteEntry
Route element - a point and a value in it.
Properties
MTLDeviceError
Implements: ISDKError
NavigationViewOptions
Navigator interface settings.
public init(
mapControlsBehaviour: NavigationViewMapControlsBehaviour = .visibleWhenNavigationActive,
distanceFormattingStrategy: DistanceFormattingStrategy = .default,
durationFormattingStrategy: DurationFormattingStrategy = .default,
durationValueFormattingStrategy: DurationValueFormattingStrategy = .default,
timeFormattingStrategy: TimeFormattingStrategy = .default,
speedFormattingStrategy: SpeedFormattingStrategy = .default,
theme: NavigationViewTheme = .default,
roadEventCardViewOptions: RoadEventCardViewOptions = .default,
roadEventCreationEnabled: Bool = true
)
Settings constructor.
Parameters
mapControlsBehaviour
Behavior of the camera controllers in navigation mode.
distanceFormattingStrategy
Way of formatting distances.
durationFormattingStrategy
Way to format the time interval.
durationValueFormattingStrategy
Formats the time interval value.
timeFormattingStrategy
Formats date/time.
speedFormattingStrategy
Formats speed.
theme
Navigator theme.
roadEventCardViewOptions
Traffic event card settings.
roadEventCreationEnabled
Whether a traffic event creation controller is needed.
Properties
var mapControlsBehaviour
var distanceFormattingStrategy
var durationFormattingStrategy
var durationValueFormattingStrategy
var timeFormattingStrategy
var speedFormattingStrategy
var theme
var roadEventCardViewOptions
var roadEventCreationEnabled
static var `default`
Navigator default interface settings.
NavigationViewTheme
Navigator theme.
public init(colors: Colors)
Parameters
colors
Colors
public init(
colors: Colors,
dashboardTheme: DashboardTheme,
remainingRouteInfoControlTheme: RemainingRouteInfoControlTheme,
nextManeuverControlTheme: NextManeuverControlTheme,
speedControlTheme: SpeedControlTheme,
cameraControlTheme: CameraControlTheme,
messageBarControlTheme: MessageBarControlTheme,
mapControlsTheme: MapControlsTheme,
betterRouteControlTheme: BetterRouteControlTheme,
thermometerTheme: ThermometerTheme
)
Parameters
colors
Colors
dashboardTheme
DashboardTheme
remainingRouteInfoControlTheme
RemainingRouteInfoControlTheme
nextManeuverControlTheme
NextManeuverControlTheme
speedControlTheme
SpeedControlTheme
cameraControlTheme
CameraControlTheme
messageBarControlTheme
MessageBarControlTheme
mapControlsTheme
MapControlsTheme
betterRouteControlTheme
BetterRouteControlTheme
thermometerTheme
ThermometerTheme
Properties
let colors
NavigationViewTheme.Colors
var dashboardTheme
NavigationViewTheme.DashboardTheme
var remainingRouteInfoControlTheme
NavigationViewTheme.RemainingRouteInfoControlTheme
var nextManeuverControlTheme
NavigationViewTheme.NextManeuverControlTheme
var speedControlTheme
NavigationViewTheme.SpeedControlTheme
var cameraControlTheme
NavigationViewTheme.CameraControlTheme
var messageBarControlTheme
NavigationViewTheme.MessageBarControlTheme
var mapControlsTheme
NavigationViewTheme.MapControlsTheme
var betterRouteControlTheme
NavigationViewTheme.BetterRouteControlTheme
var thermometerTheme
NavigationViewTheme.ThermometerTheme
static let `default`
Default navigator theme.
NoopCancellable
Ready-made ICancellable implementation that does not override anything.
Implements: ICancellable
public init()
Methods
public func cancel()
ObstacleInfo
Obstacle information on the route.
public init(
type: Obstacle = Obstacle.other,
limitation: ObstaclePassLimitation = ObstaclePassLimitation.unlimited
)
Parameters
Properties
ObstacleInfoRouteEntry
Route element - a point and a value in it.
Properties
ObstacleInfoRouteLongEntry
Extended route element - segment and value on it.
public init(
point: RoutePoint,
length: RouteDistance,
value: ObstacleInfo
)
Parameters
Properties
Opacity
Opacity - from 0.0 (full transparency) to 1.0 (full opacity).
public init(
value: Float = 0
)
Parameters
value
Float
Properties
var value
Float
OpeningHours
Hours of operation for the organization.
public init(
weekOpeningHours: [[WeekTimeInterval]],
isOpen24x7: Bool
)
Parameters
Properties
var weekOpeningHours
Hours of operation for each day of the week, starting on Monday.
var isOpen24x7
PackageInfo
Package information. See IPackage.
public init(
name: String,
installed: Bool = false,
incomplete: Bool = false,
preinstalled: Bool = false,
compatible: Bool = true,
hasUpdate: Bool = false,
updateStatus: PackageUpdateStatus
)
Parameters
Properties
var name
Localized name of the package.
var installed
Installation sign - true if the package has been selected for installation.
var incomplete
Sign of incomplete installation - true if there is no fully downloaded version of the package (possibly incompatible with the current SDK version).
var preinstalled
Sign of preinstalled packages. Preinstalled packages are always installed and fully loaded, and cannot be removed.
var compatible
Compatibility sign - true in case the downloaded package is compatible with the current SDK version.
var hasUpdate
Update availability sign is true in case there is an update for the downloaded package. It is possible situation, when during update process to new version even newer version of the package became available on the server. In this case the value will be true both during and after the upgrade.
var updateStatus
Package upgrade status.
Padding
Padding the edges of the camera.
ParkingCapacity
Parking capacity.
public init(
total: String?,
specialSpaces: [SpecialSpace]
)
Parameters
Properties
var total
Total parking capacity, parking spaces.
var specialSpaces
Description of special parking spaces.
ParkingInfo
General information about the parking lot.
public init(
type: ParkingType?,
purpose: ParkingPurpose,
access: ParkingAccess,
pavingType: ParkingPavingType?,
isPaid: Bool,
isIncentive: Bool,
forTrucks: Bool,
levelCount: UInt16?,
capacity: ParkingCapacity?
)
Parameters
type
purpose
access
pavingType
isPaid
isIncentive
forTrucks
levelCount
capacity
Properties
var type
Type.
var purpose
Value.
var access
Access type.
var pavingType
Coverage type.
var isPaid
Whether the parking lot is a paid parking lot.
var isIncentive
Whether the parking lot is intercepting.
var forTrucks
Are there spaces for trucks.
var levelCount
Number of levels.
var capacity
Capacity.
PedestrianBriefRouteInfo
Basic information about the walking route.
Properties
PedestrianInstructionCrossroad
Description of maneuvers when passing through an intersection or crosswalk.
public init(
landmark: PedestrianInstructionCrossroadLandmark = PedestrianInstructionCrossroadLandmark.`none`,
maneuvers: [PedestrianInstructionCrossroadManeuver]
)
Parameters
Properties
var landmark
var maneuvers
Chain of sequential maneuvers.
PedestrianInstructionCrossroadManeuver
public init(
direction: PedestrianInstructionCrossroadManeuverDirection = PedestrianInstructionCrossroadManeuverDirection.straight,
turnAngle: Int32 = 0
)
Parameters
Properties
var direction
Direction of travel.
var turnAngle
Int32
Turning angle in degrees [-180, 180].
PedestrianInstructionFinish
End of the pedestrian part of the route.
public init()
PedestrianInstructionIndoorEnter
Entrance to the building.
Properties
var levelId
Floor ID after entering the building.
PedestrianInstructionIndoorExit
Building exit.
public init()
PedestrianInstructionIndoorFloorChange
Floor change in the building.
public init(
type: PedestrianInstructionIndoorFloorChangeType = PedestrianInstructionIndoorFloorChangeType.undefined,
beginId: LevelId = LevelId(),
endId: LevelId = LevelId()
)
Parameters
Properties
var type
Floor change type.
var beginId
Floor ID before shift.
var endId
Floor ID after shift.
PedestrianInstructionStart
Starts of the walking part of the route.
public init()
PedestrianRouteSearchOptions
Pedestrian route search options.
public init(
avoidStairways: Bool = false,
useIndoor: Bool = true,
excludedAreas: [ExcludedArea] = []
)
Parameters
Properties
var avoidStairways
Avoid stairs.
var useIndoor
Build routes inside buildings.
var excludedAreas
Excluded areas (not more than 25).
PersonalDataCollectionOptions
Personal data collection and processing settings.
public init(personalDataCollectionConsent: PersonalDataCollectionConsent)
Parameters
personalDataCollectionConsent
Properties
let personalDataCollectionConsent
User choice regarding the collection and processing of personal data.
static let `default`
Default settings. Permission to collect and process personal data has been granted.
PlatformPositioningServicesFactory
Implementation of CLLocationManager-based geopositioning services.
Implements: IPositioningServicesFactory
public init(
locationManager: CLLocationManager = CLLocationManager()
)
Parameters
locationManager
Properties
let locationProvider
Geopositioning source interface. If `nil`, SDK geopositioning functions are not available.
let magneticHeadingProvider
Magnetic orientation source interface. If `nil`, the SDK magnetic orientation functions are not available.