Struct g_code::parse::ast::Line [−][src]
pub struct Line<'input> { /* fields omitted */ }A sequence of GCode that is either followed by a Newline or at the end of a file.
Implementations
impl<'input> Line<'input>[src]
impl<'input> Line<'input>[src]pub fn iter_fields(&self) -> impl Iterator<Item = &Field<'input>>[src]
pub fn iter_fields(&self) -> impl Iterator<Item = &Field<'input>>[src]Iterate by Field in a line of GCode.
pub fn validate_checksum(&self) -> Option<Result<(), u8>>[src]
pub fn validate_checksum(&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 compute_checksum(&self) -> u8[src]
pub fn compute_checksum(&self) -> u8[src]Trait Implementations
impl<'input> Eq 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>
impl<'input> Send for Line<'input>
impl<'input> Sync for Line<'input>
impl<'input> Unpin for Line<'input>
impl<'input> UnwindSafe for Line<'input>
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]pub fn borrow_mut(&mut self) -> &mut T[src]
pub fn borrow_mut(&mut self) -> &mut T[src]Mutably borrows from an owned value. Read more
impl<T> ToOwned for T where
T: Clone, [src]
impl<T> ToOwned for T where
T: Clone, [src]type Owned = T
type Owned = TThe resulting type after obtaining ownership.
pub fn to_owned(&self) -> T[src]
pub fn to_owned(&self) -> T[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)[src]
pub fn clone_into(&self, target: &mut T)[src]🔬 This is a nightly-only experimental API. (toowned_clone_into)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more