1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
use std::rc::Rc;

use super::{Instance, Memory, Platform};

pub trait Link {
    type Platform: Platform + ?Sized;

    fn instance(&self) -> &Rc<Instance<Self::Platform>>;
    fn memory(&self) -> &Memory;

    fn queue_rerender(&self) {
        self.instance().renderer().queue_rerender(self.instance())
    }
}