framework

fun framework(name: String, writable: Boolean = false, tableHints: Map<String, TableHint> = emptyMap(), valuePolicy: SqliteValuePolicy = SqliteValuePolicy.MASK_SENSITIVE, onWrite: Runnable? = null, unmasked: Set<String> = emptySet(), database: () -> SQLiteDatabase): SqliteDb

A database that the app has open as a framework SQLiteDatabase, such as the one that a SQLiteOpenHelper returns.

Parameters

onWrite

called on a request's thread after each POST exec, edit, or delete that committed, also when it changed no row, so that the app can tell its own readers, such as a cache or the event that its screens reload on. What it throws is logged: the write stays committed. A Runnable, so that a lambda works from Java and from Kotlin.

unmasked

the names of the columns whose values the tab shows under SqliteValuePolicy.MASK_SENSITIVE although their names look like they hold a secret, such as an oauth_scopes column, which has auth in its name but holds no secret. A name matches a column with exactly that name, in any case: it is no pattern. In POST query, it matches a result column by its name, as the mask does. It changes nothing under SqliteValuePolicy.VISIBLE.

database

returns the app's open instance. The tab calls it on a request's thread, each time it reads, and never closes what it returns.