First, let's look at the Network Statement:
Android. Intent. Action. Main determines the applicationProgramThe first
Activity Android. Intent. Category. launcher determines whether the application is displayed in the program list.
After the experiment, I found a problem?
Main and launcher are not independent tasks;
Which of the following statements is true?
My test result is that if an application does not have a launcher, the APK can still be installed on the device, but cannot be seen in the desktop icon. If launcher is set for the activity and main is set at the same time, the activity can be displayed in the program icon. If main is not set, you do not know which activity to start, therefore, no icons appear. It can be seen that main refers to the activity to start after clicking the icon. Of course, main can be set for multiple activities, but only set main without setting launcher, still cannot enter the activity. It can be seen that the main and launcher settings make sense at the same time. If multiple activities are set at the same time, two icons will appear, respectively, first entering different activities. For example: lift_cycles 01 and lift_cycles 02
<Activity Android: Name = ". life_cyclesactivity "Android: Label =" lift_cycles 01 "> <intent-filter> <action Android: Name =" android. intent. action. main "/> <category Android: Name =" android. intent. category. launcher "/> </intent-filter> </activity> <activity Android: Name =" life_cyclesactivity02 "Android: label = "lift_cycles 02"> <intent-filter> <action Android: Name = "android. intent. action. main "/> <category Android: Name =" android. intent. category. launcher "/> </intent-filter> </activity>