pub struct HistoryEntry {
pub entry_uuid: Uuid,
pub expression: Token,
/* private fields */
}Expand description
Individual history entry retaining it’s UUID, parser tokens, and textual rendition.
Fields§
§entry_uuid: UuidUUID of the entry.
expression: TokenParser tokens of the entry, basically the entire expression parsed down into it’s most basic form
Implementations§
Source§impl HistoryEntry
impl HistoryEntry
Sourcepub fn new(expression: &Token, session: &Session) -> Self
pub fn new(expression: &Token, session: &Session) -> Self
Creates a new entry struct from parser tokens and the desired amount of decimal places to render.
Sourcepub fn only_equality(&self) -> &Token
pub fn only_equality(&self) -> &Token
Gets the entry with only the equality
Sourcepub fn render_without_equality(&self, session: &Session) -> String
pub fn render_without_equality(&self, session: &Session) -> String
Renders the entry without an equal sign, nor everything right of it.
Just returns the expression unmodified if there is no equal sign.
Trait Implementations§
Source§impl Clone for HistoryEntry
impl Clone for HistoryEntry
Source§fn clone(&self) -> HistoryEntry
fn clone(&self) -> HistoryEntry
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for HistoryEntry
impl Debug for HistoryEntry
Source§impl<'de> Deserialize<'de> for HistoryEntry
impl<'de> Deserialize<'de> for HistoryEntry
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for HistoryEntry
impl PartialEq for HistoryEntry
Source§impl Serialize for HistoryEntry
impl Serialize for HistoryEntry
impl StructuralPartialEq for HistoryEntry
Auto Trait Implementations§
impl Freeze for HistoryEntry
impl RefUnwindSafe for HistoryEntry
impl Send for HistoryEntry
impl Sync for HistoryEntry
impl Unpin for HistoryEntry
impl UnwindSafe for HistoryEntry
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more