[][src]Struct tree_sitter::Parser

pub struct Parser(_);

Methods

impl Parser[src]

pub fn new() -> Parser[src]

pub fn set_language(&mut self, language: Language) -> Result<(), String>[src]

pub fn logger(&self) -> Option<&Box<dyn FnMut(LogType, &str) + 'a>>[src]

pub fn set_logger(&mut self, logger: Option<Box<dyn FnMut(LogType, &str) + 'a>>)[src]

pub fn parse<T: AsRef<[u8]>>(
    &mut self,
    input: T,
    old_tree: Option<&Tree>
) -> Option<Tree>
[src]

pub fn parse_str(
    &mut self,
    input: &str,
    old_tree: Option<&Tree>
) -> Option<Tree>
[src]

Deprecated since 0.3.6:

please use parse<T> instead

pub fn parse_utf8<'a, T: FnMut(usize, Point) -> &'a [u8]>(
    &mut self,
    input: &mut T,
    old_tree: Option<&Tree>
) -> Option<Tree>
[src]

pub fn parse_utf16<'a, T: 'a + FnMut(usize, Point) -> &'a [u16]>(
    &mut self,
    input: &mut T,
    old_tree: Option<&Tree>
) -> Option<Tree>
[src]

pub fn parse_utf8_io(
    &mut self,
    input: impl Read + Seek,
    old_tree: Option<&Tree>
) -> Result<Option<Tree>>
[src]

pub fn reset(&mut self)[src]

pub fn set_operation_limit(&mut self, limit: usize)[src]

pub fn set_included_ranges(&mut self, ranges: &[Range])[src]

Trait Implementations

impl Send for Parser[src]

impl Drop for Parser[src]

Auto Trait Implementations

impl !Sync for Parser

Blanket Implementations

impl<T, U> Into for T where
    U: From<T>, 
[src]

impl<T> From for T[src]

impl<T, U> TryFrom for T where
    U: Into<T>, 
[src]

type Error = !

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> Borrow for T where
    T: ?Sized
[src]

impl<T, U> TryInto for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

🔬 This is a nightly-only experimental API. (try_from)

The type returned in the event of a conversion error.

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> BorrowMut for T where
    T: ?Sized
[src]