集群设备监控

public class ClusterDeviceMonitor
extends LabResourceDeviceMonitor

java.lang.Object
com.google.dualhomelab.monitoringagent.resourcemonitoring.LabResourceServiceGrpc.LabResourceServiceImplBase
com.android.tradefed.monitoring.LabResourceDeviceMonitor
com.android.tradefed.cluster.ClusterDeviceMonitor


向 Tradefed 集群服务报告结果的IDeviceMonitor实现。

概括

公共构造函数

ClusterDeviceMonitor ()

公共方法

void notifyDeviceStateChange (String serial, DeviceAllocationState oldState, DeviceAllocationState newState)

IDeviceMonitor发出设备状态已更改的信号。

void run ()

设置监视器的所有 @Option 字段后将调用的方法。

void setDeviceLister ( IDeviceMonitor.DeviceLister lister)

允许设置DeviceLister

void stop ()

当监视器需要停止时将调用的方法。

公共构造函数

集群设备监控

public ClusterDeviceMonitor ()

公共方法

通知设备状态改变

public void notifyDeviceStateChange (String serial, 
                DeviceAllocationState oldState, 
                DeviceAllocationState newState)

IDeviceMonitor发出设备状态已更改的信号。监视器实现应该限制它们在此方法中执行的处理量和 IDeviceManager/DeviceLister 交互。

参数
serial String

oldState DeviceAllocationState

newState DeviceAllocationState

跑步

public void run ()

设置监视器的所有 @Option 字段后将调用的方法。

设置设备列表

public void setDeviceLister (IDeviceMonitor.DeviceLister lister)

允许设置DeviceLister 。成功尝试设置列表器后,实现可能会放弃所有后续尝试。

参数
lister IDeviceMonitor.DeviceLister

停止

public void stop ()

当监视器需要停止时将调用的方法。