Structures

The following structures are available globally.

  • Represents body of the MTError exception.

    See more

    Declaration

    Swift

    public struct MTException : Sendable
  • Color wrapper.

    See more

    Declaration

    Swift

    public struct MTColor : Sendable, Codable, Equatable
  • A utility to parse GeoJSON and extract coordinates for use with offline regions or other geometry models.

    See more

    Declaration

    Swift

    public struct MTGeoJSONParser : Sendable
  • Options for building a heatmap visualization layer through the helper.

    See more

    Declaration

    Swift

    public struct MTHeatmapLayerOptions : Codable, Sendable
  • The result returned after adding a point layer.

    See more

    Declaration

    Swift

    public struct MTPointLayerResult : Codable, Sendable, Equatable
  • The result returned after adding a polygon layer.

    See more

    Declaration

    Swift

    public struct MTPolygonLayerResult : Codable, Sendable, Equatable
  • The result returned after adding a polyline layer.

    See more

    Declaration

    Swift

    public struct MTPolylineLayerResult : Codable, Sendable, Equatable
  • The result returned after adding a heatmap layer.

    See more

    Declaration

    Swift

    public struct MTHeatmapLayerResult : Codable, Sendable, Equatable
  • Pure math helpers for geographic calculations, projections, and tile indices.

    See more

    Declaration

    Swift

    public struct MTMath
  • Options for building a point visualization layer through the helper.

    Mirrors the available configuration including common shape options.

    See more

    Declaration

    Swift

    public struct MTPointLayerOptions : Codable, Sendable
  • Options for building a polygon (fill) visualization layer through the helper.

    See more

    Declaration

    Swift

    public struct MTPolygonLayerOptions : Codable, Sendable
  • Options for building a polyline (line) visualization layer through the helper.

    See more

    Declaration

    Swift

    public struct MTPolylineLayerOptions : Codable, Sendable
  • Log object used with MTLogger.

    See more

    Declaration

    Swift

    public struct MTLog
  • Handles zooming in the map with double tap.

    See more

    Declaration

    Swift

    @MainActor
    public struct MTDoubleTapZoomInGesture : MTGesture
  • Handles panning the map by dragging.

    See more

    Declaration

    Swift

    @MainActor
    public struct MTDragPanGesture : MTGesture
  • Handles zoom and rotate by pinching with two fingers.

    See more

    Declaration

    Swift

    @MainActor
    public struct MTPinchRotateAndZoomGesture : MTGesture
  • Handles changing the pitch by dragging with two fingers.

    See more

    Declaration

    Swift

    @MainActor
    public struct MTTwoFingersDragPitchGesture : MTGesture
  • Map view content builder.

    See more

    Declaration

    Swift

    @resultBuilder
    public struct MTMapContentBuilder
  • Parameters of the map object.

    See more

    Declaration

    Swift

    public struct MTMapOptions : Sendable
    extension MTMapOptions: Codable
  • Declarative Map view for use in SwiftUI

    See more

    Declaration

    Swift

    @MainActor
    public struct MTMapViewContainer : View
  • Provides animation options for navigation functions.

    See more

    Declaration

    Swift

    public struct MTAnimationOptions : Sendable, Codable
  • Options for controlling the desired location, zoom, bearing, and pitch of the camera.

    See more

    Declaration

    Swift

    public struct MTCameraOptions : Sendable
    extension MTCameraOptions: Codable
  • Options for drag and pan gesstures.

    See more

    Declaration

    Swift

    public struct MTDragPanOptions : Sendable, Codable
  • Options that configure how the map fits to a set of bounds.

    See more

    Declaration

    Swift

    public struct MTFitBoundsOptions : Sendable, Codable
  • Options describing the destination and animation of the flyTo transition.

    See more

    Declaration

    Swift

    public struct MTFlyToOptions : Sendable, Codable
  • Options for setting padding on calls to map methods.

    See more

    Declaration

    Swift

    public struct MTPaddingOptions : Sendable, Codable, Equatable
  • Supporting type to add validation to another style related type.

    See more

    Declaration

    Swift

    public struct MTStyleSetterOptions : Sendable, Codable
  • Configuration that controls how an image is registered within the MapTiler style.

    See more

    Declaration

    Swift

    public struct MTStyleImageOptions : Codable, Equatable, Sendable
  • Represents rectangular geographic bounds defined by southwest and northeast corners.

    See more

    Declaration

    Swift

    public struct MTBounds : Sendable, Codable, Equatable
  • Object sent together with MTEvent.

    See more

    Declaration

    Swift

    public struct MTData : Codable
  • One stop in the halo radial gradient: position in [0,1] and color.

    See more

    Declaration

    Swift

    public struct MTHaloStop : Sendable, Codable
  • Configuration for the atmospheric glow (halo).

    See more

    Declaration

    Swift

    public struct MTHalo : Sendable, Codable
  • A style’s light property provides a global light source for that style.

    See more

    Declaration

    Swift

    public struct MTLight : Sendable, Codable
  • Two numbers representing x and y screen coordinates in pixels.

    See more

    Declaration

    Swift

    public struct MTPoint : Codable, Sendable
  • The style spec representation of the source if the event has a dataType of source .

    See more

    Declaration

    Swift

    public struct MTSourceData : Codable
  • Faces definition for a custom cubemap.

    See more

    Declaration

    Swift

    public struct MTSpaceFaces : Sendable, Codable
  • Path-based configuration for cubemap files.

    This fetches all images from a path, this assumes all files are named px, nx, py, ny, pz, nz and suffixed with the appropriate extension specified in format.

    See more

    Declaration

    Swift

    public struct MTSpacePath : Sendable, Codable
  • Configuration for the “space” background.

    See more

    Declaration

    Swift

    public struct MTSpace : Sendable, Codable
  • RGBA color represented by 0…255 components.

    See more

    Declaration

    Swift

    public struct MTRGBAColor : Sendable, Codable
  • A stop describing the value and color to apply.

    See more

    Declaration

    Swift

    public struct MTColorRampStop : Sendable, Codable
  • Bounds of a color ramp.

    See more

    Declaration

    Swift

    public struct MTColorRampBounds : Sendable, Codable
  • Options used when instantiating a color ramp.

    See more

    Declaration

    Swift

    public struct MTColorRampOptions : Sendable, Codable
  • Options for rendering the ramp to a canvas strip.

    See more

    Declaration

    Swift

    public struct MTColorRampCanvasStripOptions : Sendable, Codable
  • Array-based stop definition for fromArrayDefinition.

    See more

    Declaration

    Swift

    public struct MTColorRampArrayStop : Sendable, Codable
  • A single string value at a given zoom level.

    See more

    Declaration

    Swift

    public struct MTZoomStringValue : Codable, Sendable
  • A single numeric value at a given zoom level.

    See more

    Declaration

    Swift

    public struct MTZoomNumberValue : Codable, Sendable
  • A single mapping from a property value to an associated numeric value.

    See more

    Declaration

    Swift

    public struct MTHelperPropertyValue : Codable, Sendable

Colors

  • Encodes a color to a hex string when converted to JSON. Accepts either a hex color string (e.g. “#RRGGBB”) or a UIColor.

    See more

    Declaration

    Swift

    public struct MTColorValue : Codable, Sendable
  • Sky configuration used by map.setSky.

    See more

    Declaration

    Swift

    public struct MTSky : Sendable, Codable, Equatable
  • A helper struct for validating and building tile URLs from string templates.

    See more

    Declaration

    Swift

    public struct MTTileURLTemplate
  • A bounding box in WGS84 coordinates.

    See more

    Declaration

    Swift

    public struct MTBoundingBox : Codable, Equatable, Sendable
  • Provides additional context for an offline error.

    See more

    Declaration

    Swift

    public struct MTOfflineContext : Sendable, Equatable
  • Provides estimation for offline pack size and resource counts.

    See more

    Declaration

    Swift

    public struct MTOfflineEstimator : Sendable
  • Metadata information about an offline pack.

    This model is used to persist pack information such as its identifier, current state, total size, and creation date.

    See more

    Declaration

    Swift

    public struct MTOfflinePackMetadata : Codable, Equatable, Sendable
  • Represents the download progress of an offline pack.

    See more

    Declaration

    Swift

    public struct MTOfflinePackProgress : Sendable, Equatable, Codable
  • Defines a region for offline download.

    See more

    Declaration

    Swift

    public struct MTOfflineRegionDefinition : Codable, Equatable, Sendable
  • Statistics about an offline map pack.

    See more

    Declaration

    Swift

    public struct MTPackStats
  • Represents a sprite defined in a map style.

    See more

    Declaration

    Swift

    public struct MTStyleSprite : Decodable, Equatable
  • Represents a tile source extracted from a style JSON.

    See more

    Declaration

    Swift

    public struct MTStyleSource : Equatable
  • Represents the non-tile dependencies extracted from a style JSON.

    See more

    Declaration

    Swift

    public struct MTStyleDependencies : Equatable
  • A parser responsible for extracting offline dependencies (sprites and glyphs) from a style JSON payload.

    See more

    Declaration

    Swift

    public struct MTStyleParser
  • An estimate for an offline tile download.

    See more

    Declaration

    Swift

    public struct MTTileEstimate
  • Represents a range of map tiles at a specific zoom level.

    See more

    Declaration

    Swift

    public struct MTTileRange : Equatable, Sendable
  • Defines and validates a zoom range for offline tile calculations.

    See more

    Declaration

    Swift

    public struct MTOfflineZoomRange : Equatable
  • Holds normalized and validated coverage input parameters required for calculating tile coverage.

    See more

    Declaration

    Swift

    public struct MTOfflineCoverageInputs : Equatable
  • Represents a discrete tile coordinate in a map grid at a specific zoom level.

    See more

    Declaration

    Swift

    public struct MTOfflineTile : Equatable, Hashable, CustomStringConvertible