Struct g_code::parse::ast::Line [−][src]
A sequence of GCode that is either followed by a Newline or at the end of a file.
Implementations
impl<'input> Line<'input>[src]
pub fn iter_fields<'a>(&'a self) -> impl Iterator<Item = &'a Field<'_>>[src]
Iterate by Field in a line of GCode.
pub fn validate_checksum(&'input self) -> Option<Result<(), u8>>[src]
Validates Line::checksum against the fields that the line contains.
If the line has no checksum, this will return Option::None.
If the line does have a checksum, this will return an empty Result::Ok
or an Result::Err containing the computed checksum that differs from the actual.
pub fn iter_bytes(&'input self) -> impl Iterator<Item = &'input u8>[src]
Iterate over ALL u8 in a line.
pub fn compute_checksum(&'input self) -> u8[src]
Trait Implementations
impl<'input> Clone for Line<'input>[src]
impl<'input> Debug for Line<'input>[src]
impl<'input> Eq for Line<'input>[src]
impl<'input> PartialEq<Line<'input>> for Line<'input>[src]
impl<'input> Spanned for Line<'input>[src]
impl<'input> StructuralEq for Line<'input>[src]
impl<'input> StructuralPartialEq for Line<'input>[src]
Auto Trait Implementations
impl<'input> RefUnwindSafe for Line<'input>[src]
impl<'input> Send for Line<'input>[src]
impl<'input> Sync for Line<'input>[src]
impl<'input> Unpin for Line<'input>[src]
impl<'input> UnwindSafe for Line<'input>[src]
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,
pub 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.
pub fn to_owned(&self) -> T[src]
pub 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.
pub 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>,