The entry point to tracing APIs.

Summary

Public constructors

TraceDriver(sink: AbstractTraceSink, isEnabled: Boolean)
android
TraceDriver(context: Context, sink: AbstractTraceSink, isEnabled: Boolean)
android

Public functions

open Unit

Flushes all outstanding packets to the AbstractTraceSink and then closes the AbstractTraceSink.

android
open Unit

Flushes all outstanding packets to the AbstractTraceSink and then closes the AbstractTraceSink.

android
open Unit

Flushes the trace packets into the underlying AbstractTraceSink.

android
open Unit

Flushes the trace packets into the underlying AbstractTraceSink.

android

Public properties

open Tracer

Return an instance of a Tracer that can be used to emit trace events.

android
open Tracer

Return an instance of a Tracer that can be used to emit trace events.

android

Inherited functions

From androidx.tracing.AbstractTraceDriver
abstract Unit

Flushes all outstanding packets to the AbstractTraceSink and then closes the AbstractTraceSink.

Cmn
abstract Unit

Flushes the trace packets into the underlying AbstractTraceSink.

Cmn

Inherited properties

From androidx.tracing.AbstractTraceDriver
Boolean

When isEnabled is true, then the Tracer obtained from the AbstractTraceDriver emits trace events.

android
Boolean

When isEnabled is true, then the Tracer obtained from the AbstractTraceDriver emits trace events.

Cmn
Boolean

When isEnabled is true, then the Tracer obtained from the AbstractTraceDriver emits trace events.

android
AbstractTraceSink

The AbstractTraceSink that asynchronously serializes trace events to a file or buffer, depending on implementation.

android
AbstractTraceSink

The AbstractTraceSink that asynchronously serializes trace events to a file or buffer, depending on implementation.

Cmn
AbstractTraceSink

The AbstractTraceSink that asynchronously serializes trace events to a file or buffer, depending on implementation.

android
abstract Tracer

Return an instance of a Tracer that can be used to emit trace events.

Cmn

Public constructors

TraceDriver

TraceDriver(sink: AbstractTraceSink, isEnabled: Boolean = true)
Parameters
sink: AbstractTraceSink

The TraceSink instance.

isEnabled: Boolean = true

Set this to true to emit trace events. false disables all tracing to lower overhead.

TraceDriver

TraceDriver(
    context: Context,
    sink: AbstractTraceSink,
    isEnabled: Boolean = true
)
Parameters
context: Context

The Android application Context.

sink: AbstractTraceSink

The TraceSink instance.

isEnabled: Boolean = true

Set this to true to emit trace events. false disables all tracing to lower overhead.

Public functions

close

open fun close(): Unit

Flushes all outstanding packets to the AbstractTraceSink and then closes the AbstractTraceSink.

close

open fun close(): Unit

Flushes all outstanding packets to the AbstractTraceSink and then closes the AbstractTraceSink.

flush

open fun flush(): Unit

Flushes the trace packets into the underlying AbstractTraceSink.

flush

open fun flush(): Unit

Flushes the trace packets into the underlying AbstractTraceSink.

Public properties

tracer

open val tracerTracer

Return an instance of a Tracer that can be used to emit trace events.

tracer

open val tracerTracer

Return an instance of a Tracer that can be used to emit trace events.