pub trait ArgEnvReader<T, K> {
// Required methods
fn get_key(&self) -> Option<K>;
fn read(&self, default_env_name: &str) -> Result<T, HelperErrors>;
fn read_default(&self) -> Result<T, HelperErrors>;
}
Required Methods§
Sourcefn read(&self, default_env_name: &str) -> Result<T, HelperErrors>
fn read(&self, default_env_name: &str) -> Result<T, HelperErrors>
Try to read the value from the cli param (given by the key), or read from the env variable
Sourcefn read_default(&self) -> Result<T, HelperErrors>
fn read_default(&self) -> Result<T, HelperErrors>
Read the private key with a default env value and return an address string