Enum jsonpath_plus::ast::Segment
source · [−]#[non_exhaustive]
pub enum Segment {
Dot(Dot, RawSelector),
Bracket(Bracket, BracketSelector),
Recursive(DotDot, Option<RawSelector>),
}
Expand description
A single segement selector in a path
Variants (Non-exhaustive)
This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
Dot(Dot, RawSelector)
A dot followed by a simple selector, .a
Bracket(Bracket, BracketSelector)
A bracket containing a complex selector, [?(...)]
Recursive(DotDot, Option<RawSelector>)
A recursive selector optionally followed by a simple selector, ..foo
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for Segment
impl Send for Segment
impl Sync for Segment
impl Unpin for Segment
impl UnwindSafe for Segment
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more