The document discusses the anatomy of an Android application project structure. It is divided into the main parts: App, Gradle Scripts, and folders within App - Manifests, Java, and Res. The Manifests folder contains the AndroidManifest.xml file which describes app components, permissions, and other metadata. The Java folder stores Java source code files. The Res folder organizes app resources like images, layouts, icons into type-specific directories like Drawable, Layout, Mipmap and Values.
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
Anatomy Of An Adroid Application Lecture 3.pptx
1. ANATOMY OF AN ANDROID APPLICATION
• App(app)
Manifests
Java
res
• Gradle Scripts
2. APP
• Now that you have created your first Hello World Android application, it is time to
discus the inwards of the Android project and examine all the parts that make
everything work. First, note the various files that make up an Android project in the
Package Explorer in left side bar of Android studio.
• The App folder contains three subfolders (manifests, java and res) that make up your
application. They are divided so that it should be fairly easy to determine which
resources go in which folder.
3. MANIFESTS
Every app project must have an AndroidManifest.xml file (with precisely that name) at the root of the
Project Source Set. The manifest file describes essential information about your app to the
Android build tools, the Android operating system, and Google Play.
It acts as an intermediator between android OS and our application.
Among many other things, the manifest file is required to declare the following:
The components of the app, which include all activities, services, broadcast receivers,
and content providers.
The permissions that the app needs in order to access protected parts of the system or
other apps.
4. JAVA
• This is the folder in your project where you will be storing all of the source code files
written in Java programming language.
• A MainActivity.java is automatically created in this folder by Android Studio. All of your
classes will be available here, and Android Studio will even bundle together the
package path so that you can work with the files without having to drill down through
the folders that make up your package.
5. RES
• App resources such as bitmaps and layouts are organized into type-specific directories
inside each module's res/ directory.
It Further Contains
Drawable
Layout
Mipmap
Values
6. DRWABLE
• It contains the different type of images used for the development of the application. We need
to add all the images in drawable folder for the application development.It Further Contains.
• Bitmap file
Android supports bitmap files in three formats: .png (preferred), .jpg (acceptable), .gif
(discouraged).
• Shape drawable
An XML file that contains the values of geometric shape, color, size, and similar attributes.
7. LAYOUT
• The layout folder contains XML files used for your layouts. These file are used to set up the
layout for your Activity and is used for basic alignment of your layouts, components, widgets,
and similar resources that are used for the UI of your application.
• activity_main.xml is automatically created in this folder by Android Studio. Layout folder may
have multiple layout folders to handle different devices. This can be helpful when working
with layouts that need to be adjusted for devices with more or less screen space available.
8. MIPMAP
The mipmap folder contains the launcher icon files for the app. A launcher icon is a graphic
that represents your app to users. The mipmap folder was introduced in Android 4.3.
9. VALUES
• values folder is used to store the values for the resources that are used in many Android
projects to include features of color, styles, dimensions etc.
Below explained basic file, contained in the res/values folder:
colors.xml: The colors.xml is an XML file which is used to store the colors for the resources.An
Android project contains 3 essential colours namely:
colorPrimary
colorPrimaryDark
colorAccent