InvocationContext

public class InvocationContext
extends Object implements IInvocationContext

Objeto java.lang.
   ↳ com.android.tradefed.invoker.InvocationContext


Implementación genérica de un IInvocationContext.

Resumen

Constructores públicos

InvocationContext()

Crea un BuildInfo con los valores de atributos predeterminados.

Métodos públicos

void addAllocatedDevice( deviceWithName)

void addAllocatedDevice(String devicename, ITestDevice testDevice)

void addDeviceBuildInfo(String deviceName, IBuildInfo buildinfo)

void addInvocationAttribute(String attributeName, String attributeValue)

void addInvocationAttributes(MultiMap<String, String> attributesMap)

void addSerialsFromShard(Integer index, serials)

static InvocationContext fromProto(InvocationContext.Context protoContext)

Operación inversa a InvocationContext#toProto() para recuperar la instancia.

MultiMap<String, String> getAttributes()

IBuildInfo getBuildInfo(String deviceName)

IBuildInfo getBuildInfo(ITestDevice testDevice)

String getBuildInfoName(IBuildInfo info)

getBuildInfos()

ConfigurationDescriptor getConfigurationDescriptor()

ITestDevice getDevice(String deviceName)

getDeviceBuildMap()

ITestDevice getDeviceBySerial(String serial)

getDeviceConfigNames()

String getDeviceName(ITestDevice device)

getDevices()

String getInvocationId()
IInvocationContext getModuleInvocationContext()

int getNumDevicesAllocated()

getSerials()

getShardsSerials()

String getTestTag()

void lockAttributes()

Bloquea el contexto para evitar que se agreguen más atributos de invocación.

void logInvocationMetrics()

Registra los atributos InvocationMetricLogger en la invocación.

void markReleasedEarly()
void setConfigurationDescriptor(ConfigurationDescriptor configurationDescriptor)

void setModuleInvocationContext(IInvocationContext invocationContext)

void setRecoveryModeForAllDevices(ITestDevice.RecoveryMode mode)

void setTestTag(String testTag)

InvocationContext.Context toProto()

boolean wasReleasedEarly()

Constructores públicos

InvocationContext

public InvocationContext ()

Crea un BuildInfo con los valores de atributos predeterminados.

Métodos públicos

agregarDispositivoasignado

public void addAllocatedDevice ( deviceWithName)

Parámetros
deviceWithName

agregarDispositivoasignado

public void addAllocatedDevice (String devicename, 
                ITestDevice testDevice)

Parámetros
devicename String

testDevice ITestDevice

addDeviceBuildInfo

public void addDeviceBuildInfo (String deviceName, 
                IBuildInfo buildinfo)

Parámetros
deviceName String

buildinfo IBuildInfo

addInvocationAttribute

public void addInvocationAttribute (String attributeName, 
                String attributeValue)

Parámetros
attributeName String

attributeValue String

addInvocationAttributes

public void addInvocationAttributes (MultiMap<String, String> attributesMap)

Parámetros
attributesMap MultiMap

addSerialsFromShard

public void addSerialsFromShard (Integer index, 
                 serials)

Parámetros
index Integer

serials

de Proto

public static InvocationContext fromProto (InvocationContext.Context protoContext)

Operación inversa a InvocationContext#toProto() para recuperar la instancia.

Parámetros
protoContext InvocationContext.Context

Muestra
InvocationContext

getAttributes

public MultiMap<String, String> getAttributes ()

Muestra
MultiMap<String, String>

getBuildInfo

public IBuildInfo getBuildInfo (String deviceName)

Parámetros
deviceName String

Muestra
IBuildInfo

getBuildInfo

public IBuildInfo getBuildInfo (ITestDevice testDevice)

Parámetros
testDevice ITestDevice

Muestra
IBuildInfo

getBuildInfoName

public String getBuildInfoName (IBuildInfo info)

Parámetros
info IBuildInfo

Muestra
String

getBuildInfos

public  getBuildInfos ()

Muestra

getConfigurationDescriptor.

public ConfigurationDescriptor getConfigurationDescriptor ()

Muestra
ConfigurationDescriptor

getDevice

public ITestDevice getDevice (String deviceName)

Parámetros
deviceName String

Muestra
ITestDevice

getDeviceBuildMap

public  getDeviceBuildMap ()

Muestra

getDeviceBySerial

public ITestDevice getDeviceBySerial (String serial)

Parámetros
serial String

Muestra
ITestDevice

getDeviceConfigNames

public  getDeviceConfigNames ()

Muestra

getDeviceName

public String getDeviceName (ITestDevice device)

Parámetros
device ITestDevice

Muestra
String

getDevices

public  getDevices ()

Muestra

ID getInvocation

public String getInvocationId ()

Muestra
String

getModuleInvocationContext

public IInvocationContext getModuleInvocationContext ()

Muestra
IInvocationContext

getNumDevicesAllocated.

public int getNumDevicesAllocated ()

Muestra
int

getSerial

public  getSerials ()

Muestra

getShardsSerials

public  getShardsSerials ()

Muestra

getTestTag

public String getTestTag ()

Muestra
String

Atributos de bloqueo

public void lockAttributes ()

Bloquea el contexto para evitar que se agreguen más atributos de invocación.

logInvocationMetrics

public void logInvocationMetrics ()

Registra los atributos InvocationMetricLogger en la invocación.

markReleasedEarly

public void markReleasedEarly ()

setConfigurationDescriptor.

public void setConfigurationDescriptor (ConfigurationDescriptor configurationDescriptor)

Parámetros
configurationDescriptor ConfigurationDescriptor

setModuleInvocationContext

public void setModuleInvocationContext (IInvocationContext invocationContext)

Parámetros
invocationContext IInvocationContext

setRecoveryModeForAllDevices

public void setRecoveryModeForAllDevices (ITestDevice.RecoveryMode mode)

Parámetros
mode ITestDevice.RecoveryMode

setTestTag

public void setTestTag (String testTag)

Parámetros
testTag String

ToProto

public InvocationContext.Context toProto ()

Muestra
InvocationContext.Context

Se lanzó anticipada

public boolean wasReleasedEarly ()

Muestra
boolean