How to turn off the Android developer mode! What do you ask for an Android interview with a monthly salary of 20k+? In-depth good text

In order to help Android developers develop apps faster and better, Google has launched a series of components, which are packaged into a whole called Android Jetpack. The components it contains are shown in the following figure:

The old support package is integrated into Jetpack, such as AppCompat of the Foundation module in the above figure. After integration, the package name has been modified, all starting with androidx. The migration tool provided by Android Studio (Refactor> Migrate to AndroidX) can replace the old package name in the source code with the new one, but if the product that Maven depends on has not been migrated to AndroidX, you also need to configure a tool-Jetifier

1. How does the problem of picture misalignment in ListView arise?
2. Do you know about hybrid development?
3. Know what hybrid development methods are? Tell their advantages and disadvantages and their respective usage scenarios? (Answer: For example: RN, weex, 4.H5, applet, WPA, etc. It is still very useful to know some front-end js etc. for Android);
5. What are the processing techniques for screen adaptation?
6. Server only Provide a data receiving interface, how to ensure the orderly arrival of data under multi-thread or multi-process conditions?
7. Understanding of dynamic layout
8. How to remove duplicate code?
9. Draw the general architecture of Android.
10 The difference between
Recycleview and ListView. 11. The principle and solution of ListView image loading disorder

ListView itemCache mechanism: In order to make the performance better, the ListViewline item (the View corresponding to a line) will be cached. Get the item of each line ListViewthrough the getViewfunction of the adapter .

During sliding

1) If a line item has been slid out of the screen, if the item is not in the cache, put it into the cache, otherwise update the cache;
2) Before getting the line item that slid into the screen, it will first determine whether there is an item available in the cache, if so , convertViewPassed as a parameter to adaptergetView.

Problems:

1) The row item picture is repeated, and the current row item shows the picture of a previous row item.
For example, ListViewsliding to the second line will load a certain picture asynchronously, but the loading is very slow. During the loading process, the picture listViewhas been slid to the 14th line, and the picture is loaded during the sliding process, and the second line is no longer on the screen. According to the cache described above The principle is that the view in the second row may be reused in the 14th row, so what we see is that the 14th row displays the picture that should belong to the second row, causing the display to be repeated.

2) The line item picture flickers
If the picture on line 14 is loaded soon, so we see that the picture on line 2 is displayed first on line 14, and immediately displays our own picture for overlay, causing flickering confusion.

Solution
Through the above analysis, we know that the cause of the confusion is caused by asynchronous loading and object reuse. If you getViewcan give the object an identifier every time , when the asynchronous loading is completed, compare whether the identifier is consistent with the identifier of the current row item. It will be displayed, otherwise it will not be processed.

12. Dynamic permission adaptation scheme, the concept of permission group
13. Why does the Android system design ContentProvider?
14.
Does the drop-down status bar affect the life cycle of the activity? 15. If a network request is made during onStop, how to resume during onResume?
16. What should I pay attention to when using Bitmap?
17.Bitmap's recycler()
18. The main steps to turn on the camera in
Android. 19. ViewPager usage details, how to set it to initialize only the current Fragment each time, and not the others?
20. The click event is intercepted, but I want to pass it to the View below, how to do it?
21. The realization of the main page of
WeChat 22. The principle of the small red dot on
WeChat 23. Introduction to CAS

At last

Android learning is a long road. What we have to learn is not only the superficial technology, but also the bottom layer and understand the following principles. Only in this way can we improve our competitiveness. In today's competitive world Foothold in.

Life cannot be smooth sailing. There are peaks and valleys. We must believe that those who cannot defeat us will eventually make us stronger and become our own ferrymen.

I put the most important and popular learning direction materials on Android that I have compiled during this time on my GitHub , which also contains self-learning programming routes in different directions, interview questions/face-to-face, and series of technical articles.

%AA%EF%BC%81.md) , there are also self-learning programming routes in different directions, a collection of interview questions/faces, and a series of technical articles.

The resources are continuously updated, and everyone is welcome to learn and discuss together.

Guess you like

Origin blog.csdn.net/chayel123/article/details/112950488