pub struct Graph {
pub root: Option<Uuid>,
pub nodes: HashMap<Uuid, Node>,
pub links: Vec<Link>,
pub variables: HashMap<Uuid, String>,
}Expand description
The shared behavior graph: nodes, the links between their slots, the named blackboard variables, and (for tree-shaped interpreters) the root node.
Fields§
§root: Option<Uuid>The entry node, for interpreters that need one (a behavior tree’s root).
nodes: HashMap<Uuid, Node>All nodes, indexed by id.
links: Vec<Link>The links wiring node slots together.
variables: HashMap<Uuid, String>Named blackboard variables (id -> name); a LinkSource::Variable
refers to one of these, and the name is what an interpreter resolves
against the data store.
Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Graph
impl<'de> Deserialize<'de> for Graph
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl StructuralPartialEq for Graph
Auto Trait Implementations§
impl Freeze for Graph
impl RefUnwindSafe for Graph
impl Send for Graph
impl Sync for Graph
impl Unpin for Graph
impl UnsafeUnpin for Graph
impl UnwindSafe for Graph
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more