# tranhuyhoang69/do-an-tot-nghiep architecture

> Architecture diagram of the GitHub repository tranhuyhoang69/do-an-tot-nghiep, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-11-12). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/tranhuyhoang69/do-an-tot-nghiep
- Repository: https://github.com/tranhuyhoang69/do-an-tot-nghiep

## Overview

MoneyMatev2 appears to be an Android personal-finance app. Its likely user flow is entering or scanning a transaction, then reviewing spending and budgets; the tree also shows account, category, recurring-transaction, reminder, security, statistics, and sync features. The README provides no capability or wiring details, and no runtime source was excerpted, so relationships below are dashed and unverified rather than asserted as inspected calls.

Main entry points: [`app/src/main/java/com/example/moneymatev2/data/repository/TransactionRepositoryImpl.kt`](https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/data/repository/TransactionRepositoryImpl.kt) (Data repositories), [`app/src/main/java/com/example/moneymatev2/navigation/NavGraph.kt`](https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/navigation/NavGraph.kt) (Navigation), [`app/src/main/java/com/example/moneymatev2/presentation/transaction/AddTransactionScreen.kt`](https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/presentation/transaction/AddTransactionScreen.kt) (Transaction entry), [`app/src/main/java/com/example/moneymatev2/domain/usecase/reminder/CreateReminderUseCase.kt`](https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/domain/usecase/reminder/CreateReminderUseCase.kt) (Reminder rules)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_ui["User experience"]
  node_app["App entry<br/>[MainActivity.kt]"]
  node_navigation["Navigation<br/>[NavGraph.kt]"]
  node_finance_ui["Finance screens<br/>[HomeScreen.kt]"]
  node_transaction_ui["Transaction entry"]
  node_ocr_ui["Receipt scanning<br/>[OcrScanScreen.kt]"]
  node_budget_ui["Budget screens<br/>[BudgetScreen.kt]"]
  node_statistics_ui["Statistics"]
  node_profile_ui["Account settings<br/>[ProfileScreen.kt]"]
end

subgraph group_domain["Finance domain"]
  node_transaction_logic["Transaction rules"]
  node_budget_logic["Budget overview"]
  node_recurring_logic["Recurring schedules"]
  node_reminder_logic["Reminder rules"]
  node_sync_logic["Sync orchestration"]
end

subgraph group_storage["Local data"]
  node_repositories["Data repositories"]
  node_database[("Room database<br/>[AppDatabase.kt]")]
end

subgraph group_services["Platform services"]
  node_receipt_ocr["Receipt OCR"]
  node_reminder_service["Reminder delivery"]
  node_cloud_sync["Cloud sync"]
end

node_user(("User"))
node_cloud[("Cloud backend")]

node_user -.->|"opens"| node_app
node_app -.->|"starts"| node_navigation
node_navigation -.->|"routes to"| node_finance_ui
node_finance_ui -.->|"offers entry"| node_transaction_ui
node_transaction_ui -.->|"submits transaction"| node_transaction_logic
node_ocr_ui -.->|"requests scan"| node_receipt_ocr
node_receipt_ocr -.->|"provides receipt data"| node_transaction_ui
node_budget_ui -.->|"requests overview"| node_budget_logic
node_statistics_ui -.->|"reads finance data"| node_repositories
node_profile_ui -.->|"configures app"| node_navigation
node_transaction_logic -.->|"persists transaction"| node_repositories
node_budget_logic -.->|"reads budget data"| node_repositories
node_recurring_logic -.->|"stores schedules"| node_repositories
node_reminder_logic -.->|"stores reminders"| node_repositories
node_reminder_logic -.->|"schedules alerts"| node_reminder_service
node_repositories -.->|"reads and writes"| node_database
node_sync_logic -.->|"coordinates sync"| node_cloud_sync
node_cloud_sync -.->|"exchanges data"| node_cloud

click node_app "https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/MainActivity.kt"
click node_navigation "https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/navigation/NavGraph.kt"
click node_finance_ui "https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/presentation/home/HomeScreen.kt"
click node_transaction_ui "https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/presentation/transaction/AddTransactionScreen.kt"
click node_ocr_ui "https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/presentation/ocr/OcrScanScreen.kt"
click node_budget_ui "https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/presentation/budget/BudgetScreen.kt"
click node_statistics_ui "https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/presentation/statistics/StatisticsScreens.kt"
click node_profile_ui "https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/presentation/profile/ProfileScreen.kt"
click node_transaction_logic "https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/domain/usecase/transaction/CreateTransactionUseCase.kt"
click node_budget_logic "https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/domain/usecase/GetMonthlyBudgetOverviewUseCase.kt"
click node_recurring_logic "https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/domain/usecase/recurring/RecurringScheduleCaculator.kt"
click node_reminder_logic "https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/domain/usecase/reminder/CreateReminderUseCase.kt"
click node_sync_logic "https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/domain/usecase/SyncOrchestrator.kt"
click node_repositories "https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/data/repository/TransactionRepositoryImpl.kt"
click node_database "https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/data/local/AppDatabase.kt"
click node_receipt_ocr "https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/data/ocr/MlKitOcrProcessor.kt"
click node_reminder_service "https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/data/reminder/AlarmReminderScheduler.kt"
click node_cloud_sync "https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/data/remote/sync/CloudPullService.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_app,node_navigation,node_finance_ui,node_transaction_ui,node_ocr_ui,node_budget_ui,node_statistics_ui,node_profile_ui,node_user toneBlue
class node_transaction_logic,node_budget_logic,node_recurring_logic,node_reminder_logic,node_sync_logic,node_cloud toneAmber
class node_repositories,node_database toneMint
class node_receipt_ocr,node_reminder_service,node_cloud_sync toneRose
```

## Components

### User experience

- [App entry](https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/MainActivity.kt): `app/src/main/java/com/example/moneymatev2/MainActivity.kt`
- [Navigation](https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/navigation/NavGraph.kt): `app/src/main/java/com/example/moneymatev2/navigation/NavGraph.kt`
- [Finance screens](https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/presentation/home/HomeScreen.kt): `app/src/main/java/com/example/moneymatev2/presentation/home/HomeScreen.kt`
- [Transaction entry](https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/presentation/transaction/AddTransactionScreen.kt): `app/src/main/java/com/example/moneymatev2/presentation/transaction/AddTransactionScreen.kt`
- [Receipt scanning](https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/presentation/ocr/OcrScanScreen.kt): `app/src/main/java/com/example/moneymatev2/presentation/ocr/OcrScanScreen.kt`
- [Budget screens](https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/presentation/budget/BudgetScreen.kt): `app/src/main/java/com/example/moneymatev2/presentation/budget/BudgetScreen.kt`
- [Statistics](https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/presentation/statistics/StatisticsScreens.kt): `app/src/main/java/com/example/moneymatev2/presentation/statistics/StatisticsScreens.kt`
- [Account settings](https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/presentation/profile/ProfileScreen.kt): `app/src/main/java/com/example/moneymatev2/presentation/profile/ProfileScreen.kt`

### Finance domain

- [Transaction rules](https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/domain/usecase/transaction/CreateTransactionUseCase.kt): `app/src/main/java/com/example/moneymatev2/domain/usecase/transaction/CreateTransactionUseCase.kt`
- [Budget overview](https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/domain/usecase/GetMonthlyBudgetOverviewUseCase.kt): `app/src/main/java/com/example/moneymatev2/domain/usecase/GetMonthlyBudgetOverviewUseCase.kt`
- [Recurring schedules](https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/domain/usecase/recurring/RecurringScheduleCaculator.kt): `app/src/main/java/com/example/moneymatev2/domain/usecase/recurring/RecurringScheduleCaculator.kt`
- [Reminder rules](https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/domain/usecase/reminder/CreateReminderUseCase.kt): `app/src/main/java/com/example/moneymatev2/domain/usecase/reminder/CreateReminderUseCase.kt`
- [Sync orchestration](https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/domain/usecase/SyncOrchestrator.kt): `app/src/main/java/com/example/moneymatev2/domain/usecase/SyncOrchestrator.kt`

### Local data

- [Data repositories](https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/data/repository/TransactionRepositoryImpl.kt): `app/src/main/java/com/example/moneymatev2/data/repository/TransactionRepositoryImpl.kt`
- [Room database](https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/data/local/AppDatabase.kt): `app/src/main/java/com/example/moneymatev2/data/local/AppDatabase.kt`

### Platform services

- [Receipt OCR](https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/data/ocr/MlKitOcrProcessor.kt): `app/src/main/java/com/example/moneymatev2/data/ocr/MlKitOcrProcessor.kt`
- [Reminder delivery](https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/data/reminder/AlarmReminderScheduler.kt): `app/src/main/java/com/example/moneymatev2/data/reminder/AlarmReminderScheduler.kt`
- [Cloud sync](https://github.com/tranhuyhoang69/do-an-tot-nghiep/blob/main/app/src/main/java/com/example/moneymatev2/data/remote/sync/CloudPullService.kt): `app/src/main/java/com/example/moneymatev2/data/remote/sync/CloudPullService.kt`

### Other components

- **User**
- **Cloud backend**

## Connections

- User → App entry: opens
- App entry → Navigation: starts
- Navigation → Finance screens: routes to
- Finance screens → Transaction entry: offers entry
- Transaction entry → Transaction rules: submits transaction
- Receipt scanning → Receipt OCR: requests scan
- Receipt OCR → Transaction entry: provides receipt data
- Budget screens → Budget overview: requests overview
- Statistics → Data repositories: reads finance data
- Account settings → Navigation: configures app
- Transaction rules → Data repositories: persists transaction
- Budget overview → Data repositories: reads budget data
- Recurring schedules → Data repositories: stores schedules
- Reminder rules → Data repositories: stores reminders
- Reminder rules → Reminder delivery: schedules alerts
- Data repositories → Room database: reads and writes
- Sync orchestration → Cloud sync: coordinates sync
- Cloud sync → Cloud backend: exchanges data
