Struct LkPathArray

#[repr(C)]
pub struct LkPathArray<const N: usize = linkspace_point::::path::LkPathArray::{constant#0}> { pub roots: Roots, /* private fields */ }

Fields§

§roots: Roots

Implementations§

§

impl LkPathArray

pub const EMPTY: LkPathArray = Self::EMPTY_CONST_SIZED

pub const INVALID: LkPathArray<0>

This triggers MissingRoots error on deserialize::LkPath::from_bytes

pub const fn from_path(value: &LkPath) -> LkPathArray

pub fn extend_from_iter<A, T>(&mut self, iter: T) -> Result<(), LkPathError>
where A: AsRef<[u8]>, T: IntoIterator<Item = A>,

pub fn try_from_iter<A, T>(iter: T) -> Result<LkPathArray, LkPathError>
where A: AsRef<[u8]>, T: IntoIterator<Item = A>,

§

impl<const N: usize> LkPathArray<N>

pub const EMPTY_CONST_SIZED: LkPathArray<N>

pub const fn push(&mut self, part: &[u8]) -> Result<(), LkPathError>

pub const fn try_from_path( path: &LkPath, ) -> Result<LkPathArray<N>, CapacityError>

§

impl LkPathArray

pub fn try_from_ablist(ablist: &ABList) -> Result<LkPathArray, LkPathExprError>

§

impl LkPathArray

pub fn parse_eval_basic( st: &str, ) -> Result<LkPathArray, ABEError<LkPathExprError>>

§

impl<const N: usize> LkPathArray<N>

pub const fn as_path(&self) -> &LkPath

pub const fn as_path_mut(&mut self) -> &mut LkPath

Methods from Deref<Target = LkPath>§

pub fn to_array(&self) -> LkPathArray

pub fn pop_last(&self) -> (&LkPathSegm, Option<LkPathPart<'_>>)

pub fn ablist(&self) -> ABList

pub const EMPTY: &'static LkPath

pub fn segments(&self) -> &LkPathSegm

pub fn double_check_parts(&self) -> Result<(), LkPathError>

pub fn as_bytes(&self) -> &[u8]

pub fn as_bytes_inclusive(&self) -> &[u8]

pub fn parts(&self) -> [Option<LkPathPart<'_>>; 8]

pub fn parts_bytes(&self) -> [&[u8]; 8]

pub fn parts_bytes_mut(&mut self) -> [&mut [u8]; 8]

pub fn nparts(&self) -> &u8

pub fn part0(&self) -> &[u8]

pub fn part0_mut(&mut self) -> &mut [u8]

pub fn part1(&self) -> &[u8]

pub fn part1_mut(&mut self) -> &mut [u8]

pub fn part2(&self) -> &[u8]

pub fn part2_mut(&mut self) -> &mut [u8]

pub fn part3(&self) -> &[u8]

pub fn part3_mut(&mut self) -> &mut [u8]

pub fn part4(&self) -> &[u8]

pub fn part4_mut(&mut self) -> &mut [u8]

pub fn part5(&self) -> &[u8]

pub fn part5_mut(&mut self) -> &mut [u8]

pub fn part6(&self) -> &[u8]

pub fn part6_mut(&mut self) -> &mut [u8]

pub fn part7(&self) -> &[u8]

pub fn part7_mut(&mut self) -> &mut [u8]

pub fn boxed(&self) -> Box<LkPath>

pub fn rc(&self) -> Rc<LkPath>

Methods from Deref<Target = LkPathSegm>§

pub fn try_into_array(&self) -> Result<LkPathArray, LkPathError>

pub fn alt_delimiter(&self, delim: Ctr) -> String

pub const EMPTY: &'static LkPathSegm

pub fn iter(&self) -> impl Iterator<Item = LkPathPart<'_>>

pub fn iter_checked( &self, ) -> impl Iterator<Item = Result<LkPathPart<'_>, LkPathError>>

pub fn is_empty(&self) -> bool

pub fn raw_segment_bytes(&self) -> &[u8]

pub fn starts_with(&self, other: &LkPathSegm) -> bool

pub fn shift(&self) -> (Option<LkPathPart<'_>>, &LkPathSegm)

Trait Implementations§

§

impl ABEValidator for LkPathArray

§

fn check(b: &[ABE]) -> Result<(), MatchError>

§

impl Borrow<LkPath> for LkPathArray

§

fn borrow(&self) -> &LkPath

Immutably borrows from an owned value. Read more
§

impl<const N: usize> Clone for LkPathArray<N>

§

fn clone(&self) -> LkPathArray<N>

Returns a copy of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
§

impl<const N: usize> Debug for LkPathArray<N>

§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
§

impl Default for LkPathArray

§

fn default() -> LkPathArray

Returns the “default value” for a type. Read more
§

impl<const N: usize> Deref for LkPathArray<N>

§

type Target = LkPath

The resulting type after dereferencing.
§

fn deref(&self) -> &<LkPathArray<N> as Deref>::Target

Dereferences the value.
§

impl<const N: usize> DerefMut for LkPathArray<N>

§

fn deref_mut(&mut self) -> &mut <LkPathArray<N> as Deref>::Target

Mutably dereferences the value.
§

impl<const N: usize> Display for LkPathArray<N>

§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
§

impl From<&LkPath> for LkPathArray

§

fn from(value: &LkPath) -> LkPathArray

Converts to this type from the input type.
§

impl FromStr for LkPathArray

§

type Err = ABEError<LkPathExprError>

The associated error which can be returned from parsing.
§

fn from_str(s: &str) -> Result<LkPathArray, <LkPathArray as FromStr>::Err>

Parses a string s to return a value of this type. Read more
§

impl Ord for LkPathArray

§

fn cmp(&self, other: &LkPathArray) -> Ordering

This method returns an Ordering between self and other. Read more
1.21.0 · Source§

fn max(self, other: Self) -> Self
where Self: Sized,

Compares and returns the maximum of two values. Read more
1.21.0 · Source§

fn min(self, other: Self) -> Self
where Self: Sized,

Compares and returns the minimum of two values. Read more
1.50.0 · Source§

fn clamp(self, min: Self, max: Self) -> Self
where Self: Sized,

Restrict a value to a certain interval. Read more
§

impl<const N: usize> PartialEq for LkPathArray<N>

§

fn eq(&self, other: &LkPathArray<N>) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
§

impl PartialOrd for LkPathArray

§

fn partial_cmp(&self, other: &LkPathArray) -> Option<Ordering>

This method returns an ordering between self and other values if one exists. Read more
1.0.0 · Source§

fn lt(&self, other: &Rhs) -> bool

Tests less than (for self and other) and is used by the < operator. Read more
1.0.0 · Source§

fn le(&self, other: &Rhs) -> bool

Tests less than or equal to (for self and other) and is used by the <= operator. Read more
1.0.0 · Source§

fn gt(&self, other: &Rhs) -> bool

Tests greater than (for self and other) and is used by the > operator. Read more
1.0.0 · Source§

fn ge(&self, other: &Rhs) -> bool

Tests greater than or equal to (for self and other) and is used by the >= operator. Read more
§

impl ToABE for LkPathArray

§

fn write_abe(&self, out: &mut dyn FnMut(ABE))

§

fn write_abe_str(&self, out: &mut dyn Write) -> Result<(), Error>

§

fn to_abe_str(&self) -> String

§

fn to_abe(&self) -> Vec<ABE>

Source§

impl TryAsSpace for LkPathArray

Source§

fn try_as_space(&self, scope: &dyn LkEnv) -> Result<Space>

§

impl TryFrom<ABList> for LkPathArray

§

type Error = LkPathExprError

The type returned in the event of a conversion error.
§

fn try_from( ablist: ABList, ) -> Result<LkPathArray, <LkPathArray as TryFrom<ABList>>::Error>

Performs the conversion.
§

impl<const N: usize> Copy for LkPathArray<N>

§

impl<const N: usize> Eq for LkPathArray<N>

§

impl<const N: usize> StructuralPartialEq for LkPathArray<N>

Auto Trait Implementations§

§

impl<const N: usize> Freeze for LkPathArray<N>

§

impl<const N: usize> RefUnwindSafe for LkPathArray<N>

§

impl<const N: usize> Send for LkPathArray<N>

§

impl<const N: usize> Sync for LkPathArray<N>

§

impl<const N: usize> Unpin for LkPathArray<N>

§

impl<const N: usize> UnwindSafe for LkPathArray<N>

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T> Instrument for T

§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided [Span], returning an Instrumented wrapper. Read more
§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

impl<P, T> Receiver for P
where P: Deref<Target = T> + ?Sized, T: ?Sized,

Source§

type Target = T

🔬This is a nightly-only experimental API. (arbitrary_self_types)
The target type on which the method may be called.
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T> ToString for T
where T: Display + ?Sized,

Source§

fn to_string(&self) -> String

Converts the given value to a String. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

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

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

§

fn vzip(self) -> V

§

impl<T> WithSubscriber for T

§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a [WithDispatch] wrapper. Read more
§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a [WithDispatch] wrapper. Read more