[−][src]Struct smeagol::node::Store
A struct to store nodes and node evolution results.
Methods
impl Store
[src]
pub fn new() -> Self
[src]
pub fn node(&self, id: NodeId) -> Node
[src]
Returns the node corresponding to the given node ID.
pub fn create_leaf(&mut self, grid: u16x16) -> NodeId
[src]
Creates a leaf node corresponding to the given 16 by 16 grid.
pub fn create_interior(&mut self, template: NodeTemplate) -> NodeId
[src]
Creates an interior node from the given node template.
pub fn create_empty(&mut self, level: Level) -> NodeId
[src]
Creates an empty node with the given level.
impl Store
[src]
pub fn step_log_2(&self) -> u8
[src]
Returns the current step size log 2.
pub fn set_step_log_2(&mut self, step_log_2: u8)
[src]
Sets the step size to be 2^step_log_2
.
This clears previously calculated steps.
pub fn get_step(&self, id: NodeId) -> Option<NodeId>
[src]
Gets the step of the given node, if it has been previously calculated.
pub fn add_step(&mut self, id: NodeId, step: NodeId)
[src]
Sets the step of the given node.
pub fn get_jump(&self, id: NodeId) -> Option<NodeId>
[src]
Gets the jump of the given node, if it has been previously calculated.
pub fn add_jump(&mut self, id: NodeId, jump: NodeId)
[src]
Sets the jump of the given node.
Trait Implementations
impl Default for Store
[src]
impl Clone for Store
[src]
fn clone(&self) -> Store
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more
impl Debug for Store
[src]
Auto Trait Implementations
Blanket Implementations
impl<T> From for T
[src]
impl<T, U> Into for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
impl<T, U> TryFrom for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = !
🔬 This is a nightly-only experimental API. (
try_from
)The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T> Borrow for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> BorrowMut for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T, U> TryInto for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
🔬 This is a nightly-only experimental API. (
try_from
)The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> FromCast for T
[src]
impl<T, U> Cast for T where
U: FromCast<T>,
[src]
U: FromCast<T>,