ManagedTestDeviceFactory

public class ManagedTestDeviceFactory
extends Object implements IManagedTestDeviceFactory

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


Factory untuk membuat berbagai jenis perangkat yang dapat dipantau oleh Tf

Ringkasan

Konstanta

int FRAMEWORK_CHECK_MAX_RETRY

long FRAMEWORK_CHECK_SLEEP_MS

Kolom

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

Konstruktor publik

ManagedTestDeviceFactory(boolean fastbootEnabled, IDeviceManager deviceManager, IDeviceMonitor allocationMonitor)

Metode publik

IManagedTestDevice createDevice(IDevice idevice)

void setFastbootEnabled(boolean enable)

Metode yang dilindungi

boolean checkFrameworkSupport(IDevice idevice)

Helper yang menampilkan nilai true jika perangkat memiliki dukungan framework.

CollectingOutputReceiver createOutputReceiver()

Buat CollectingOutputReceiver.

IRunUtil getRunUtil()

Menampilkan instance IRunUtil default.

boolean isRemoteEnvironment()

Menampilkan true jika saat ini kita sedang berjalan di lingkungan jarak jauh.

boolean isTcpDeviceSerial(String serial)

Helper ke perangkat jika serial dari perangkat yang terhubung dari jarak jauh.

Konstanta

FRAMEWORK_CHECK_MAX_RETRY

protected static final int FRAMEWORK_CHECK_MAX_RETRY

Nilai Konstanta: 3 (0x00000003)

FRAMEWORK_CHECK_SLEEP_MS

protected static final long FRAMEWORK_CHECK_SLEEP_MS

Nilai Konstanta: 500 (0x00000000000001f4)

Kolom

CHECK_PM_CMD

protected static final String CHECK_PM_CMD

EXPECTED_ERROR

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

mDeviceManager

protected IDeviceManager mDeviceManager

mFastbootEnabled

protected boolean mFastbootEnabled

Konstruktor publik

ManagedTestDeviceFactory

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

Parameter
fastbootEnabled boolean

deviceManager IDeviceManager

allocationMonitor IDeviceMonitor

Metode publik

createDevice

public IManagedTestDevice createDevice (IDevice idevice)

Parameter
idevice IDevice

Hasil
IManagedTestDevice

setFastbootEnabled

public void setFastbootEnabled (boolean enable)

Parameter
enable boolean

Metode yang dilindungi

checkFrameworkSupport

protected boolean checkFrameworkSupport (IDevice idevice)

Helper yang menampilkan nilai true jika perangkat memiliki dukungan framework.

Parameter
idevice IDevice

Hasil
boolean

createOutputReceiver

protected CollectingOutputReceiver createOutputReceiver ()

Buat CollectingOutputReceiver.

Hasil
CollectingOutputReceiver

getRunUtil

protected IRunUtil getRunUtil ()

Menampilkan instance IRunUtil default.

Hasil
IRunUtil

isRemoteEnvironment

protected boolean isRemoteEnvironment ()

Menampilkan true jika saat ini kita sedang berjalan di lingkungan jarak jauh. Tindakan ini akan mengubah perilaku perangkat.

Hasil
boolean

isTcpDeviceSerial

protected boolean isTcpDeviceSerial (String serial)

Helper ke perangkat jika serial dari perangkat yang terhubung dari jarak jauh. format serial perangkat tcp adalah :

Parameter
serial String

Hasil
boolean