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()
覆寫基本 getter,以便在嘗試執行遠端設定之前,先解析動態選項。 |
GceAvdInfo
|
getRemoteAvdInfo()
傳回描述遠端執行個體的 |
void
|
postInvocationTearDown(Throwable exception)
|
void
|
preInvocationSetup(IBuildInfo info, MultiMap<String, String> attributes)
|
void
|
setTestLogger(ITestLogger testLogger)
|
受保護的方法 | |
|---|---|
long
|
getCurrentTime()
傳回目前的系統時間。 |
void
|
launchGce()
根據建構資訊啟動實際的 gce 裝置。 |
公用建構函式
ManagedRemoteDevice
public ManagedRemoteDevice (IDevice device,
IDeviceStateMonitor stateMonitor,
IDeviceMonitor allocationMonitor)| 參數 | |
|---|---|
device |
IDevice:相關聯的 IDevice |
stateMonitor |
IDeviceStateMonitor:要使用的 IDeviceStateMonitor 機制 |
allocationMonitor |
IDeviceMonitor:用於通知分配狀態變更的 IDeviceMonitor。 |
公用方法
getOptions
public TestDeviceOptions getOptions ()
覆寫基本 getter,以便在嘗試執行遠端設定之前,先解析動態選項。
| 傳回 | |
|---|---|
TestDeviceOptions |
|
postInvocationTearDown
public void postInvocationTearDown (Throwable exception)
| 參數 | |
|---|---|
exception |
Throwable |
preInvocationSetup
public void preInvocationSetup (IBuildInfo info,
MultiMap<String, String> attributes)
| 參數 | |
|---|---|
info |
IBuildInfo |
attributes |
MultiMap |
| 擲回 | |
|---|---|
DeviceNotAvailableException |
|
TargetSetupError |
|
setTestLogger
public void setTestLogger (ITestLogger testLogger)
| 參數 | |
|---|---|
testLogger |
ITestLogger |
受保護的方法
getCurrentTime
protected long getCurrentTime ()
傳回目前的系統時間。已公開供測試。
| 傳回 | |
|---|---|
long |
|
launchGce
protected void launchGce ()
根據建構資訊啟動實際的 gce 裝置。
| 擲回 | |
|---|---|
TargetSetupError |
|