Directory Structure of Android programs
-
- SRC: Source code organization and Management directory.
- Gen: The automatically generated directory generates some important files, such as R.java, which are not normally required for us to write.
- Assets: This directory file will not be compiled into binary encoding, used for playback of audio and video, text and other raw format files.
- Bin: Used to store compiled Java files and apk files.
- Libs: Store the Android source package or the source package that needs to be introduced.
- Res: the directory where the program resources are located, including images, values and other types of resources.
- Androidmanifest.xml: Program configuration file, which describes the program information to the system.
Res directory
This directory is used to store the various resources of Android programs and is very important for managing resources and adapting the Android UI
Drawable-xxx
An XML file that holds a drawing resource such as a bitmap (Bitmap files) (. png,.9.png,.jpg,.gif) or a status list (state lists), animation (Animation drawables), Graphics (shapes), and so on.
Equivalent to a picture resource in a Web page. Where-xxx is used to fit the screen with different pixel densities
Layout
The directory's XML file is used to describe an interface structure for an Android UI interface (Activity) or a System Desktop component (Appwidget). Corresponds to the HTML structure of the Web page.
Menu
The Main.xml file in this directory is used to define the pop-up menu structure at the bottom of Android.
Values-xxx
For storing XML files that define various: character values, color values, values, styles, etc. For example, Dimens.xml is used to define each dimension value, Strings.xml is used to define the text, Colors.xml is used to define each color value, the most important of which styles.xml is used to define the visual style of the view element (CSS equivalent to the Web page). The-XXX function is also suitable for Android
Androidmanifest.xml file
Each Android application has a androidmanifest.xml file in the root directory that is used to provide the system with the information it needs to provide before the program runs. This file mainly contains the following information:
-
- Names the Java package name for the app, which is the unique identity of the app.
- Describe the composition of the application, including Activity,services.
- Declares the permissions that the app must have to access the protected part of the API.
- Declares the environment configuration information that is required when the app runs.
- Declare the minimum version level of the system Android API that your app requires.
- Lists the libraries that the app needs to link to.
Http://www.ui.cn/detail/35893.html
Introduction to the Android program directory and UI