use crate::enums::VBoxEventType;
use crate::event::Event;
use crate::utility::macros::macros::get_function_result_number;
use crate::VboxError;
impl Event {
pub fn get_type(&self) -> Result<VBoxEventType, VboxError> {
let event_type = get_function_result_number!(self.object, GetType, u32)?;
Ok(VBoxEventType::from(event_type))
}
}