# adhithya9841/qr-secure-share architecture

> Architecture diagram of the GitHub repository adhithya9841/qr-secure-share, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-03). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/adhithya9841/qr-secure-share
- Repository: https://github.com/adhithya9841/qr-secure-share

## Overview

QR Secure Share is an Android app for preparing and receiving password-protected file transfers represented as QR frames, with transfer history and settings screens. The visible user flow starts at Home and navigates to Send, Receive, History, or Settings. Send and Receive currently show UI prompts, but their file-picking, QR-generation, scanning, and restore buttons are TODOs; the core crypto and QR services therefore cannot be connected to those screens from the shown evidence. History storage components are present, though the History screen’s repository interaction is not established by the excerpts.

Main entry points: [`features/src/main/java/com/qrsecureshare/features/navigation/QRNavHost.kt`](https://github.com/adhithya9841/qr-secure-share/blob/main/features/src/main/java/com/qrsecureshare/features/navigation/QRNavHost.kt) (Navigation host), [`data/src/main/java/com/qrsecureshare/data/repository/HistoryRepositoryImpl.kt`](https://github.com/adhithya9841/qr-secure-share/blob/main/data/src/main/java/com/qrsecureshare/data/repository/HistoryRepositoryImpl.kt) (History repository), [`data/src/main/java/com/qrsecureshare/data/di/DataModule.kt`](https://github.com/adhithya9841/qr-secure-share/blob/main/data/src/main/java/com/qrsecureshare/data/di/DataModule.kt) (Data bindings), [`app/src/main/java/com/qrsecureshare/MainActivity.kt`](https://github.com/adhithya9841/qr-secure-share/blob/main/app/src/main/java/com/qrsecureshare/MainActivity.kt) (Main activity)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_app["App entry"]
  node_activity["Main activity<br/>[MainActivity.kt]"]
end

subgraph group_features["User interface"]
  node_navigation["Navigation host<br/>[QRNavHost.kt]"]
  node_home["Home screen<br/>[HomeScreen.kt]"]
  node_send["Send screen<br/>[SendScreen.kt]"]
  node_receive["Receive screen<br/>[ReceiveScreen.kt]"]
  node_historyscreen["History screen<br/>[HistoryScreen.kt]"]
  node_settings["Settings screen<br/>[SettingsScreen.kt]"]
end

subgraph group_transfer["Transfer core"]
  node_crypto["Encryption and checksums<br/>[CryptoManager.kt]"]
  node_compression["Compression"]
  node_qrgen["QR frame generation"]
  node_qrscan["QR frame scanning"]
  node_assembler["File assembly<br/>[FileAssembler.kt]"]
end

subgraph group_history["Transfer history"]
  node_record["Transfer record<br/>[TransferRecord.kt]"]
  node_status["Transfer status<br/>[TransferStatus.kt]"]
  node_repository["History contract"]
  node_repoimpl["History repository"]
  node_dao["Transfer DAO<br/>[TransferDao.kt]"]
  node_entity["Transfer entity<br/>[TransferEntity.kt]"]
  node_database[("Transfer database<br/>[AppDatabase.kt]")]
  node_datamodule["Data bindings<br/>[DataModule.kt]"]
end

node_user(("User"))

node_user -->|"opens app"| node_activity
node_activity -->|"shows"| node_navigation
node_navigation -->|"routes to"| node_home
node_navigation -->|"routes to"| node_send
node_navigation -->|"routes to"| node_receive
node_navigation -->|"routes to"| node_historyscreen
node_navigation -->|"routes to"| node_settings
node_qrgen -->|"checksums with"| node_crypto
node_assembler -->|"references"| node_crypto
node_repoimpl -->|"reads and writes"| node_dao
node_repoimpl -->|"maps records"| node_entity
node_repoimpl -->|"maps records"| node_record
node_repoimpl -->|"maps status"| node_status
node_datamodule -->|"binds"| node_repoimpl
node_datamodule -->|"provides"| node_database

click node_activity "https://github.com/adhithya9841/qr-secure-share/blob/main/app/src/main/java/com/qrsecureshare/MainActivity.kt"
click node_navigation "https://github.com/adhithya9841/qr-secure-share/blob/main/features/src/main/java/com/qrsecureshare/features/navigation/QRNavHost.kt"
click node_home "https://github.com/adhithya9841/qr-secure-share/blob/main/features/src/main/java/com/qrsecureshare/features/home/HomeScreen.kt"
click node_send "https://github.com/adhithya9841/qr-secure-share/blob/main/features/src/main/java/com/qrsecureshare/features/send/SendScreen.kt"
click node_receive "https://github.com/adhithya9841/qr-secure-share/blob/main/features/src/main/java/com/qrsecureshare/features/receive/ReceiveScreen.kt"
click node_historyscreen "https://github.com/adhithya9841/qr-secure-share/blob/main/features/src/main/java/com/qrsecureshare/features/history/HistoryScreen.kt"
click node_settings "https://github.com/adhithya9841/qr-secure-share/blob/main/features/src/main/java/com/qrsecureshare/features/settings/SettingsScreen.kt"
click node_crypto "https://github.com/adhithya9841/qr-secure-share/blob/main/core/src/main/java/com/qrsecureshare/core/crypto/CryptoManager.kt"
click node_compression "https://github.com/adhithya9841/qr-secure-share/blob/main/core/src/main/java/com/qrsecureshare/core/compression/CompressionManager.kt"
click node_qrgen "https://github.com/adhithya9841/qr-secure-share/blob/main/core/src/main/java/com/qrsecureshare/core/qr/QrGeneratorService.kt"
click node_qrscan "https://github.com/adhithya9841/qr-secure-share/blob/main/core/src/main/java/com/qrsecureshare/core/qr/QrScannerService.kt"
click node_assembler "https://github.com/adhithya9841/qr-secure-share/blob/main/core/src/main/java/com/qrsecureshare/core/qr/FileAssembler.kt"
click node_record "https://github.com/adhithya9841/qr-secure-share/blob/main/domain/src/main/java/com/qrsecureshare/domain/model/TransferRecord.kt"
click node_status "https://github.com/adhithya9841/qr-secure-share/blob/main/domain/src/main/java/com/qrsecureshare/domain/model/TransferStatus.kt"
click node_repository "https://github.com/adhithya9841/qr-secure-share/blob/main/domain/src/main/java/com/qrsecureshare/domain/repository/HistoryRepository.kt"
click node_repoimpl "https://github.com/adhithya9841/qr-secure-share/blob/main/data/src/main/java/com/qrsecureshare/data/repository/HistoryRepositoryImpl.kt"
click node_dao "https://github.com/adhithya9841/qr-secure-share/blob/main/data/src/main/java/com/qrsecureshare/data/db/TransferDao.kt"
click node_entity "https://github.com/adhithya9841/qr-secure-share/blob/main/data/src/main/java/com/qrsecureshare/data/db/TransferEntity.kt"
click node_database "https://github.com/adhithya9841/qr-secure-share/blob/main/data/src/main/java/com/qrsecureshare/data/db/AppDatabase.kt"
click node_datamodule "https://github.com/adhithya9841/qr-secure-share/blob/main/data/src/main/java/com/qrsecureshare/data/di/DataModule.kt"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_activity,node_user toneBlue
class node_navigation,node_home,node_send,node_receive,node_historyscreen,node_settings toneAmber
class node_crypto,node_compression,node_qrgen,node_qrscan,node_assembler toneMint
class node_record,node_status,node_repository,node_repoimpl,node_dao,node_entity,node_database,node_datamodule toneRose
```

## Components

### App entry

- [Main activity](https://github.com/adhithya9841/qr-secure-share/blob/main/app/src/main/java/com/qrsecureshare/MainActivity.kt): `app/src/main/java/com/qrsecureshare/MainActivity.kt`

### User interface

- [Navigation host](https://github.com/adhithya9841/qr-secure-share/blob/main/features/src/main/java/com/qrsecureshare/features/navigation/QRNavHost.kt): `features/src/main/java/com/qrsecureshare/features/navigation/QRNavHost.kt`
- [Home screen](https://github.com/adhithya9841/qr-secure-share/blob/main/features/src/main/java/com/qrsecureshare/features/home/HomeScreen.kt): `features/src/main/java/com/qrsecureshare/features/home/HomeScreen.kt`
- [Send screen](https://github.com/adhithya9841/qr-secure-share/blob/main/features/src/main/java/com/qrsecureshare/features/send/SendScreen.kt): `features/src/main/java/com/qrsecureshare/features/send/SendScreen.kt`
- [Receive screen](https://github.com/adhithya9841/qr-secure-share/blob/main/features/src/main/java/com/qrsecureshare/features/receive/ReceiveScreen.kt): `features/src/main/java/com/qrsecureshare/features/receive/ReceiveScreen.kt`
- [History screen](https://github.com/adhithya9841/qr-secure-share/blob/main/features/src/main/java/com/qrsecureshare/features/history/HistoryScreen.kt): `features/src/main/java/com/qrsecureshare/features/history/HistoryScreen.kt`
- [Settings screen](https://github.com/adhithya9841/qr-secure-share/blob/main/features/src/main/java/com/qrsecureshare/features/settings/SettingsScreen.kt): `features/src/main/java/com/qrsecureshare/features/settings/SettingsScreen.kt`

### Transfer core

- [Encryption and checksums](https://github.com/adhithya9841/qr-secure-share/blob/main/core/src/main/java/com/qrsecureshare/core/crypto/CryptoManager.kt): `core/src/main/java/com/qrsecureshare/core/crypto/CryptoManager.kt`
- [Compression](https://github.com/adhithya9841/qr-secure-share/blob/main/core/src/main/java/com/qrsecureshare/core/compression/CompressionManager.kt): `core/src/main/java/com/qrsecureshare/core/compression/CompressionManager.kt`
- [QR frame generation](https://github.com/adhithya9841/qr-secure-share/blob/main/core/src/main/java/com/qrsecureshare/core/qr/QrGeneratorService.kt): `core/src/main/java/com/qrsecureshare/core/qr/QrGeneratorService.kt`
- [QR frame scanning](https://github.com/adhithya9841/qr-secure-share/blob/main/core/src/main/java/com/qrsecureshare/core/qr/QrScannerService.kt): `core/src/main/java/com/qrsecureshare/core/qr/QrScannerService.kt`
- [File assembly](https://github.com/adhithya9841/qr-secure-share/blob/main/core/src/main/java/com/qrsecureshare/core/qr/FileAssembler.kt): `core/src/main/java/com/qrsecureshare/core/qr/FileAssembler.kt`

### Transfer history

- [Transfer record](https://github.com/adhithya9841/qr-secure-share/blob/main/domain/src/main/java/com/qrsecureshare/domain/model/TransferRecord.kt): `domain/src/main/java/com/qrsecureshare/domain/model/TransferRecord.kt`
- [Transfer status](https://github.com/adhithya9841/qr-secure-share/blob/main/domain/src/main/java/com/qrsecureshare/domain/model/TransferStatus.kt): `domain/src/main/java/com/qrsecureshare/domain/model/TransferStatus.kt`
- [History contract](https://github.com/adhithya9841/qr-secure-share/blob/main/domain/src/main/java/com/qrsecureshare/domain/repository/HistoryRepository.kt): `domain/src/main/java/com/qrsecureshare/domain/repository/HistoryRepository.kt`
- [History repository](https://github.com/adhithya9841/qr-secure-share/blob/main/data/src/main/java/com/qrsecureshare/data/repository/HistoryRepositoryImpl.kt): `data/src/main/java/com/qrsecureshare/data/repository/HistoryRepositoryImpl.kt`
- [Transfer DAO](https://github.com/adhithya9841/qr-secure-share/blob/main/data/src/main/java/com/qrsecureshare/data/db/TransferDao.kt): `data/src/main/java/com/qrsecureshare/data/db/TransferDao.kt`
- [Transfer entity](https://github.com/adhithya9841/qr-secure-share/blob/main/data/src/main/java/com/qrsecureshare/data/db/TransferEntity.kt): `data/src/main/java/com/qrsecureshare/data/db/TransferEntity.kt`
- [Transfer database](https://github.com/adhithya9841/qr-secure-share/blob/main/data/src/main/java/com/qrsecureshare/data/db/AppDatabase.kt): `data/src/main/java/com/qrsecureshare/data/db/AppDatabase.kt`
- [Data bindings](https://github.com/adhithya9841/qr-secure-share/blob/main/data/src/main/java/com/qrsecureshare/data/di/DataModule.kt): `data/src/main/java/com/qrsecureshare/data/di/DataModule.kt`

### Other components

- **User**

## Connections

- User → Main activity: opens app
- Main activity → Navigation host: shows (evidence: `app/src/main/java/com/qrsecureshare/MainActivity.kt`)
- Navigation host → Home screen: routes to (evidence: `features/src/main/java/com/qrsecureshare/features/navigation/QRNavHost.kt`)
- Navigation host → Send screen: routes to (evidence: `features/src/main/java/com/qrsecureshare/features/navigation/QRNavHost.kt`)
- Navigation host → Receive screen: routes to (evidence: `features/src/main/java/com/qrsecureshare/features/navigation/QRNavHost.kt`)
- Navigation host → History screen: routes to (evidence: `features/src/main/java/com/qrsecureshare/features/navigation/QRNavHost.kt`)
- Navigation host → Settings screen: routes to (evidence: `features/src/main/java/com/qrsecureshare/features/navigation/QRNavHost.kt`)
- QR frame generation → Encryption and checksums: checksums with (evidence: `core/src/main/java/com/qrsecureshare/core/qr/QrGeneratorService.kt`)
- File assembly → Encryption and checksums: references (evidence: `core/src/main/java/com/qrsecureshare/core/qr/FileAssembler.kt`)
- History repository → Transfer DAO: reads and writes (evidence: `data/src/main/java/com/qrsecureshare/data/repository/HistoryRepositoryImpl.kt`)
- History repository → Transfer entity: maps records (evidence: `data/src/main/java/com/qrsecureshare/data/repository/HistoryRepositoryImpl.kt`)
- History repository → Transfer record: maps records (evidence: `data/src/main/java/com/qrsecureshare/data/repository/HistoryRepositoryImpl.kt`)
- History repository → Transfer status: maps status (evidence: `data/src/main/java/com/qrsecureshare/data/repository/HistoryRepositoryImpl.kt`)
- Data bindings → History repository: binds (evidence: `data/src/main/java/com/qrsecureshare/data/di/DataModule.kt`)
- Data bindings → Transfer database: provides (evidence: `data/src/main/java/com/qrsecureshare/data/di/DataModule.kt`)
