RecyclerView vs. ListView

前端 未结 16 2043
名媛妹妹
名媛妹妹 2020-11-22 06:07

From android developer (Creating Lists and Cards):

The RecyclerView widget is a more advanced and flexible version of ListView.

<
16条回答
  •  半阙折子戏
    2020-11-22 06:15

    I want just emphasize that RecyclerView is a part of the compatibility package. It means that instead of using the feature and code from OS, every application carries own RecyclerView implementation. Potentially, a feature similar to RecyclerView can be a part of a future OS and using it from there can be beneficial. For example Harmony OS will be out soon.The compatibility package license can be changed in the future and it can be an implication. Summery of disadvantages:

    1. licensing
    2. a bigger foot print especially as a part of many apps
    3. losing in efficiency if some feature coming from OS can be there

    But on a good note, an implementation of some functionality, as swiping items, is coming from RecyclerView.

    All said above has to be taken in a consideration.

提交回复
热议问题