管理されたテストデバイスファクトリー

public class ManagedTestDeviceFactory
extends Object implements IManagedTestDeviceFactory

java.lang.オブジェクト
com.android.tradefed.device.ManagedTestDeviceFactory


Tf によって監視できるさまざまな種類のデバイスを作成するためのファクトリー

まとめ

定数

int FRAMEWORK_CHECK_MAX_RETRY

long FRAMEWORK_CHECK_SLEEP_MS

田畑

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

public static final String NOTIFY_AS_NATIVE

protected IDeviceMonitor mAllocationMonitor

protected IDeviceManager mDeviceManager

protected boolean mFastbootEnabled

パブリックコンストラクター

ManagedTestDeviceFactory (boolean fastbootEnabled, IDeviceManager deviceManager, IDeviceMonitor allocationMonitor)

パブリックメソッド

IManagedTestDevice createDevice (IDevice idevice)

渡されたIDeviceに基づいてIManagedTestDeviceを作成します。

IManagedTestDevice createRequestedDevice (IDevice idevice, IDeviceSelection options)

仕様に合わせたデバイスを具体的に作成する

static boolean isTcpDeviceSerial (String serial)

リモート接続されたデバイスからのシリアルの場合、デバイスへのヘルパー。

void setFastbootEnabled (boolean enable)

作成したデバイスの fastboot サポートを有効にするかどうかを指定します。

保護されたメソッド

CollectingOutputReceiver createOutputReceiver ()

CollectingOutputReceiverを作成します。

IRunUtil getRunUtil ()

デフォルトのIRunUtilインスタンスを返します。

boolean isRemoteEnvironment ()

現在リモート環境で実行している場合は true を返します。

定数

FRAMEWORK_CHECK_MAX_RETRY

protected static final int FRAMEWORK_CHECK_MAX_RETRY

定数値: 3 (0x00000003)

FRAMEWORK_CHECK_SLEEP_MS

protected static final long FRAMEWORK_CHECK_SLEEP_MS

定数値: 500 (0x00000000000001f4)

田畑

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

NOTIFY_AS_NATIVE

public static final String NOTIFY_AS_NATIVE

mAllocationMonitor

protected IDeviceMonitor mAllocationMonitor

mデバイスマネージャー

protected IDeviceManager mDeviceManager

mFastboot有効

protected boolean mFastbootEnabled

パブリックコンストラクター

管理されたテストデバイスファクトリー

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

パラメーター
fastbootEnabled boolean

deviceManager IDeviceManager

allocationMonitor IDeviceMonitor

パブリックメソッド

デバイスの作成

public IManagedTestDevice createDevice (IDevice idevice)

渡されたIDeviceに基づいてIManagedTestDeviceを作成します。

パラメーター
idevice IDevice : 作成されるデバイスのタイプを定義します

戻り値
IManagedTestDevice IDevice に基づいて作成された IManatedTestDevice

リクエストされたデバイスの作成

public IManagedTestDevice createRequestedDevice (IDevice idevice, 
                IDeviceSelection options)

仕様に合わせたデバイスを具体的に作成する

パラメーター
idevice IDevice

options IDeviceSelection

戻り値
IManagedTestDevice

isTcpDeviceSerial

public static boolean isTcpDeviceSerial (String serial)

リモート接続されたデバイスからのシリアルの場合、デバイスへのヘルパー。 TCPデバイスのシリアルフォーマットは:

パラメーター
serial String

戻り値
boolean

setFastbootEnabled

public void setFastbootEnabled (boolean enable)

作成したデバイスの fastboot サポートを有効にするかどうかを指定します。

パラメーター
enable boolean : サポートを設定する値。

保護されたメソッド

createOutputReceiver

protected CollectingOutputReceiver createOutputReceiver ()

CollectingOutputReceiverを作成します。

戻り値
CollectingOutputReceiver

getRunUtil

protected IRunUtil getRunUtil ()

デフォルトのIRunUtilインスタンスを返します。

戻り値
IRunUtil

リモート環境です

protected boolean isRemoteEnvironment ()

現在リモート環境で実行している場合は true を返します。これにより、デバイスの動作が変わります。

戻り値
boolean