pub enum TerminalValues {
Range(u32, u32),
Concatenation(Vec<u32>),
}Expand description
Terminal created by numerical values.
Variants§
Range(u32, u32)
A single value within a range (e.g. %x01-ff).
Concatenation(Vec<u32>)
A terminal defined by a concatenation of values (e.g. %x0f.f1.ce).
Implementations§
Source§impl TerminalValues
impl TerminalValues
Sourcepub fn range(from: u32, to: u32) -> TerminalValues
pub fn range(from: u32, to: u32) -> TerminalValues
Create an alternation from a lower and upper bound (both inclusive).
See ABNF’s “value range alternatives”, e.g. %c##-##.
Sourcepub fn sequence(alts: &[u32]) -> TerminalValues
pub fn sequence(alts: &[u32]) -> TerminalValues
Create a terminal from a series of values.
See ABNF’s terminal notation, e.g. %c##.##.##.
Trait Implementations§
Source§impl Clone for TerminalValues
impl Clone for TerminalValues
Source§fn clone(&self) -> TerminalValues
fn clone(&self) -> TerminalValues
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 TerminalValues
impl Debug for TerminalValues
Source§impl PartialEq for TerminalValues
impl PartialEq for TerminalValues
impl Eq for TerminalValues
impl StructuralPartialEq for TerminalValues
Auto Trait Implementations§
impl Freeze for TerminalValues
impl RefUnwindSafe for TerminalValues
impl Send for TerminalValues
impl Sync for TerminalValues
impl Unpin for TerminalValues
impl UnwindSafe for TerminalValues
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