Data Layer high complexity Shared Component mobile
0
Dependencies
6
Dependents
3
Entities
0
Integrations

Description

Encrypted local SQLite database managed by Drift (Flutter's type-safe ORM). Provides full CRUD for all core entities - activities, contacts, notes, expenses, assignments - so peer mentors can read and write data without any network connection. Schema mirrors the server schema with selective denormalization for mobile query performance.

Feature: Offline Data Support

local-database

Responsibilities

  • Persist all core entities locally with AES-256 encryption via SQLCipher
  • Expose typed Dart table classes and companion objects for type-safe inserts and updates
  • Support full CRUD operations matching server-side schema structure
  • Provide reactive query streams for Riverpod provider integration
  • Manage schema migrations across app versions

Interfaces

activitiesDao: ActivitiesDao
contactsDao: ContactsDao
notesDao: NotesDao
expensesDao: ExpensesDao
assignmentsDao: AssignmentsDao
open(encryptionKey): Future<void>
close(): Future<void>
runTransaction(fn): Future<T>

Related Data Entities (3)

Data entities managed by this component