RestrictedTelemetryConfigProvider
public class RestrictedTelemetryConfigProvider : TelemetryConfigProvider
Implementation of TelemetryConfigProvider
that restricts the telemetry configuration to only handle Location events.
When passing an instance of RestrictedTelemetryConfigProvider
to Telemetry.initialize
, the method throws a TelemetryError
if:
An error occurs when creating or accessing an internal database.
Important
This is a Public Preview API. It may be changed or removed at any time.
-
Create
RestrictedTelemetryConfigProvider
object.Throws
TelemetryError.invalidArgument
if the device ID contains symbols that are not allowed.Declaration
Swift
public init(apiKey: String, deviceID: String? = nil) throws
Parameters
apiKey
TomTom APIM API key.
deviceID
Optional device ID predefined by the client. If not provided, it is generated automatically. If not nil, it can contain only alphanumeric, ‘_’ (underscore) or ‘-’ (hyphen) characters. Otherwise,
Telemetry.initialize
throws an error.