2023-04-28 13:46:43 +08:00
|
|
|
use crate::{call_if_method, define_method_prefix, return_if_not_method};
|
2023-04-27 23:37:13 +08:00
|
|
|
|
2023-04-28 13:46:43 +08:00
|
|
|
use super::PluginNativeHandler;
|
2023-04-27 23:37:13 +08:00
|
|
|
|
2023-04-28 13:46:43 +08:00
|
|
|
#[derive(Default)]
|
2023-04-27 23:37:13 +08:00
|
|
|
/// Session related handler for librustdesk core.
|
|
|
|
pub struct PluginNativeSessionHandler;
|
|
|
|
|
|
|
|
impl PluginNativeHandler for PluginNativeSessionHandler {
|
2023-04-28 13:46:43 +08:00
|
|
|
define_method_prefix!("session_");
|
|
|
|
|
|
|
|
fn on_message(
|
|
|
|
&self,
|
|
|
|
method: &str,
|
|
|
|
data: &serde_json::Map<String, serde_json::Value>,
|
|
|
|
) -> Option<super::NR> {
|
2023-04-27 23:37:13 +08:00
|
|
|
None
|
|
|
|
}
|
|
|
|
|
2023-04-28 13:46:43 +08:00
|
|
|
fn on_message_raw(
|
|
|
|
&self,
|
|
|
|
method: &str,
|
|
|
|
data: &serde_json::Map<String, serde_json::Value>,
|
|
|
|
raw: *const std::ffi::c_void,
|
|
|
|
raw_len: usize,
|
|
|
|
) -> Option<super::NR> {
|
2023-04-27 23:37:13 +08:00
|
|
|
None
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
impl PluginNativeSessionHandler {
|
2023-04-28 13:46:43 +08:00
|
|
|
fn create_session() {}
|
2023-04-27 23:37:13 +08:00
|
|
|
|
2023-04-28 13:46:43 +08:00
|
|
|
fn add_session_hook() {}
|
|
|
|
}
|