This section takes MyRainmaker App as an example to introduce the
structure of an Android project. There are two folders in the root
Gradle Scripts. The
app folder contains all the code and resources to develop the smartphone app, and the
Gradle Scripts folder contains scripts related to Gradle compilation. The structure of this Android project is shown in Figure 10.1.
app folder contains three subfolders:
manifests: Stores app configurations, including name, version, SDK, and permissions.
java: Mainly stores source code and test code.
res: Stores all project resources.
Gradle Scripts folder contains
build.gradle (two files with the
build.gradle: Compiles the app with Gradle.
gradle-wrapper.properties: Configures the Gradle version.
proguard-rules.pro: Configures proguard rules to obfuscate the code.
gradle.properties: Configures Gradle-related global properties.
settings.gradle: Configures relevant Gradle scripts.
local.properties: Configures the path to the SDK/NDK.