Client di ossigeno
public class OxygenClient
extends Object
java.lang.Object | |
↳ | com.android.tradefed.device.cloud.OxygenClient |
Una classe che gestisce l'utilizzo del file binario del client Oxygen per noleggiare o rilasciare il dispositivo Oxygen.
Riepilogo
Campi | |
---|---|
public static final | sGceDeviceParamsToOxygenMap
|
Costruttori pubblici | |
---|---|
OxygenClient (File clientBinary, IRunUtil runUtil) | |
OxygenClient (File clientBinary) Il costruttore della classe OxygenClient. |
Metodi pubblici | |
---|---|
void | closeLHPConnection (Process p) Chiudere la connessione al dispositivo di ossigenazione remota con un dato |
Process | createTunnelViaLHP ( OxygenClient.LHPTunnelMode mode) Crea un tunnel adb o ssh a un determinato nome di istanza e assegna l'endpoint a un dispositivo tramite LHP in base alla modalità tunnel specificata. |
String | getOverrideFetchCvdPath ( TestDeviceOptions deviceOptions) Restituisce il valore dell'argomento 'override_fetch_cvd_path' nel TestDeviceOptions specificato. |
CommandResult | leaseDevice ( IBuildInfo b, TestDeviceOptions deviceOptions, MultiMap <String, String> attributes) Tentare di noleggiare un dispositivo chiamando il file binario del client Oxygen. |
CommandResult | leaseMultipleDevices ( buildInfos, TestDeviceOptions deviceOptions, MultiMap <String, String> attributes) leaseMultipleDevices ( buildInfos, TestDeviceOptions deviceOptions, MultiMap <String, String> attributes) Tentare di noleggiare più dispositivi chiamando il file binario del client Oxygen. |
Boolean | noWaitForBootSpecified ( TestDeviceOptions deviceOptions) Controlla se no_wait_for_boot è specificato nella richiesta di lease di Oxygen |
boolean | release ( GceAvdInfo gceAvdInfo, TestDeviceOptions deviceOptions) Tentare di rilasciare un dispositivo utilizzando il file binario del client Oxygen. |
Campi
sGceDeviceParamsToOxygenMap
public static finalsGceDeviceParamsToOxygenMap
Costruttori pubblici
Client di ossigeno
public OxygenClient (File clientBinary, IRunUtil runUtil)
Parametri | |
---|---|
clientBinary | File |
runUtil | IRunUtil |
Client di ossigeno
public OxygenClient (File clientBinary)
Il costruttore della classe OxygenClient.
Parametri | |
---|---|
clientBinary | File : il file binario eseguibile del client Oxygen. |
Metodi pubblici
chiudiLHPConnection
public void closeLHPConnection (Process p)
Chiudere la connessione al dispositivo di ossigenazione remota con un dato Process
.
Parametri | |
---|---|
p | Process |
createTunnelViaLHP
public Process createTunnelViaLHP (OxygenClient.LHPTunnelMode mode)
Crea un tunnel adb o ssh a un determinato nome di istanza e assegna l'endpoint a un dispositivo tramite LHP in base alla modalità tunnel specificata.
Parametri | |
---|---|
mode | OxygenClient.LHPTunnelMode |
ritorna | |
---|---|
Process | Process dell'adb sul tunnel LHP. |
getOverrideFetchCvdPath
public String getOverrideFetchCvdPath (TestDeviceOptions deviceOptions)
Restituisce il valore dell'argomento 'override_fetch_cvd_path' nel TestDeviceOptions specificato.
Parametri | |
---|---|
deviceOptions | TestDeviceOptions : TestDeviceOptions |
ritorna | |
---|---|
String | il valore di 'override_fetch_cvd_path', o null se non è presente |
leaseDevice
public CommandResult leaseDevice (IBuildInfo b, TestDeviceOptions deviceOptions, MultiMap<String, String> attributes)
Tentare di noleggiare un dispositivo chiamando il file binario del client Oxygen.
Parametri | |
---|---|
b | IBuildInfo : IBuildInfo |
deviceOptions | TestDeviceOptions : TestDeviceOptions |
attributes | MultiMap : attributi associati all'invocazione corrente |
ritorna | |
---|---|
CommandResult | un CommandResult restituito dal binario Oxygen. |
leaseMultipleDevices
public CommandResult leaseMultipleDevices (buildInfos, TestDeviceOptions deviceOptions, MultiMap<String, String> attributes)
Tentare di noleggiare più dispositivi chiamando il file binario del client Oxygen.
Parametri | |
---|---|
buildInfos | ERROR(/List ) ERROR(/List ) |
deviceOptions | TestDeviceOptions : TestDeviceOptions |
attributes | MultiMap : attributi associati all'invocazione corrente |
ritorna | |
---|---|
CommandResult | CommandResult restituito dal binario Oxygen. |
noWaitForBootSpecified
public Boolean noWaitForBootSpecified (TestDeviceOptions deviceOptions)
Controlla se no_wait_for_boot è specificato nella richiesta di lease di Oxygen
Parametri | |
---|---|
deviceOptions | TestDeviceOptions : TestDeviceOptions |
ritorna | |
---|---|
Boolean | true se è specificato no_wait_for_boot |
pubblicazione
public boolean release (GceAvdInfo gceAvdInfo, TestDeviceOptions deviceOptions)
Tentare di rilasciare un dispositivo utilizzando il file binario del client Oxygen.
Parametri | |
---|---|
gceAvdInfo | GceAvdInfo : GceAvdInfo |
deviceOptions | TestDeviceOptions : TestDeviceOptions |
ritorna | |
---|---|
boolean | un valore booleano che indica se il rilascio del dispositivo ha avuto esito positivo. |