Flight

public struct Flight : Codable

Tracked data is aggregated and anonymized. To group tracked data it’s attached to a corresponding flight. The set flight object is stored locally until removed.

  • dep

    Departure airport’s ICAO code.

    Declaration

    Swift

    public let dep: String
  • Destination airport’s ICAO code.

    Declaration

    Swift

    public let dest: String
  • Flight number is a combination of the airline’s ICAO code and 1-4 digit number. When there is no such number, use ORIG-DEST-GUID, where ORIG is the ICAO code of the departure airport, DEST is the ICAO code of the destination airport and GUID is a globally unique identifier.

    Declaration

    Swift

    public let fnum: String
  • SDK will send a current position when in the air that can be visible on the map. The full flight number can be visible for other pilots in the same company but will not be visible to other companies. However, the aircraft’s position can still be visible on the map in real time. The flight number can be hidden like “ICAO–”. Set this flag to true if the fnum is a generated number or a custom manually entered (not a real flight plan number), otherwise set true. The default is true.

    Declaration

    Swift

    public var fnumManual: Bool?
  • Create a Flight object to associate tracked data with.

    Declaration

    Swift

    public init(dep: String = "",
                dest: String = "",
                fnum: String,
                fnumManual: Bool? = true)

    Parameters

    dep

    Departure airport’s ICAO code. Optional, but recommended to set.

    dest

    Destination airport’s ICAO code. Optional, but recommended to set.

    fnum

    Flight number. See fnum docs. Required.

    fnumManual

    Weather fnum is manually entered or generated. See fnumManual docs. Optional. The default is true.