GceAvdInfo
public
class
GceAvdInfo
extends Object
| java.lang.Object | |
| ↳ | com.android.tradefed.device.cloud.GceAvdInfo |
Structure permettant de stocker les données pertinentes pour une instance AVD GCE donnée.
Résumé
Classes imbriquées | |
|---|---|
class |
GceAvdInfo.LogFileEntry
|
Champs | |
|---|---|
public
static
final
|
BUILD_VARS
|
Constructeurs publics | |
|---|---|
GceAvdInfo(String instanceName, HostAndPort hostAndPort)
|
|
GceAvdInfo(String instanceName, HostAndPort hostAndPort, ErrorIdentifier errorType, String errors, GceAvdInfo.GceStatus status)
|
|
Méthodes publiques | |
|---|---|
|
getBuildVars()
Renvoie le hachage des informations de variable de compilation de l'appareil AVD GCE. |
Integer
|
getDeviceOffset()
|
ErrorIdentifier
|
getErrorType()
|
String
|
getErrors()
|
String
|
getInstanceUser()
|
|
getLogs()
Renvoie la carte des types de chemins d'accès aux journaux locaux ou distants. |
String
|
getOxygenationDeviceId()
|
boolean
|
getSkipDeviceLogCollection()
|
GceAvdInfo.GceStatus
|
getStatus()
|
HostAndPort
|
hostAndPort()
|
String
|
instanceName()
|
boolean
|
isIpPreconfigured()
|
static
GceAvdInfo
|
parseGceInfoFromFile(File f, DeviceDescriptor descriptor, int remoteAdbPort)
Analysez un fichier donné pour obtenir les informations sur l'appareil AVD GCE. |
static
|
parseGceInfoFromOxygenClientOutput(CommandResult oxygenRes, TestDeviceOptions deviceOptions)
Analysez une sortie de ligne de commande donnée à partir du binaire client Oxygen pour obtenir des informations sur les AVD loués. |
static
GceAvdInfo
|
parseGceInfoFromString(String data, DeviceDescriptor descriptor, int remoteAdbPort)
Analysez une chaîne donnée pour obtenir les informations sur l'appareil AVD GCE. |
void
|
setDeviceOffset(Integer deviceOffset)
|
void
|
setErrorType(ErrorIdentifier errorType)
|
void
|
setErrors(String errors)
|
void
|
setInstanceUser(String instanceUser)
|
void
|
setIpPreconfigured(boolean isIpPreconfigured)
|
void
|
setOxygenationDeviceId(String deviceId)
|
void
|
setSkipBugreportCollection(boolean skipDeviceLogCollection)
|
void
|
setSkipDeviceLogCollection(boolean skipDeviceLogCollection)
|
void
|
setStatus(GceAvdInfo.GceStatus status)
|
String
|
toString()
|
Champs
BUILD_VARS
public static finalBUILD_VARS
Constructeurs publics
GceAvdInfo
public GceAvdInfo (String instanceName,
HostAndPort hostAndPort)| Paramètres | |
|---|---|
instanceName |
String |
hostAndPort |
HostAndPort |
GceAvdInfo
public GceAvdInfo (String instanceName,
HostAndPort hostAndPort,
ErrorIdentifier errorType,
String errors,
GceAvdInfo.GceStatus status)| Paramètres | |
|---|---|
instanceName |
String |
hostAndPort |
HostAndPort |
errorType |
ErrorIdentifier |
errors |
String |
status |
GceAvdInfo.GceStatus |
Méthodes publiques
getBuildVars
publicgetBuildVars ()
Renvoie le hachage des informations de variable de compilation de l'appareil AVD GCE.
Les clés de variables de compilation possibles sont décrites dans BUILD_VARS, par exemple: build_id, build_target, branch, kernel_build_id, kernel_build_target, kernel_branch, system_build_id, system_build_target, system_branch, emulator_build_id, emulator_build_target, emulator_branch.
| Renvoie | |
|---|---|
|
|
getDeviceOffset
public Integer getDeviceOffset ()
| Renvoie | |
|---|---|
Integer |
|
getErrors
public String getErrors ()
| Renvoie | |
|---|---|
String |
|
getInstanceUser
public String getInstanceUser ()
| Renvoie | |
|---|---|
String |
|
getLogs
publicgetLogs ()
Renvoie la carte des chemins d'accès aux journaux locaux ou distants vers les types.
| Renvoie | |
|---|---|
|
|
getOxygenationDeviceId
public String getOxygenationDeviceId ()
| Renvoie | |
|---|---|
String |
|
getSkipDeviceLogCollection
public boolean getSkipDeviceLogCollection ()
| Renvoie | |
|---|---|
boolean |
|
hostAndPort
public HostAndPort hostAndPort ()
| Renvoie | |
|---|---|
HostAndPort |
|
instanceName
public String instanceName ()
| Renvoie | |
|---|---|
String |
|
isIpPreconfigured
public boolean isIpPreconfigured ()
| Renvoie | |
|---|---|
boolean |
|
parseGceInfoFromFile
public static GceAvdInfo parseGceInfoFromFile (File f, DeviceDescriptor descriptor, int remoteAdbPort)
Analysez un fichier donné pour obtenir les informations sur l'appareil AVD GCE.
| Paramètres | |
|---|---|
f |
File: fichier ERROR(/File) pour lire la sortie JSON du pilote GCE. |
descriptor |
DeviceDescriptor: descripteur de l'appareil qui a besoin des informations. |
remoteAdbPort |
int: port distant à utiliser pour la connexion adb |
| Renvoie | |
|---|---|
GceAvdInfo |
GceAvdInfo de l'appareil s'il est détecté, ou valeur nulle en cas d'erreur. |
| Génère | |
|---|---|
TargetSetupError |
|
parseGceInfoFromOxygenClientOutput
public staticparseGceInfoFromOxygenClientOutput (CommandResult oxygenRes, TestDeviceOptions deviceOptions)
Analysez une sortie de ligne de commande donnée à partir du binaire client Oxygen pour obtenir des informations sur les AVD loués.
| Paramètres | |
|---|---|
oxygenRes |
CommandResult: CommandResult de l'exécution de la commande client Oxygen. |
deviceOptions |
TestDeviceOptions: TestDeviceOptions décrivant les options de l'appareil |
| Renvoie | |
|---|---|
|
ERROR(/List) appareils ont bien été loués. Une exception TargetSetupError est générée si l'appareil ne peut pas être loué. |
| Génère | |
|---|---|
TargetSetupError |
|
parseGceInfoFromString
public static GceAvdInfo parseGceInfoFromString (String data, DeviceDescriptor descriptor, int remoteAdbPort)
Analysez une chaîne donnée pour obtenir les informations sur l'appareil AVD GCE.
| Paramètres | |
|---|---|
data |
String: chaîne JSON. |
descriptor |
DeviceDescriptor: descripteur de l'appareil qui a besoin des informations. |
remoteAdbPort |
int: port distant à utiliser pour la connexion adb |
| Renvoie | |
|---|---|
GceAvdInfo |
GceAvdInfo de l'appareil s'il est détecté, ou valeur nulle en cas d'erreur. |
| Génère | |
|---|---|
TargetSetupError |
|
setDeviceOffset
public void setDeviceOffset (Integer deviceOffset)
| Paramètres | |
|---|---|
deviceOffset |
Integer |
setErrorType
public void setErrorType (ErrorIdentifier errorType)
| Paramètres | |
|---|---|
errorType |
ErrorIdentifier |
setErrors
public void setErrors (String errors)
| Paramètres | |
|---|---|
errors |
String |
setInstanceUser
public void setInstanceUser (String instanceUser)
| Paramètres | |
|---|---|
instanceUser |
String |
setIpPreconfigured
public void setIpPreconfigured (boolean isIpPreconfigured)
| Paramètres | |
|---|---|
isIpPreconfigured |
boolean |
setOxygenationDeviceId
public void setOxygenationDeviceId (String deviceId)
| Paramètres | |
|---|---|
deviceId |
String |
setSkipBugreportCollection
public void setSkipBugreportCollection (boolean skipDeviceLogCollection)
| Paramètres | |
|---|---|
skipDeviceLogCollection |
boolean |
setSkipDeviceLogCollection
public void setSkipDeviceLogCollection (boolean skipDeviceLogCollection)
| Paramètres | |
|---|---|
skipDeviceLogCollection |
boolean |
setStatus
public void setStatus (GceAvdInfo.GceStatus status)
| Paramètres | |
|---|---|
status |
GceAvdInfo.GceStatus |
toString
public String toString ()
| Renvoie | |
|---|---|
String |
|