[][src]Struct nu_protocol::value::column_path::ColumnPath

pub struct ColumnPath { /* fields omitted */ }

The fundamental path primitive to descrive how to navigate through a table to get to a sub-item. A path member can be either a word or a number. Words/strings are taken to mean a column name, and numbers are the row number. Taken together they describe which column or row to narrow to in order to get data.

Rows must follow column names, they can't come first. eg) foo.1 is valid where 1.foo is not.

Implementations

impl ColumnPath[src]

pub fn members(&self) -> &Vec<PathMember>[src]

impl ColumnPath[src]

pub fn new(members: Vec<PathMember>) -> Self[src]

Constructs a new ColumnPath.

impl ColumnPath[src]

pub fn iter(&self) -> impl Iterator<Item = &PathMember>[src]

Iterate over the members of the column path

pub fn split_last(&self) -> Option<(&PathMember, &[PathMember])>[src]

Returns the last member and a slice of the remaining members

pub fn last(&self) -> Option<&PathMember>[src]

Returns the last member

pub fn build(text: &Spanned<String>) -> ColumnPath[src]

Trait Implementations

impl Clone for ColumnPath[src]

impl Debug for ColumnPath[src]

impl<'de> Deserialize<'de> for ColumnPath[src]

impl Eq for ColumnPath[src]

impl HasFallibleSpan for ColumnPath[src]

fn maybe_span(&self) -> Option<Span>[src]

Creates a span that will cover the column path, if possible

impl Hash for ColumnPath[src]

impl Ord for ColumnPath[src]

impl PartialEq<ColumnPath> for ColumnPath[src]

impl PartialOrd<ColumnPath> for ColumnPath[src]

impl PrettyDebug for ColumnPath[src]

fn pretty(&self) -> DebugDocBuilder[src]

Gets the ColumnPath ready to be pretty-printed

impl Serialize for ColumnPath[src]

impl StructuralEq for ColumnPath[src]

impl StructuralPartialEq for ColumnPath[src]

Auto Trait Implementations

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> DeserializeOwned for T where
    T: for<'de> Deserialize<'de>, 
[src]

impl<Q, K> Equivalent<K> for Q where
    K: Borrow<Q> + ?Sized,
    Q: Eq + ?Sized
[src]

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

impl<T> HasFallibleSpan for T where
    T: HasSpan
[src]

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

impl<T> IntoSpanned for T where
    T: HasFallibleSpan
[src]

type Output = T

impl<T> PrettyDebugWithSource for T where
    T: PrettyDebug
[src]

impl<T> SpannedItem for T[src]

impl<T> TaggedItem for T[src]

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

type Owned = T

The resulting type after obtaining ownership.

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.