ManagedRemoteDevice
public class ManagedRemoteDevice
extends TestDevice
implements ITestLoggerReceiver
java.lang.Object | |||
↳ | com.android.tradefed.device.NativeDevice | ||
↳ | com.android.tradefed.device.TestDevice | ||
↳ | com.android.tradefed.device.cloud.ManagedRemoteDevice |
在虚拟机内部运行的设备,我们通过VM内的Tradefed实例进行远程管理。
概要
公共建设者 | |
---|---|
ManagedRemoteDevice (IDevice device, IDeviceStateMonitor stateMonitor, IDeviceMonitor allocationMonitor) 创建一个 |
公开方法 | |
---|---|
TestDeviceOptions | getOptions () 在尝试进行远程设置之前,请覆盖基本的获取方法,以便能够解析动态选项。 |
GceAvdInfo | getRemoteAvdInfo () 返回描述远程实例的 |
void | postInvocationTearDown (Throwable exception) |
void | preInvocationSetup (IBuildInfo info) |
void | setTestLogger (ITestLogger testLogger) |
受保护的方法 | |
---|---|
long | getCurrentTime () 返回当前系统时间。 |
void | launchGce () 根据构建信息启动实际的gce设备。 |
公共建设者
ManagedRemoteDevice
public ManagedRemoteDevice (IDevice device, IDeviceStateMonitor stateMonitor, IDeviceMonitor allocationMonitor)
创建一个ManagedRemoteDevice
。
参量 | |
---|---|
device | IDevice :关联的IDevice |
stateMonitor | IDeviceStateMonitor :要使用的IDeviceStateMonitor 机制 |
allocationMonitor | IDeviceMonitor : IDeviceMonitor 通知分配状态更改。 |
公开方法
getOptions
public TestDeviceOptions getOptions ()
在尝试进行远程设置之前,请覆盖基本的获取方法,以便能够解析动态选项。
退货 | |
---|---|
TestDeviceOptions |
postInvocationTearDown
public void postInvocationTearDown (Throwable exception)
参量 | |
---|---|
exception | Throwable |
preInvocationSetup
public void preInvocationSetup (IBuildInfo info)
参量 | |
---|---|
info | IBuildInfo |
投掷 | |
---|---|
DeviceNotAvailableException | |
TargetSetupError |
setTestLogger
public void setTestLogger (ITestLogger testLogger)
参量 | |
---|---|
testLogger | ITestLogger |
受保护的方法
getCurrentTime
protected long getCurrentTime ()
返回当前系统时间。暴露于测试。
退货 | |
---|---|
long |
launchGce
protected void launchGce ()
根据构建信息启动实际的gce设备。
投掷 | |
---|---|
TargetSetupError |