ManagedTestDeviceFactory

public class ManagedTestDeviceFactory
extends Object implements IManagedTestDeviceFactory

java.lang.Object
😎 com.android.tradefed.device.ManagedTestDeviceFactory


Factory zum Erstellen der verschiedenen Gerätetypen, die von Tf überwacht werden können

Zusammenfassung

Konstanten

int FRAMEWORK_CHECK_MAX_RETRY

long FRAMEWORK_CHECK_SLEEP_MS

Felder

protected static final String CHECK_PM_CMD

protected static final String EXPECTED_ERROR

protected static final String EXPECTED_RES

public static final String IPADDRESS_PATTERN

protected IDeviceMonitor mAllocationMonitor

protected IDeviceManager mDeviceManager

protected boolean mFastbootEnabled

Öffentliche Konstruktoren

ManagedTestDeviceFactory(boolean fastbootEnabled, IDeviceManager deviceManager, IDeviceMonitor allocationMonitor)

Öffentliche Methoden

IManagedTestDevice createDevice(IDevice idevice)

void setFastbootEnabled(boolean enable)

Geschützte Methoden

boolean checkFrameworkSupport(IDevice idevice)

Hilfsprogramm, das „true“ zurückgibt, wenn das Gerät Framework-Unterstützung hat.

CollectingOutputReceiver createOutputReceiver()

Erstellen Sie ein CollectingOutputReceiver.

IRunUtil getRunUtil()

Geben Sie die Standardinstanz IRunUtil zurück.

boolean isRemoteEnvironment()

Gibt „true“ zurück, wenn die Ausführung derzeit in einer Remote-Umgebung erfolgt.

boolean isTcpDeviceSerial(String serial)

Hilfsfunktion für das Gerät, wenn es sich um ein serielles Gerät von einem remote verbundenen Gerät handelt.

Konstanten

FRAMEWORK_CHECK_MAX_RETRY

protected static final int FRAMEWORK_CHECK_MAX_RETRY

Konstantenwert: 3. (0x00000003)

FRAMEWORK_CHECK_SLEEP_MS

protected static final long FRAMEWORK_CHECK_SLEEP_MS

Konstantenwert: 500 (0x00000000000001f4)

Felder

CHECK_PM_CMD

protected static final String CHECK_PM_CMD

EXPECTED_FEHLER

protected static final String EXPECTED_ERROR

EXPECTED_RES

protected static final String EXPECTED_RES

IPADDRESS_PATTERN

public static final String IPADDRESS_PATTERN

mAllocationMonitor

protected IDeviceMonitor mAllocationMonitor

mGerätemanager

protected IDeviceManager mDeviceManager

mFastbootEnabled

protected boolean mFastbootEnabled

Öffentliche Konstruktoren

ManagedTestDeviceFactory

public ManagedTestDeviceFactory (boolean fastbootEnabled, 
                IDeviceManager deviceManager, 
                IDeviceMonitor allocationMonitor)

Parameter
fastbootEnabled boolean

deviceManager IDeviceManager

allocationMonitor IDeviceMonitor

Öffentliche Methoden

Gerät erstellen

public IManagedTestDevice createDevice (IDevice idevice)

Parameter
idevice IDevice

Returns
IManagedTestDevice

setFastbootEnabled

public void setFastbootEnabled (boolean enable)

Parameter
enable boolean

Geschützte Methoden

checkFrameworkSupport

protected boolean checkFrameworkSupport (IDevice idevice)

Hilfsprogramm, das „true“ zurückgibt, wenn das Gerät Framework-Unterstützung hat.

Parameter
idevice IDevice

Returns
boolean

createOutputReceiver

protected CollectingOutputReceiver createOutputReceiver ()

Erstellen Sie ein CollectingOutputReceiver.

Returns
CollectingOutputReceiver

getRunUtil (GetRunUtil)

protected IRunUtil getRunUtil ()

Geben Sie die Standardinstanz IRunUtil zurück.

Returns
IRunUtil

isRemoteEnvironment

protected boolean isRemoteEnvironment ()

Gibt „true“ zurück, wenn die Ausführung derzeit in einer Remote-Umgebung erfolgt. Dadurch wird das Gerät geändert verhalten.

Returns
boolean

isTcpDeviceSerial

protected boolean isTcpDeviceSerial (String serial)

Hilfsfunktion für das Gerät, wenn es sich um ein serielles Gerät von einem remote verbundenen Gerät handelt. Das serielle Format des TCP-Geräts ist :

Parameter
serial String

Returns
boolean