sdk-traffic / com.tomtom.online.sdk.traffic / OnlineTrafficApi

OnlineTrafficApi

open class OnlineTrafficApi : TrafficApi

Main entry point for Traffic API Flow Segment Data and Traffic API Incident Details services.

Inherited Properties

DEFAULT_ONLINE_TRAFFIC_API_VERSION

static val DEFAULT_ONLINE_TRAFFIC_API_VERSION: String

Default TomTom's Traffic API service version.

DEFAULT_ONLINE_TRAFFIC_ENDPOINT

static val DEFAULT_ONLINE_TRAFFIC_ENDPOINT: String

Default TomTom's Traffic API endpoint.

Functions

create

open static fun create(context: Context): TrafficApi!
open static fun create(context: Context, apiKey: String!): TrafficApi!

Creates new TrafficApi object which will use provided Traffic API key. It uses default values for Traffic API service endpoint and api version.

findFlowSegmentData

open fun findFlowSegmentData(query: FlowSegmentDataQuery!): Single<FlowSegmentDataResponse!>!
open fun findFlowSegmentData(query: FlowSegmentDataQuery!, listener: FlowSegmentDataResultListener!): Unit

findIncidentDetails

open fun findIncidentDetails(query: IncidentDetailsQuery!): Single<IncidentDetailsResponse!>!
open fun findIncidentDetails(query: IncidentDetailsQuery!, listener: IncidentDetailsResultListener!): Unit

getResultScheduler

open fun getResultScheduler(): Scheduler

getWorkingScheduler

open fun getWorkingScheduler(): Scheduler