Add AIDL definitions for the binder service in system server for ODP.

This will be published in system_server in U+.

Bug: 236174677
Test: TH
Change-Id: Iaff3641c6d958cbcaa257c7f6ed6bf86b379bde4
diff --git a/apex/Android.bp b/apex/Android.bp
index 2ad2609..b49b043 100644
--- a/apex/Android.bp
+++ b/apex/Android.bp
@@ -67,6 +67,7 @@
         // classes into an API surface, e.g. public, system, etc.. Doing so will
         // result in a build failure due to inconsistent flags.
         package_prefixes: [
+	    "android.app.ondevicepersonalization",
             "android.ondevicepersonalization",
 	    "com.android.ondevicepersonalization.internal",
         ],
diff --git a/framework/Android.bp b/framework/Android.bp
index 40dd587..3733179 100644
--- a/framework/Android.bp
+++ b/framework/Android.bp
@@ -52,6 +52,7 @@
         "ondevicepersonalization-java-defaults",
     ],
     permitted_packages: [
+        "android.app.ondevicepersonalization",
         "android.ondevicepersonalization",
         "com.android.ondevicepersonalization.internal",
     ],
diff --git a/framework/java/android/app/ondevicepersonalization/IOnDevicePersonalizationSystemService.aidl b/framework/java/android/app/ondevicepersonalization/IOnDevicePersonalizationSystemService.aidl
new file mode 100644
index 0000000..5a59293
--- /dev/null
+++ b/framework/java/android/app/ondevicepersonalization/IOnDevicePersonalizationSystemService.aidl
@@ -0,0 +1,28 @@
+/*
+ * Copyright (C) 2022 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.app.ondevicepersonalization;
+
+import android.app.ondevicepersonalization.IOnDevicePersonalizationSystemServiceCallback;
+import android.os.Bundle;
+
+/** @hide */
+interface IOnDevicePersonalizationSystemService {
+    void onRequest(
+            in Bundle params,
+            in IOnDevicePersonalizationSystemServiceCallback callback
+    );
+}
diff --git a/framework/java/android/app/ondevicepersonalization/IOnDevicePersonalizationSystemServiceCallback.aidl b/framework/java/android/app/ondevicepersonalization/IOnDevicePersonalizationSystemServiceCallback.aidl
new file mode 100644
index 0000000..e8b87f5
--- /dev/null
+++ b/framework/java/android/app/ondevicepersonalization/IOnDevicePersonalizationSystemServiceCallback.aidl
@@ -0,0 +1,24 @@
+/*
+ * Copyright (C) 2022 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.app.ondevicepersonalization;
+
+import android.os.Bundle;
+
+/** @hide */
+oneway interface IOnDevicePersonalizationSystemServiceCallback {
+    void onResult(in Bundle result);
+}
diff --git a/framework/java/android/app/ondevicepersonalization/OnDevicePersonalizationSystemServiceManager.java b/framework/java/android/app/ondevicepersonalization/OnDevicePersonalizationSystemServiceManager.java
new file mode 100644
index 0000000..674c4b3
--- /dev/null
+++ b/framework/java/android/app/ondevicepersonalization/OnDevicePersonalizationSystemServiceManager.java
@@ -0,0 +1,29 @@
+/*
+ * Copyright (C) 2022 The Android Open Source Project
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ *      http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package android.app.ondevicepersonalization;
+
+/**
+ * API for ODP service to interact with ODP System Service.
+ * @hide
+ */
+public class OnDevicePersonalizationSystemServiceManager {
+    /** Identifier for the ODP binder service in system_server. */
+    public static final String ON_DEVICE_PERSONALIZATION_SYSTEM_SERVICE =
+            "android.app.ondevicepersonalization.ondevicepersonalizationsystemservice";
+
+    private OnDevicePersonalizationSystemServiceManager() {}
+}