Struct fixity::path::Path[][src]

pub struct Path { /* fields omitted */ }

Implementations

impl Path[src]

pub fn new() -> Self[src]

pub fn is_root_map(&self) -> bool[src]

pub fn from_segments(segments: Vec<Segment>) -> Self[src]

pub fn push<T>(&mut self, segment: T) where
    T: Into<Segment>, 
[src]

pub fn into_push<T>(self, segment: T) -> Self where
    T: Into<Segment>, 
[src]

pub fn len(&self) -> usize[src]

pub fn pop(&mut self) -> Option<Segment>[src]

Pop the last Segment from the Path.

pub fn is_empty(&self) -> bool[src]

Returns true is this Path is empty.

pub fn reverse(&mut self)[src]

Reverses the order of Keys in the Path, in place.

pub fn from_map<T>(map_segment: T) -> Self where
    T: Into<MapSegment>, 
[src]

pub fn push_map<T>(&mut self, map_segment: T) where
    T: Into<MapSegment>, 
[src]

pub fn into_map<T>(self, map_segment: T) -> Self where
    T: Into<MapSegment>, 
[src]

pub async fn resolve<C>(
    &self,
    storage: &C,
    root_addr: Option<Addr>
) -> Result<Vec<Option<Addr>>, Error> where
    C: CacheRead
[src]

pub async fn resolve_last<C>(
    &self,
    storage: &C,
    addr: Option<Addr>
) -> Result<Option<Addr>, Error> where
    C: CacheRead
[src]

pub async fn update<C>(
    &self,
    storage: &C,
    resolved_addrs: Vec<Option<Addr>>,
    new_last_segment_addr: Addr
) -> Result<Addr, Error> where
    C: CacheRead + CacheWrite
[src]

impl Path[src]

pub fn from_cli_str(s: &str) -> Result<Self, Error>[src]

An experimental implementation to parse a Path value from a string focused interface; eg parsing values from the command line.

This differs from a FromStr implementation in that there may be multiple interfaces tailored towards different user interfaces.

Important

The implementation currently assumes every segment is a map Segment. A more robust implementation is warranted.

Trait Implementations

impl Clone for Path[src]

impl Debug for Path[src]

impl Default for Path[src]

impl Display for Path[src]

impl Eq for Path[src]

impl<T> From<&'_ [T]> for Path where
    T: Clone + Into<Segment>, 
[src]

impl<T> From<Vec<T, Global>> for Path where
    T: Into<Segment>, 
[src]

impl Hash for Path[src]

impl IntoIterator for Path[src]

type Item = Segment

The type of the elements being iterated over.

type IntoIter = IntoIter<Self::Item>

Which kind of iterator are we turning this into?

impl Ord for Path[src]

impl PartialEq<Path> for Path[src]

impl PartialOrd<Path> for Path[src]

impl StructuralEq for Path[src]

impl StructuralPartialEq for Path[src]

Auto Trait Implementations

impl RefUnwindSafe for Path

impl Send for Path

impl Sync for Path

impl Unpin for Path

impl UnwindSafe for Path

Blanket Implementations

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

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

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

impl<T> Conv for T

impl<T> Conv for T

impl<T> FmtForward for T

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

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

impl<T> Pipe for T where
    T: ?Sized

impl<T> Pipe for T

impl<T> PipeAsRef for T

impl<T> PipeBorrow for T

impl<T> PipeDeref for T

impl<T> PipeRef for T

impl<T> Same<T> for T

type Output = T

Should always be Self

impl<T> Tap for T

impl<T> Tap for T

impl<T, U> TapAsRef<U> for T where
    U: ?Sized

impl<T, U> TapBorrow<U> for T where
    U: ?Sized

impl<T> TapDeref for T

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T> ToString for T where
    T: Display + ?Sized
[src]

impl<T> TryConv for T

impl<T> TryConv for T

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.