use serde::{Deserialize, Serialize};
#[derive(Clone, Copy, Debug, PartialEq, Eq, Serialize, Deserialize)]
pub enum BackendDirection {
Outgoing,
Incoming,
}
#[derive(Clone, Debug)]
pub struct NeighborQuery {
pub direction: BackendDirection,
pub edge_type: Option<String>,
}
impl Default for NeighborQuery {
fn default() -> Self {
Self {
direction: BackendDirection::Outgoing,
edge_type: None,
}
}
}
#[derive(Clone, Debug)]
pub struct NodeSpec {
pub kind: String,
pub name: String,
pub file_path: Option<String>,
pub data: serde_json::Value,
}
#[derive(Clone, Debug)]
pub struct EdgeSpec {
pub from: i64,
pub to: i64,
pub edge_type: String,
pub data: serde_json::Value,
}