[][src]Struct rslint_core::DirectiveParser

pub struct DirectiveParser<'store> {
    pub root_node: SyntaxNode,
    pub declarator: String,
    // some fields omitted
}

Fields

root_node: SyntaxNodedeclarator: String

A string denoting the start of a directive, rslint- by default.

Implementations

impl<'store> DirectiveParser<'store>[src]

pub fn new(
    root_node: SyntaxNode,
    file_id: usize,
    store: &'store CstRuleStore
) -> Self
[src]

Make a new directive parser from the root node of a file.

Panics

Panics if the node's kind is not SCRIPT or MODULE

pub fn get_file_directives(
    &self
) -> Result<Vec<DirectiveParseResult>, Diagnostic>
[src]

Auto Trait Implementations

impl<'store> !RefUnwindSafe for DirectiveParser<'store>

impl<'store> Send for DirectiveParser<'store>

impl<'store> Sync for DirectiveParser<'store>

impl<'store> Unpin for DirectiveParser<'store>

impl<'store> !UnwindSafe for DirectiveParser<'store>

Blanket Implementations

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

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

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

impl<T> Erasable for T

impl<T> From<T> for T[src]

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

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

type Error = Infallible

The type returned in the event of a conversion error.

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

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

The type returned in the event of a conversion error.