Supplies records for one entity store during Database.pullFrom.
The entity class name, e.g. "User".
The records to upsert locally, or undefined to leave the
local store untouched.
Receives the full record list of one entity store during Database.pushTo.
The entity class name, e.g. "User".
All records currently in that entity's store.
Transport-agnostic adapter bridging the local IndexedDB with any backend.
Implement these two methods over your transport of choice (REST, WebSocket, in-memory, ...) and pass the adapter to Database.pushTo / Database.pullFrom. The library never assumes anything about the transport; conflict resolution is left to the adapter/backend (locally, pulled records win by primary key).
Example