Package android.os
Class RemoteException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- android.util.AndroidException
-
- android.os.RemoteException
-
- All Implemented Interfaces:
java.io.Serializable
- Direct Known Subclasses:
DeadObjectException
public class RemoteException extends AndroidException
Parent exception for all Binder remote-invocation errors- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description RemoteException()RemoteException(java.lang.String message)RemoteException(java.lang.String message, java.lang.Throwable cause, boolean enableSuppression, boolean writableStackTrace)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.RuntimeExceptionrethrowAsRuntimeException(){}java.lang.RuntimeExceptionrethrowFromSystemServer()Rethrow this exception when we know it came from the system server.
-
-
-
Method Detail
-
rethrowAsRuntimeException
public java.lang.RuntimeException rethrowAsRuntimeException()
{}
-
rethrowFromSystemServer
public java.lang.RuntimeException rethrowFromSystemServer()
Rethrow this exception when we know it came from the system server. This gives us an opportunity to throw a nice cleanDeadSystemExceptionsignal to avoid spamming logs with misleading stack traces.Apps making calls into the system server may end up persisting internal state or making security decisions based on the perceived success or failure of a call, or any default values returned. For this reason, we want to strongly throw when there was trouble with the transaction.
-
-