[][src]Struct aces::Context

pub struct Context { /* fields omitted */ }

A representation of shared state.

This is an umbrella type which, currently, includes a collection of Atoms and two symbol tables, one for structure names, and another for node names.

For usage, see ContextHandle type, Contextual trait and InContext struct.

Methods

impl Context[src]

pub fn new_as_handle() -> ContextHandle[src]

Creates a new Context instance and returns a corresponding ContextHandle.

Calling this method is the only public way of creating new Context instances.

pub fn share_node_name<S: AsRef<str>>(&mut self, node_name: S) -> NodeID[src]

pub fn get_node_name(&self, node_id: NodeID) -> Option<&str>[src]

pub fn get_node_id<S: AsRef<str>>(&self, node_name: S) -> Option<NodeID>[src]

pub fn share_port(&mut self, port: &mut Port) -> PortID[src]

pub fn get_port(&self, port_id: PortID) -> Option<&Port>[src]

pub fn get_port_mut(&mut self, port_id: PortID) -> Option<&mut Port>[src]

pub fn get_antiport_id(&self, port_id: PortID) -> Option<PortID>[src]

impl Context[src]

pub fn with<'a, T: Contextual>(&'a self, thing: &'a T) -> InContext<'a, T>[src]

pub fn with_mut<'a, T: Contextual>(
    &'a self,
    thing: &'a mut T
) -> InContextMut<'a, T>
[src]

pub fn with_docked<'a, T: Contextual>(
    &'a self,
    face: Face,
    thing: &'a T
) -> InContext<'a, T>
[src]

pub fn with_docked_mut<'a, T: Contextual>(
    &'a self,
    face: Face,
    thing: &'a mut T
) -> InContextMut<'a, T>
[src]

Trait Implementations

impl PartialEq<Context> for Context[src]

#[must_use] fn ne(&self, other: &Rhs) -> bool1.0.0[src]

This method tests for !=.

impl Eq for Context[src]

impl Debug for Context[src]

Auto Trait Implementations

impl Sync for Context

impl Unpin for Context

impl Send for Context

impl UnwindSafe for Context

impl RefUnwindSafe for Context

Blanket Implementations

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<Reference, Outer, OuterFieldType, Inner> HasPart<Nested<Outer, Inner>> for Reference where
    Inner: Part,
    Outer: Part<PartType = Field<OuterFieldType>>,
    OuterFieldType: HasPart<Inner, RawTarget = OuterFieldType> + PartialRefTarget + ?Sized,
    Reference: HasPart<Outer> + ?Sized