xen/ctrl/
interface.rs

1use std::rc::Rc;
2
3use super::XenInterfaceHandle;
4use crate::XenError;
5
6#[derive(Debug, Clone)]
7pub struct XenInterface {
8    pub(crate) handle: Rc<XenInterfaceHandle>,
9}
10
11impl XenInterface {
12    pub fn new() -> Result<Self, XenError> {
13        Ok(Self {
14            handle: Rc::new(XenInterfaceHandle::new()?),
15        })
16    }
17}