Type Definition radn::rstd::collections::stack::Stack

source ·
pub type Stack<'a, Ctx, A> = Nullable<'a, Ctx, StackNode<'a, Ctx, A>>;
Expand description

Type representing a stack, an alias to a Nullable of a StackNode.

Trait Implementations§

source§

impl<'a, Ctx: Context<'a>, A: Mentionable<'a, Ctx>> ExtStack<'a, Ctx, A> for Stack<'a, Ctx, A>where StackNode<'a, Ctx, A>: Mentionable<'a, Ctx, _Fctr = StackNodeFactory<Ctx, A::Fctr>>,

source§

fn empty(factory: A::Fctr) -> Self

Get an empty stack (Nullable::Null).
source§

fn f(factory: A::Fctr) -> Self::Fctr

Get the corresponding factory.
source§

fn add(self, element: A) -> Self

Add one element. Read more
source§

impl<'a, Ctx: Context<'a>, A: Mentionable<'a, Ctx> + Clone> ExtStackClone<'a, Ctx, A> for Stack<'a, Ctx, A>where StackNode<'a, Ctx, A>: Mentionable<'a, Ctx, _Fctr = StackNodeFactory<Ctx, A::Fctr>>, StackNodeFactory<Ctx, A::Fctr>: FactoryParse<'a, Ctx>,

source§

fn vec(self) -> StackVecWrapped<'a, Ctx, A>

Collect all the elements into a Vec.