Skip to main content

teaql_core/
trace.rs

1#[derive(Debug, Clone, PartialEq, Eq)]
2pub struct TraceNode {
3    pub entity_type: String,
4    pub entity_id: Option<u64>,
5    pub comment: String,
6}
7
8impl TraceNode {
9    pub fn new(entity_type: impl Into<String>, entity_id: Option<u64>, comment: impl Into<String>) -> Self {
10        Self {
11            entity_type: entity_type.into(),
12            entity_id,
13            comment: comment.into(),
14        }
15    }
16}