android webview setDatabasePath deprecated

后端 未结 1 750
挽巷
挽巷 2020-12-18 02:19

This method was deprecated in API level 19 Database paths are managed by the implementation and calling this method will have no effect.

I use

相关标签:
1条回答
  • 2020-12-18 02:48

    API level 19 means Android 4.4 KitKat, in which the browser engine is switched from Android webkit to chromium webkit, with almost all the original WebView APIs wrapped to the counterparts of chromium webkit.

    That means most of the implementations of WebView APIs are different from Android 4.3 and before, incuding the database storage API. That also means since Android 4.4 developers cannot (or don't have to) assign an alternative db path; all this is handled by Android by default.

    managed by the implementation now means the database storage path is handled by chromium webkit engine by default, while before Android 4.4 it's handled in android.webkit in framework layer which needs to be set.

    0 讨论(0)
提交回复
热议问题