Human-readable XML on Ravenwood.
We had temporarily been using the binary XML implementation in all
situations, but this change brings in the existing `kxml2-android`
library to offer reading/writing of human-readable XML. We also
use the upstream SAX parser to offer an event-based parser.
In all cases we carefully keep the existing XML libraries in place
untouched on physical devices to avoid regressions.
Bug: 324417456
Test: atest CtsUtilTestCasesRavenwood
Test: atest FrameworksCoreTestsRavenwood
Test: atest FrameworksUtilTestsRavenwood
Change-Id: I2effc7fca5c586968658073f9652d13cf50a2c66
diff --git a/ravenwood/Android.bp b/ravenwood/Android.bp
index 1ac69f6..35ce481 100644
--- a/ravenwood/Android.bp
+++ b/ravenwood/Android.bp
@@ -58,11 +58,14 @@
visibility: ["//visibility:public"],
}
-java_host_for_device {
- name: "core-xml-for-device",
- libs: [
- "core-xml-for-host",
+java_library {
+ // Prefixed with "200" to ensure it's sorted early in Tradefed classpath
+ // so that we provide a concrete implementation before Mainline stubs
+ name: "200-kxml2-android",
+ static_libs: [
+ "kxml2-android",
],
+ visibility: ["//frameworks/base"],
}
java_host_for_device {
diff --git a/ravenwood/framework-minus-apex-ravenwood-policies.txt b/ravenwood/framework-minus-apex-ravenwood-policies.txt
index 0229611..2eef0cd 100644
--- a/ravenwood/framework-minus-apex-ravenwood-policies.txt
+++ b/ravenwood/framework-minus-apex-ravenwood-policies.txt
@@ -89,6 +89,7 @@
# Internals
class com.android.internal.util.FileRotator stubclass
+class com.android.internal.util.FastXmlSerializer stubclass
class com.android.internal.util.HexDump stubclass
class com.android.internal.util.MessageUtils stubclass
class com.android.internal.util.Preconditions stubclass