[MS54.3] Move NetworkStats to updatable sources

This CL builds NetworkStats related codes with the
connectivity module instead of platform.

Test: TH
Bug: 197717846
Change-Id: I4eeb7ea9cfc3139991caf0fc22474e0052a0391c
Merged-In: I4eeb7ea9cfc3139991caf0fc22474e0052a0391c
diff --git a/framework/Android.bp b/framework/Android.bp
index da16a8d..481f375 100644
--- a/framework/Android.bp
+++ b/framework/Android.bp
@@ -63,6 +63,7 @@
     srcs: [
         ":framework-connectivity-sources",
         ":net-utils-framework-common-srcs",
+        ":framework-connectivity-api-shared-srcs",
     ],
     aidl: {
         generate_get_transaction_name: true,
@@ -84,6 +85,7 @@
         "net-utils-device-common",
     ],
     static_libs: [
+        "framework-connectivity-protos",
         "modules-utils-build",
         "modules-utils-preconditions",
     ],
@@ -177,3 +179,23 @@
         "com.android.tethering",
     ],
 }
+
+// TODO: reduce size of this library; consider using
+// proto nano for example
+java_library {
+    name: "framework-connectivity-protos",
+    sdk_version: "module_current",
+    min_sdk_version: "30",
+    proto: {
+        type: "lite",
+    },
+    srcs: [
+        "proto/**/*.*",
+    ],
+   static_libs: ["libprotobuf-java-lite"],
+    apex_available: [
+        "com.android.tethering",
+    ],
+    lint: { strict_updatability_linting: true },
+    visibility: ["//visibility:private"],
+}