How akhilesh002/mindmap_assignment works
Project Type and Purpose
• This is a cross-platform mobile application built with Flutter, targeting both Android and iOS.
• Its core purpose is to allow a user to log in (offline, using Hive as a local database), view a dashboard, send money, and see transaction history.
• No external APIs are used; all data persists locally and is cleared on logout.
File Structure Analysis
• android/ and ios/ directories contain platform-specific boilerplate for native embedding.
• lib/ holds the Dart source, subdivided by feature under ui/features. Each feature has its own screen (UI) and controller (business logic).
• lib/util contains shared utilities.
• pubspec.yaml declares dependencies (Hive for local storage, probably GetX or Provider for state management).
• test/ holds widget tests.
Key Architectural Patterns
• Feature-based modular layout: each feature folder encapsulates its screen(s), controller, models, and widgets.
• MVC/MVVM-style separation:
• Screens (View)
• Controllers (ViewModel/Controller)
• Models (Data layer)
• Local persistence layer via Hive (no remote service layer presently).
Main Components
A. Presentation Layer
– Flutter Engine
– Widgets & Screens (SplashScreen, LoginScreen, DashboardScreen, SendMoneyScreen, TransactionsScreen)
B. Business Logic Layer
– Controllers (splash_controller, login_controller, dashboard_controller, send_money_controller, transactions_controller)
C. Data Layer
– Models (transaction_model.dart & generated adapters)
D. Platform Layer
– Android platform integration (MainActivity.kt, Gradle config)
– iOS platform integration (AppDelegate.swift, Xcode project)
E. Asset Layer
Relationships & Data Flow
2. Flutter engine loads SplashScreen → splash_controller checks Hive for persisted session
3. If not logged in → navigate to LoginScreen → login_controller validates static credentials → on success, write session to Hive
4. Navigate to DashboardScreen → dashboard_controller reads summary data from Hive
5. Send Money: send_money_controller writes a new transaction record to Hive
6. TransactionsScreen: transactions_controller queries Hive, maps data to transaction_model, displays list
Important Architectural Notes
• All data flows occur within the device (no network calls).
• Controllers serve as the single source of truth for each feature.
• Hive adapters (transaction_model.g.dart) handle serialization/deserialization.
• Feature folders enforce clear boundaries, making the app easily extensible for future remote APIs.
– Component names and roles
– Feature boundaries (dashboard, login, send money, transactions)
– Platform integration points (Android/iOS hosts)