ConfigurationDescriptor
  public
  
  
  
  class
  ConfigurationDescriptor
  
    extends Object
  
  
  
  
  
  
| java.lang.Object | |
| ↳ | com.android.tradefed.config.ConfigurationDescriptor | 
Configuration Object that describes some aspect of the configuration itself. Like a membership test-suite-tag. This class cannot receive option values via command line. Only directly in the xml.
Summary
| Fields | |
|---|---|
| 
    public
    static
    final
    String | ACTIVE_PARAMETER_KEYMetadata key for a config parameterization, optional. | 
| 
    public
    static
    final
    String | LOCAL_SHARDED_KEYMetadata key for a config to specify that it was sharded. | 
| 
    public
    static
    final
    String | MODULE_DIR_PATH_KEYMetadata key for a config to specify the module dir path when it's a module config. | 
| 
    public
    static
    final
    String | PRIORITIZE_HOST_CONFIG_KEYMetadata key for a config to specify if it is prioritizing host config. | 
| Public constructors | |
|---|---|
| 
      ConfigurationDescriptor()
       | |
| Public methods | |
|---|---|
| 
        
        
        
        
        
        void | 
      addMetadata(String key, Add more values of a given key to the metadata entries. | 
| 
        
        
        
        
        
        void | 
      addRerunOption(OptionDef optionDef)
      Add the option to a list of options that can be used to rerun the test. | 
| 
        
        
        
        
        
        ConfigurationDescriptor | 
      clone()
      Return a deep-copy of the  | 
| 
        
        
        static
        
        
        ConfigurationDescriptor | 
      fromProto(ConfigurationDescription.Descriptor protoDescriptor)
      Inverse operation from  | 
| 
        
        
        
        
        
        IAbi | 
      getAbi()
      Returns the abi the configuration is running against if known, null otherwise. | 
| 
        
        
        
        
        
        MultiMap<String, String> | 
      getAllMetaData()
      Retrieves all configured metadata and return a copy of the map. | 
| 
        
        
        
        
        
         | 
      getMetaData(String name)
      Get the named metadata entries | 
| 
        
        
        
        
        
        String | 
      getModuleName()
      Returns the module name of the module configuration. | 
| 
        
        
        
        
        
         | 
      getRerunOptions()
      Get the list of  | 
| 
        
        
        
        
        
        Integer | 
      getShardIndex()
      Get the shard index of the invocation during local sharding. | 
| 
        
        
        
        
        
         | 
      getSuiteTags()
      Returns the list of suite tags the test is part of. | 
| 
        
        
        
        
        
        boolean | 
      isNotIRemoteTestShardable()
      Returns if the configuration should split the IRemoteTest into different modules. | 
| 
        
        
        
        
        
        boolean | 
      isNotShardable()
      Returns if the configuration is shardable or not as part of a suite | 
| 
        
        
        
        
        
        boolean | 
      isNotStrictShardable()
      Returns if the configuration is strict shardable or not as part of a suite | 
| 
        
        
        
        
        
         | 
      removeMetadata(String key)
      Remove the tracking of the specified metadata key. | 
| 
        
        
        
        
        
        void | 
      setAbi(IAbi abi)
      Sets the abi the configuration is going to run against. | 
| 
        
        
        
        
        
        void | 
      setMetaData(MultiMap<String, String> metadata)
       | 
| 
        
        
        
        
        
        void | 
      setModuleName(String name)
      If this configuration represents a module, we can set the module name associated with it. | 
| 
        
        
        
        
        
        void | 
      setNotIRemoteTestShardable(boolean notIRemoteTestShardable)
       | 
| 
        
        
        
        
        
        void | 
      setSandboxed(boolean useSandboxed)
      Sets whether or not a config will run in sandboxed mode or not. | 
| 
        
        
        
        
        
        void | 
      setShardIndex(int index)
      Set the shard index for the invocation in local sharding. | 
| 
        
        
        
        
        
        void | 
      setSuiteTags(Sets the list of suite tags the test is part of. | 
| 
        
        
        
        
        
        boolean | 
      shouldUseSandbox()
      Returns true if the invocation should run in sandboxed mode. | 
| 
        
        
        
        
        
        ConfigurationDescription.Descriptor | 
      toProto()
      Convert the current instance of the descriptor into its proto format. | 
Fields
ACTIVE_PARAMETER_KEY
public static final String ACTIVE_PARAMETER_KEY
Metadata key for a config parameterization, optional.
LOCAL_SHARDED_KEY
public static final String LOCAL_SHARDED_KEY
Metadata key for a config to specify that it was sharded.
MODULE_DIR_PATH_KEY
public static final String MODULE_DIR_PATH_KEY
Metadata key for a config to specify the module dir path when it's a module config.
PRIORITIZE_HOST_CONFIG_KEY
public static final String PRIORITIZE_HOST_CONFIG_KEY
Metadata key for a config to specify if it is prioritizing host config.
Public constructors
ConfigurationDescriptor
public ConfigurationDescriptor ()
Public methods
addMetadata
public void addMetadata (String key, 
                 values) Add more values of a given key to the metadata entries.
| Parameters | |
|---|---|
| key | String:Stringof the key to add values to. | 
| values | : a list ofStringof the additional values. | 
addRerunOption
public void addRerunOption (OptionDef optionDef)
Add the option to a list of options that can be used to rerun the test.
| Parameters | |
|---|---|
| optionDef | OptionDef: aOptionDefobject of the test option. | 
clone
public ConfigurationDescriptor clone ()
Return a deep-copy of the ConfigurationDescriptor object.
| Returns | |
|---|---|
| ConfigurationDescriptor | |
fromProto
public static ConfigurationDescriptor fromProto (ConfigurationDescription.Descriptor protoDescriptor)
Inverse operation from toProto() to get the object back.
| Parameters | |
|---|---|
| protoDescriptor | ConfigurationDescription.Descriptor | 
| Returns | |
|---|---|
| ConfigurationDescriptor | |
getAbi
public IAbi getAbi ()
Returns the abi the configuration is running against if known, null otherwise.
| Returns | |
|---|---|
| IAbi | |
getAllMetaData
public MultiMap<String, String> getAllMetaData ()
Retrieves all configured metadata and return a copy of the map.
| Returns | |
|---|---|
| MultiMap<String, String> | |
getMetaData
publicgetMetaData (String name) 
Get the named metadata entries
| Parameters | |
|---|---|
| name | String | 
| Returns | |
|---|---|
|  | |
getModuleName
public String getModuleName ()
Returns the module name of the module configuration.
| Returns | |
|---|---|
| String | |
getRerunOptions
publicgetRerunOptions () 
Get the list of OptionDef that can be used for rerun.
| Returns | |
|---|---|
|  | |
getShardIndex
public Integer getShardIndex ()
Get the shard index of the invocation during local sharding. Returns null if no sharding.
| Returns | |
|---|---|
| Integer | |
getSuiteTags
publicgetSuiteTags () 
Returns the list of suite tags the test is part of.
| Returns | |
|---|---|
|  | |
isNotIRemoteTestShardable
public boolean isNotIRemoteTestShardable ()
Returns if the configuration should split the IRemoteTest into different modules.
| Returns | |
|---|---|
| boolean | |
isNotShardable
public boolean isNotShardable ()
Returns if the configuration is shardable or not as part of a suite
| Returns | |
|---|---|
| boolean | |
isNotStrictShardable
public boolean isNotStrictShardable ()
Returns if the configuration is strict shardable or not as part of a suite
| Returns | |
|---|---|
| boolean | |
removeMetadata
publicremoveMetadata (String key) 
Remove the tracking of the specified metadata key.
| Parameters | |
|---|---|
| key | String | 
| Returns | |
|---|---|
|  | |
setAbi
public void setAbi (IAbi abi)
Sets the abi the configuration is going to run against.
| Parameters | |
|---|---|
| abi | IAbi | 
setMetaData
public void setMetaData (MultiMap<String, String> metadata)
| Parameters | |
|---|---|
| metadata | MultiMap | 
setModuleName
public void setModuleName (String name)
If this configuration represents a module, we can set the module name associated with it.
| Parameters | |
|---|---|
| name | String | 
setNotIRemoteTestShardable
public void setNotIRemoteTestShardable (boolean notIRemoteTestShardable)
| Parameters | |
|---|---|
| notIRemoteTestShardable | boolean | 
setSandboxed
public void setSandboxed (boolean useSandboxed)
Sets whether or not a config will run in sandboxed mode or not.
| Parameters | |
|---|---|
| useSandboxed | boolean | 
setShardIndex
public void setShardIndex (int index)
Set the shard index for the invocation in local sharding.
| Parameters | |
|---|---|
| index | int | 
setSuiteTags
public void setSuiteTags (suiteTags) 
Sets the list of suite tags the test is part of.
| Parameters | |
|---|---|
| suiteTags |  | 
shouldUseSandbox
public boolean shouldUseSandbox ()
Returns true if the invocation should run in sandboxed mode. False otherwise.
| Returns | |
|---|---|
| boolean | |
toProto
public ConfigurationDescription.Descriptor toProto ()
Convert the current instance of the descriptor into its proto format.
| Returns | |
|---|---|
| ConfigurationDescription.Descriptor | |
