UzakAndroidSanalCihaz

public class RemoteAndroidVirtualDevice
extends RemoteAndroidDevice implements ITestLoggerReceiver

java.lang.Object
com.android.tradefed.device.NativeDevice
com.android.tradefed.device.TestDevice
com.android.tradefed.device.RemoteAndroidDevice
com.android.tradefed.device.cloud.RemoteAndroidVirtualDevice


Google Compute Engine'de (Gce) çalışan tam yığın Android cihazı için RemoteAndroidDevice davranışını genişletir. Cihaz serisinin şu formatta olacağını varsayalım: : adb'de.

Özet

Kamu inşaatçıları

RemoteAndroidVirtualDevice (IDevice device, IDeviceStateMonitor stateMonitor, IDeviceMonitor allocationMonitor)

Bir RemoteAndroidVirtualDevice oluşturur.

Genel yöntemler

GceAvdInfo getAvdInfo ()

Oluşturulan uzak VM'den GceAvdInfo döndürür.

DeviceDescriptor getDeviceDescriptor ()

getTombstones ()

Mürekkep balığının, mezar taşlarını doğrudan alabileceğimiz uzak ana bilgisayara getiren özel bir özelliği vardır.

void postBootSetup ()

{@miras }

void postInvocationTearDown (Throwable exception)

boolean powerwashGce ()

Bir GCE örneğine powerwash işlemi uygulanmaya çalışılıyor

void preInvocationSetup (IBuildInfo info, MultiMap<String, String> attributes)

void recoverDevice ()

Cihaz iletişimini kurtarma girişimleri.

void setGceSshMonitor ( GceSshTunnelMonitor gceSshMonitor)

Cihazın dahili GceSshTunnelMonitor geçersiz kılın.

void setTestLogger (ITestLogger testLogger)

Korumalı yöntemler

void doAdbReboot ( NativeDevice.RebootMode rebootMode, String reason)

Bir adb yeniden başlatma işlemi gerçekleştirin.

long getCurrentTime ()

Geçerli sistem saatini döndürür.

GceSshTunnelMonitor getGceSshMonitor ()

Cihazın GceSshTunnelMonitor döndürür.

void launchGce (IBuildInfo buildInfo, MultiMap<String, String> attributes)

Derleme bilgilerine göre gerçek gce cihazını başlatın.

void waitForTunnelOnline (long waitTime)

Tünel monitörünün çalışıp çalışmadığını kontrol edin.

Kamu inşaatçıları

UzakAndroidSanalCihaz

public RemoteAndroidVirtualDevice (IDevice device, 
                IDeviceStateMonitor stateMonitor, 
                IDeviceMonitor allocationMonitor)

Bir RemoteAndroidVirtualDevice oluşturur.

Parametreler
device IDevice : ilişkili IDevice

stateMonitor IDeviceStateMonitor : kullanılacak IDeviceStateMonitor mekanizması

allocationMonitor IDeviceMonitor : Tahsis durumu değişiklikleri hakkında bilgi veren IDeviceMonitor .

Genel yöntemler

AvdInfo'yu al

public GceAvdInfo getAvdInfo ()

Oluşturulan uzak VM'den GceAvdInfo döndürür. Getirme başarılı olmazsa null değerini döndürür.

İadeler
GceAvdInfo

getDeviceDescriptor

public DeviceDescriptor getDeviceDescriptor ()

İadeler
DeviceDescriptor

Mezar Taşlarını Al

public  getTombstones ()

Mürekkep balığının, mezar taşlarını doğrudan alabileceğimiz uzak ana bilgisayara getiren özel bir özelliği vardır.

İadeler

Atar
DeviceNotAvailableException

postBootSetup

public void postBootSetup ()

{@miras }

Atar
DeviceNotAvailableException

postInvokasyonTearDown

public void postInvocationTearDown (Throwable exception)

Parametreler
exception Throwable

powerwashGce

public boolean powerwashGce ()

Bir GCE örneğine powerwash işlemi uygulanmaya çalışılıyor

İadeler
boolean powerwash Gce başarılı olursa true değerini döndürür.

Atar
com.android.tradefed.targetprep.TargetSetupError
DeviceNotAvailableException
TargetSetupError

preInvokasyon Kurulumu

public void preInvocationSetup (IBuildInfo info, 
                MultiMap<String, String> attributes)

Parametreler
info IBuildInfo

attributes MultiMap

Atar
DeviceNotAvailableException
TargetSetupError

kurtarmaCihaz

public void recoverDevice ()

Cihaz iletişimini kurtarma girişimleri.

Atar
DeviceNotAvailableException

setGceSshMonitor

public void setGceSshMonitor (GceSshTunnelMonitor gceSshMonitor)

Cihazın dahili GceSshTunnelMonitor geçersiz kılın.

Parametreler
gceSshMonitor GceSshTunnelMonitor

setTestLogger

public void setTestLogger (ITestLogger testLogger)

Parametreler
testLogger ITestLogger

Korumalı yöntemler

doAdbYeniden Başlat

protected void doAdbReboot (NativeDevice.RebootMode rebootMode, 
                String reason)

Bir adb yeniden başlatma işlemi gerçekleştirin.

Parametreler
rebootMode NativeDevice.RebootMode : bu yeniden başlatmanın bir modu.

reason String : bu yeniden başlatma için.

Atar
DeviceNotAvailableException

getCurrentTime

protected long getCurrentTime ()

Geçerli sistem saatini döndürür. Test için açığa çıkarıldı.

İadeler
long

getGceSshMonitor

protected GceSshTunnelMonitor getGceSshMonitor ()

Cihazın GceSshTunnelMonitor döndürür. Test için açığa çıkarıldı.

İadeler
GceSshTunnelMonitor

lansmanGce

protected void launchGce (IBuildInfo buildInfo, 
                MultiMap<String, String> attributes)

Derleme bilgilerine göre gerçek gce cihazını başlatın.

Parametreler
buildInfo IBuildInfo

attributes MultiMap

Atar
TargetSetupError

waitForTunnelOnline

protected void waitForTunnelOnline (long waitTime)

Tünel monitörünün çalışıp çalışmadığını kontrol edin.

Parametreler
waitTime long

Atar
DeviceNotAvailableException