use std::collections::HashMap;
pub type EncryptorResult<T> = Result<T, String>;
pub trait IEncryptor {
fn module_name(&self) -> &str;
fn algorithm(&self) -> &str;
fn initialize(&mut self, config: HashMap<String, String>);
fn set_password(&mut self, password: &str) -> EncryptorResult<()>;
fn encrypt(&self, data: &[u8]) -> EncryptorResult<Vec<u8>>;
fn decrypt(&self, encrypted_data: &[u8]) -> EncryptorResult<Vec<u8>>;
fn validate(&self) -> Result<(), String>;
fn get_metadata(&self) -> HashMap<String, String>;
fn priority(&self) -> i32;
}