pub enum Event {
StreamStart,
StreamEnd,
DocumentStart {
explicit: bool,
version: Option<(u8, u8)>,
tags: Vec<(String, String)>,
},
DocumentEnd {
explicit: bool,
},
MappingStart {
anchor: Option<String>,
tag: Option<String>,
},
MappingEnd,
SequenceStart {
anchor: Option<String>,
tag: Option<String>,
},
SequenceEnd,
Scalar {
value: String,
style: ScalarStyle,
anchor: Option<String>,
tag: Option<String>,
},
Alias {
name: String,
},
Comment {
text: String,
},
}Expand description
A high-level YAML parse event.
Variants§
StreamStart
The stream has started.
StreamEnd
The stream has ended.
DocumentStart
A document has started.
Fields
The %TAG directive pairs (handle, prefix).
DocumentEnd
A document has ended.
MappingStart
A mapping node has started.
MappingEnd
A mapping node has ended.
SequenceStart
A sequence node has started.
SequenceEnd
A sequence node has ended.
Scalar
A scalar node.
Alias
An alias node.
Comment
A YAML comment.
Trait Implementations§
impl Eq for Event
impl StructuralPartialEq for Event
Auto Trait Implementations§
impl Freeze for Event
impl RefUnwindSafe for Event
impl Send for Event
impl Sync for Event
impl Unpin for Event
impl UnsafeUnpin for Event
impl UnwindSafe for Event
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