1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
#[derive(Copy, Clone, Debug)]
pub enum Entry {
    Node,
    Edge,
}

#[derive(Clone, Copy, Debug)]
pub struct Query {
    pub entry: Entry,
    pub index: usize,
}

impl Query {
    pub fn node(id: usize) -> Self {
        Self { entry: Entry::Node, index: id }
    }
    pub fn edge(id: usize) -> Self {
        Self { entry: Entry::Edge, index: id }
    }
}