How jack-d1/lightmeter works
Main Components
• Android Application Module ("app"): This is the core of the project and contains all the application code, resources, and manifest.
• Activities (UI Components): The project includes multiple activities such as MainActivity, AperturePriorityActivity, ShutterPriorityActivity, CustomValuesActivity, and SettingsActivity. Each represents different screens or modes in the app.
• Resources: Organized under app/src/main/res (layouts, drawables, values, XML configurations) which form the visual and configuration layer of the app.
• Android Manifest: Located in app/src/main/AndroidManifest.xml, it defines key components like activities and permissions.
• Build and Dependency Management: Gradle configuration files (build.gradle, settings.gradle, gradle.properties, and the Gradle wrapper) control the build process and specify dependencies.
• Testing: The project includes an androidTest directory for instrumentation tests that verify app behavior on devices.
• CI/CD Integration: The .github/workflows folder with main.yml implies the use of GitHub Actions to automate build/test processes.
Relationships and Interaction
• The Activities interact with one another; for example, MainActivity likely serves as a landing screen which then routes to either Aperture or Shutter Priority modes.
• UI components (layouts in the res/layout folders) feed data into the activities and vice versa.
• The Android Manifest ties together the app’s components providing declarations, intent filters, and permissions.
• Gradle build files aggregate dependencies, compile options, and resource linking, ensuring that all components integrate seamlessly.
• Instrumentation tests in androidTest simulate user interaction with these activities, ensuring the user experience remains intact.
Detailed Step-by-Step Construction
a. Start by drawing a top-level block labeled “Light Meter Application (Android)” and subdivide it into core subsystems.
c. A block representing “Resources”, linking it to UI components to denote usage of layouts, drawables, and string values.
d. Insert a block for “Configuration & Build”, including the Gradle build files, and highlight the GitHub Actions CI/CD process.
e. “Testing” block which connects with the application core to run instrumentation tests.