pub enum TokenType {
LeftBrace,
RightBrace,
LeftBracket,
RightBracket,
Colon,
Comma,
String(String),
Number(f64),
Boolean(bool),
Null,
}Expand description
The specific type of a Token.
This represents the smallest meaningful units of JSON grammar.
Variants§
LeftBrace
{
RightBrace
}
LeftBracket
[
RightBracket
]
Colon
:
Comma
,
String(String)
A string, e.g., "hello"
Number(f64)
A number, e.g., 123.4
Boolean(bool)
A boolean, true or false
Null
The null literal
Trait Implementations§
impl StructuralPartialEq for TokenType
Auto Trait Implementations§
impl Freeze for TokenType
impl RefUnwindSafe for TokenType
impl Send for TokenType
impl Sync for TokenType
impl Unpin for TokenType
impl UnwindSafe for TokenType
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