Struct tree_sitter::QueryMatch
source · pub struct QueryMatch<'cursor, 'tree> {
pub pattern_index: usize,
pub captures: &'cursor [QueryCapture<'tree>],
/* private fields */
}
Fields§
§pattern_index: usize
§captures: &'cursor [QueryCapture<'tree>]
Implementations§
source§impl<'tree> QueryMatch<'_, 'tree>
impl<'tree> QueryMatch<'_, 'tree>
pub const fn id(&self) -> u32
pub fn remove(&self)
pub fn nodes_for_capture_index( &self, capture_ix: u32 ) -> impl Iterator<Item = Node<'tree>> + '_
pub fn satisfies_text_predicates<I: AsRef<[u8]>>( &self, query: &Query, buffer1: &mut Vec<u8>, buffer2: &mut Vec<u8>, text_provider: &mut impl TextProvider<I> ) -> bool
Trait Implementations§
Auto Trait Implementations§
impl<'cursor, 'tree> RefUnwindSafe for QueryMatch<'cursor, 'tree>
impl<'cursor, 'tree> !Send for QueryMatch<'cursor, 'tree>
impl<'cursor, 'tree> !Sync for QueryMatch<'cursor, 'tree>
impl<'cursor, 'tree> Unpin for QueryMatch<'cursor, 'tree>
impl<'cursor, 'tree> UnwindSafe for QueryMatch<'cursor, 'tree>
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