Added in API level 35

LogReader


open class LogReader
kotlin.Any
   ↳ android.adservices.ondevicepersonalization.LogReader

An interface to a read logs from REQUESTS and EVENTS Used as a Data Access Object for the REQUESTS and EVENTS table.

Summary

Public methods
open MutableList<EventLogRecord!>
getJoinedEvents(startTime: Instant, endTime: Instant)

Retrieves a List of EventLogRecord with its corresponding RequestLogRecord written by this IsolatedService within the specified time range.

open MutableList<RequestLogRecord!>
getRequests(startTime: Instant, endTime: Instant)

Retrieves a List of RequestLogRecords written by this IsolatedService within the specified time range.

Public methods

getJoinedEvents

Added in API level 35
open fun getJoinedEvents(
    startTime: Instant,
    endTime: Instant
): MutableList<EventLogRecord!>

Retrieves a List of EventLogRecord with its corresponding RequestLogRecord written by this IsolatedService within the specified time range.
This method may take several seconds to complete, so it should only be called from a worker thread.

Parameters
startTime Instant: This value cannot be null.
endTime Instant: This value cannot be null.
Return
MutableList<EventLogRecord!> This value cannot be null.

getRequests

Added in API level 35
open fun getRequests(
    startTime: Instant,
    endTime: Instant
): MutableList<RequestLogRecord!>

Retrieves a List of RequestLogRecords written by this IsolatedService within the specified time range.
This method may take several seconds to complete, so it should only be called from a worker thread.

Parameters
startTime Instant: This value cannot be null.
endTime Instant: This value cannot be null.
Return
MutableList<RequestLogRecord!> This value cannot be null.