DeviceRuntimeException
public
class
DeviceRuntimeException
extends HarnessRuntimeException
| java.lang.Object | ||
| ↳ | com.android.tradefed.error.HarnessRuntimeException | |
| ↳ | com.android.tradefed.device.DeviceRuntimeException | |
当设备操作未产生预期结果时抛出。
例如:“pm list users”预计会返回用户列表,如果未能返回,则应作为 DeviceRuntimeException 引发,因为出现了严重问题。
摘要
公共构造函数 | |
|---|---|
DeviceRuntimeException(String msg, ErrorIdentifier errorId)
|
|
DeviceRuntimeException(String msg, Throwable t, ErrorIdentifier errorId)
|
|
公共构造函数
DeviceRuntimeException
public DeviceRuntimeException (String msg,
ErrorIdentifier errorId)| 参数 | |
|---|---|
msg |
String:错误的描述性错误消息。 |
errorId |
ErrorIdentifier:用于对异常进行分类的 ErrorIdentifier。 |
DeviceRuntimeException
public DeviceRuntimeException (String msg,
Throwable t,
ErrorIdentifier errorId)| 参数 | |
|---|---|
msg |
String:错误的描述性错误消息 |
t |
Throwable:应封装在 DeviceRuntimeException 中的 Throwable。 |
errorId |
ErrorIdentifier:用于对异常进行分类的 ErrorIdentifier。 |