First, Android development experience:
1. The project should be created with care:
1) Enter Com.bignerdranch.android.geoquiz at the package name and the package name follows the "DNS inversion" convention.
That is, after the domain name of the enterprise organization or company is reversed, the name is applied on the tail attachment. Adherence to this Convention guarantees the uniqueness of the package name, so that
Different apps from the same device and Google Play Store can be distinguished.
2) named Quizactivity in Activity name, the system automatically generates activity_quiz.xml in Layout name, suggesting
Follow such a good naming habit.
2. User interface Design:
buttons, text input controls, selection boxes, and so on are components
<LinearLayoutxmlns:android= "Http://schemas.android.com/apk/res/android"
Android:layout_width= "Match_parent"Match_parent is as much space as the filling unit
Android:layout_height= "Match_parent"android:gravity= "center" //gravity where the control element appears in the control android:orientation= "vertical" > <TextView
Android:layout_width= "Wrap_content"//wrap_content is automatic layout based on content
Android:layout_height= "Wrap_content"
Android:padding= "24DP"//padding Specifies the distance between the element's border and the element's content
Android:text= "@string/question_text" /> <LinearLayout
Android:layout_width= "Wrap_content"
Android:layout_height= "Wrap_content"
Android:orientation= "Horizontal" > //orientation (directional) is the control of the layout order, vertical (vertical) or horizontal (horizontal) <Button
Android:layout_width= "Wrap_content"
Android:layout_height= "Wrap_content"
Android:text= "@string/true_button" /> <Button
Android:layout_width= "Wrap_content"
Android:layout_height= "Wrap_content"
Android:text= "@string/false_button" /> </LinearLayout>
</LinearLayout>
2.MVC:
M stands for model object: Java file, which does not care about the user interface, only exists to store and manage application data
V represents the View object: Everything can be displayed on the screen, that is, the view object, like the XML layout file, etc.
C for Controller (Control object): is a specific instance of the activity class in the Activity,android SDK, which manages the user's interaction with the information screen.
2.
Android Development Essay One