use crate::consistency::{PersonaProfile, StateChangeEvent};
use crate::protocol_abstraction::Protocol;
use crate::Result;
#[async_trait::async_trait]
pub trait ProtocolAdapter: Send + Sync {
fn protocol(&self) -> Protocol;
async fn on_state_change(&self, event: &StateChangeEvent) -> Result<()>;
async fn get_current_state(
&self,
workspace_id: &str,
) -> Result<Option<crate::consistency::types::ProtocolState>>;
async fn apply_persona(&self, workspace_id: &str, persona: &PersonaProfile) -> Result<()>;
async fn apply_scenario(&self, workspace_id: &str, scenario_id: &str) -> Result<()>;
}