summaryrefslogtreecommitdiff
path: root/telephony/java/android/service/euicc/EuiccService.java
diff options
context:
space:
mode:
Diffstat (limited to 'telephony/java/android/service/euicc/EuiccService.java')
-rw-r--r--telephony/java/android/service/euicc/EuiccService.java26
1 files changed, 26 insertions, 0 deletions
diff --git a/telephony/java/android/service/euicc/EuiccService.java b/telephony/java/android/service/euicc/EuiccService.java
index bc6a9e848e2a..ef11f469d9a0 100644
--- a/telephony/java/android/service/euicc/EuiccService.java
+++ b/telephony/java/android/service/euicc/EuiccService.java
@@ -34,6 +34,8 @@ import android.telephony.euicc.EuiccInfo;
import android.telephony.euicc.EuiccManager.OtaStatus;
import android.util.Log;
+import java.io.PrintWriter;
+import java.io.StringWriter;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.util.concurrent.LinkedBlockingQueue;
@@ -583,6 +585,13 @@ public abstract class EuiccService extends Service {
public abstract int onRetainSubscriptionsForFactoryReset(int slotId);
/**
+ * Dump to a provided printWriter.
+ */
+ public void dump(@NonNull PrintWriter printWriter) {
+ printWriter.println("The connected LPA does not implement EuiccService#dump()");
+ }
+
+ /**
* Wrapper around IEuiccService that forwards calls to implementations of {@link EuiccService}.
*/
private class IEuiccServiceWrapper extends IEuiccService.Stub {
@@ -834,5 +843,22 @@ public abstract class EuiccService extends Service {
}
});
}
+
+ @Override
+ public void dump(IEuiccServiceDumpResultCallback callback) throws RemoteException {
+ mExecutor.execute(new Runnable() {
+ @Override
+ public void run() {
+ try {
+ final StringWriter sw = new StringWriter();
+ final PrintWriter pw = new PrintWriter(sw);
+ EuiccService.this.dump(pw);
+ callback.onComplete(sw.toString());
+ } catch (RemoteException e) {
+ // Can't communicate with the phone process; ignore.
+ }
+ }
+ });
+ }
}
}