CompanionAllocator
public
abstract
class
CompanionAllocator
extends BaseTargetPreparer
| java.lang.Object | ||
| ↳ | com.android.tradefed.targetprep.BaseTargetPreparer | |
| ↳ | com.android.tradefed.targetprep.companion.CompanionAllocator | |
负责分配和释放配套设备的基类
应实现 getCompanionDeviceSelectionOptions() 以描述分配配套设备所需的条件
摘要
公共构造函数 | |
|---|---|
CompanionAllocator()
|
|
公共方法 | |
|---|---|
void
|
setUp(ITestDevice device, IBuildInfo buildInfo)
设置设备。 |
void
|
tearDown(ITestDevice device, IBuildInfo buildInfo, Throwable e)
|
受保护的方法 | |
|---|---|
abstract
DeviceSelectionOptions
|
getCompanionDeviceSelectionOptions()
描述配套设备的 |
公共构造函数
CompanionAllocator
public CompanionAllocator ()
公共方法
setUp
public void setUp (ITestDevice device, IBuildInfo buildInfo)
设置设备。
此方法的内部实现将请求配套设备并进行分配。
| 参数 | |
|---|---|
device |
ITestDevice |
buildInfo |
IBuildInfo |
| 抛出 | |
|---|---|
BuildError |
|
DeviceNotAvailableException |
|
TargetSetupError |
|
tearDown
public void tearDown (ITestDevice device, IBuildInfo buildInfo, Throwable e)
| 参数 | |
|---|---|
device |
ITestDevice |
buildInfo |
IBuildInfo |
e |
Throwable |
| 抛出 | |
|---|---|
DeviceNotAvailableException |
|
受保护的方法
getCompanionDeviceSelectionOptions
protected abstract DeviceSelectionOptions getCompanionDeviceSelectionOptions ()
描述配套设备的 DeviceSelectionOptions
| 返回 | |
|---|---|
DeviceSelectionOptions |
|