use crate::common::protocol::Frame;
use crate::common::protocol::flare::core::commands::system_command::Type as SysType;
use crate::common::protocol::flare::core::commands::message_command::Type as MsgType;
use crate::common::protocol::flare::core::commands::notification_command::Type as NotifType;
use crate::transport::events::ConnectionEvent;
use crate::common::error::Result;
#[async_trait::async_trait]
pub trait ClientEventHandler: Send + Sync {
async fn handle_system_command(&self, command_type: SysType, frame: &Frame) -> Result<Option<Frame>> {
let _ = (command_type, frame);
Ok(None)
}
async fn handle_message_command(&self, command_type: MsgType, frame: &Frame) -> Result<Option<Frame>> {
let _ = (command_type, frame);
Ok(None)
}
async fn handle_notification_command(&self, command_type: NotifType, frame: &Frame) -> Result<Option<Frame>> {
let _ = (command_type, frame);
Ok(None)
}
async fn handle_connection_event(&self, event: &ConnectionEvent) -> Result<()> {
let _ = event;
Ok(())
}
}