OSDN Git Service

WebView: clarify docs regarding base64 encoding
authorNate Fischer <ntfschr@google.com>
Fri, 5 Jan 2018 05:57:33 +0000 (21:57 -0800)
committerNate Fischer <ntfschr@google.com>
Fri, 5 Jan 2018 05:57:33 +0000 (21:57 -0800)
commit867d10944d7d2bcf38609629edfc7e75d68a0e34
tree7626afc8f71759fa8975c1c76355b87a8fb317e8
parent670c338751ce3f8175e84845f20bd99ea12e5f1d
WebView: clarify docs regarding base64 encoding

Docs change only, no change to logic.

This CL provides a better loadData() example, using base64 encoding.
This uses the Base64 class already provided by Android to automatically
handle the encoding.

This also changes the percent-encoding docs to:

 * Link to the official RFC
 * No longer provide examples of characters to encode (one example was
   incorrect, '\' is not %27)

Bug: 70555565
Test: make docs (manually verify things look good)
Test: I built a sample app and tested Base64#encodetoString to make sure the flags are correct
Change-Id: If9f810e6b568efdc5d1ad84ac64f2abf3788f40b
core/java/android/webkit/WebView.java