pub struct Program {
pub def: Behavior,
pub scope: Vec<u8>,
pub local_inits: Vec<Val>,
pub queries: Vec<Vec<u8>>,
pub body: Vec<CNode>,
pub paths: Vec<TracePath>,
pub bindings: usize,
}Expand description
One compiled behavior.
Fields§
§def: BehaviorThe authored definition this was compiled from.
scope: Vec<u8>Components an entity must carry for this behavior to run against it. Empty runs the body once, world-scoped.
local_inits: Vec<Val>Starting value of each local, indexed by slot.
queries: Vec<Vec<u8>>Component tags each declared query selects on, indexed by slot.
body: Vec<CNode>The compiled body.
paths: Vec<TracePath>Each node’s authored-tree path, indexed by CNode::id.
bindings: usizeHow many binding slots a run of this body needs.
Implementations§
Trait Implementations§
Auto Trait Implementations§
impl Freeze for Program
impl RefUnwindSafe for Program
impl Send for Program
impl Sync for Program
impl Unpin for Program
impl UnsafeUnpin for Program
impl UnwindSafe for Program
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