DryRunKeyStore

public class DryRunKeyStore
extends Object implements IKeyStoreClient

java.lang.Object
   ↳ com.android.tradefed.util.keystore.DryRunKeyStore


A keystore for dry-run where any keystore value is always properly replaced and found.

Summary

Public constructors

DryRunKeyStore()

Public methods

boolean containsKey(String key)

A method to check if the key store contains a given key.

String fetchKey(String key)

A method to fetch a given key inside the key store.

String fetchKey(String key, String optionType)

Special callback for the dry run keystore to create value of expected type.

boolean isAvailable()

A method to check whether or not we have a valid key store to talk to.

Public constructors

DryRunKeyStore

public DryRunKeyStore ()

Public methods

containsKey

public boolean containsKey (String key)

A method to check if the key store contains a given key.

Parameters
key String: to check existence for.

Returns
boolean true if the given key exists.

fetchKey

public String fetchKey (String key)

A method to fetch a given key inside the key store.

Parameters
key String: to fetch inside the key store.

Returns
String the String value of the key. It will return null if key is not found.

fetchKey

public String fetchKey (String key, 
                String optionType)

Special callback for the dry run keystore to create value of expected type.

Parameters
key String: the key for the option, will be ignored.

optionType String: the return type expected.

Returns
String

isAvailable

public boolean isAvailable ()

A method to check whether or not we have a valid key store to talk to.

Returns
boolean true if we have a valid key store, false otherwise.