10.26 the beginning of the day: you insist, look at the finishing
An application is usually composed of multiple activity, which are loosely coupled relationships. In particular, there is an activity as the main activity of the app, which is presented to the user when the app is first launched.
Each ay can start another to show a different action, whenever a test ay starts, the previous opportunity stops, but the system keeps it in the back stack. When an explicit new ay starts, it is pushed to the top of the stack to get the user focus.
When an ay is stopped due to another AY drive, the change in this state is notified by the callback function of the AY's life cycle. Depending on the state, Ay may receive a number of callback functions, each of which will give you the opportunity to handle a particular job in response to a change in state. For example, when stop, your AY should release large objects such as network connections and database connections. When Ayresume, you can re-request the necessary resources and restore the original interrupted action. These state transitions are part of the AY life cycle.
Create Ay:
To create an ay, you must create a subclass of activity, or a subclass of an existing subclass of activity. In your subclass, you must implement the callback functions that the system needs to change between states during the life cycle, such as create, stop, restore, or destroy. The two most important callback functions are:
OnCreate (): You have to implement this method. When you create AY, the system calls it. When implemented you need to initialize the important components of your ay. Most importantly, here you have to call Setcontentview () to define the layout of the Ay UI.
Api-guides translation of my study notes------appcomponent_activites