[−][src]Struct pl_lens::LensPath
Describes a lens relative to a source data structure.
Fields
elements: Vec<LensPathElement>
The path elements.
Implementations
impl LensPath
[src]
pub fn empty() -> LensPath
[src]
Creates a new LensPath
with no elements.
pub fn new(id: u64) -> LensPath
[src]
Creates a new LensPath
with a single element.
pub fn from_index(index: usize) -> LensPath
[src]
Creates a new LensPath
with a single index (for an indexed type such as Vec
).
pub fn from_pair(id0: u64, id1: u64) -> LensPath
[src]
Creates a new LensPath
with two elements.
pub fn from_vec(ids: Vec<u64>) -> LensPath
[src]
Creates a new LensPath
from a vector of element identifiers.
pub fn concat(lhs: LensPath, rhs: LensPath) -> LensPath
[src]
Creates a new LensPath
that is the concatenation of the two paths.
Trait Implementations
impl Clone for LensPath
[src]
impl Debug for LensPath
[src]
impl Eq for LensPath
[src]
impl Ord for LensPath
[src]
fn cmp(&self, other: &LensPath) -> Ordering
[src]
#[must_use]fn max(self, other: Self) -> Self
1.21.0[src]
#[must_use]fn min(self, other: Self) -> Self
1.21.0[src]
#[must_use]fn clamp(self, min: Self, max: Self) -> Self
[src]
impl PartialEq<LensPath> for LensPath
[src]
impl PartialOrd<LensPath> for LensPath
[src]
fn partial_cmp(&self, other: &LensPath) -> Option<Ordering>
[src]
fn lt(&self, other: &LensPath) -> bool
[src]
fn le(&self, other: &LensPath) -> bool
[src]
fn gt(&self, other: &LensPath) -> bool
[src]
fn ge(&self, other: &LensPath) -> bool
[src]
impl StructuralEq for LensPath
[src]
impl StructuralPartialEq for LensPath
[src]
Auto Trait Implementations
impl RefUnwindSafe for LensPath
impl Send for LensPath
impl Sync for LensPath
impl Unpin for LensPath
impl UnwindSafe for LensPath
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
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, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,