Ruby

Struct Ruby 

Source
pub struct Ruby {
    pub class_query: Query,
    pub function_declaration_query: Query,
    pub field_query: Query,
}

Fields§

§class_query: Query§function_declaration_query: Query§field_query: Query

Implementations§

Source§

impl Ruby

Source

pub const BEGIN: &'static str = "begin"

Source

pub const BINARY: &'static str = "binary"

Source

pub const BLOCK: &'static str = "block"

Source

pub const BREAK: &'static str = "break"

Source

pub const CALL: &'static str = "call"

Source

pub const CASE: &'static str = "case"

Source

pub const CLASS_VARIABLE: &'static str = "class_variable"

Source

pub const COMMENT: &'static str = "comment"

Source

pub const CONDITIONAL: &'static str = "conditional"

Source

pub const CONSTANT: &'static str = "constant"

Source

pub const DO_BLOCK: &'static str = "do_block"

Source

pub const ELSE: &'static str = "else"

Source

pub const ELSIF: &'static str = "elsif"

Source

pub const FOR: &'static str = "for"

Source

pub const GLOBAL_VARIABLE: &'static str = "global_variable"

Source

pub const IDENTIFIER: &'static str = "identifier"

Source

pub const IF: &'static str = "if"

Source

pub const INITIALIZE: &'static str = "initialize"

Source

pub const INSTANCE_VARIABLE: &'static str = "instance_variable"

Source

pub const METHOD_CALL: &'static str = "method_call"

Source

pub const METHOD: &'static str = "method"

Source

pub const NEXT: &'static str = "next"

Source

pub const OPERATOR_ASSIGNMENT: &'static str = "operator_assignment"

Source

pub const PROGRAM: &'static str = "program"

Source

pub const RESCUE: &'static str = "rescue"

Source

pub const RETURN: &'static str = "return"

Source

pub const SELF: &'static str = "self"

Source

pub const SINGLETON_METHOD: &'static str = "singleton_method"

Source

pub const STRING: &'static str = "string"

Source

pub const UNTIL: &'static str = "until"

Source

pub const WHEN: &'static str = "when"

Source

pub const WHILE: &'static str = "while"

Source

pub const LOGICAL_AND: &'static str = "&&"

Source

pub const LOGICAL_OR: &'static str = "||"

Source

pub const AND: &'static str = "and"

Source

pub const OR: &'static str = "or"

Trait Implementations§

Source§

impl Default for Ruby

Source§

fn default() -> Self

Returns the “default value” for a type. Read more
Source§

impl Language for Ruby

Source§

fn name(&self) -> &str

Source§

fn self_keyword(&self) -> Option<&str>

Source§

fn class_query(&self) -> &Query

Source§

fn function_declaration_query(&self) -> &Query

Source§

fn field_query(&self) -> &Query

Source§

fn invisible_container_nodes(&self) -> Vec<&str>

Source§

fn if_nodes(&self) -> Vec<&str>

Source§

fn elsif_nodes(&self) -> Vec<&str>

Source§

fn else_nodes(&self) -> Vec<&str>

Source§

fn ternary_nodes(&self) -> Vec<&str>

Source§

fn switch_nodes(&self) -> Vec<&str>

Source§

fn case_nodes(&self) -> Vec<&str>

Source§

fn loop_nodes(&self) -> Vec<&str>

Source§

fn except_nodes(&self) -> Vec<&str>

Source§

fn try_expression_nodes(&self) -> Vec<&str>

Source§

fn conditional_assignment_nodes(&self) -> Vec<&str>

Source§

fn jump_nodes(&self) -> Vec<&str>

Source§

fn return_nodes(&self) -> Vec<&str>

Source§

fn binary_nodes(&self) -> Vec<&str>

Source§

fn boolean_operator_nodes(&self) -> Vec<&str>

Source§

fn field_nodes(&self) -> Vec<&str>

Source§

fn call_nodes(&self) -> Vec<&str>

Source§

fn function_nodes(&self) -> Vec<&str>

Source§

fn closure_nodes(&self) -> Vec<&str>

Source§

fn comment_nodes(&self) -> Vec<&str>

Source§

fn string_nodes(&self) -> Vec<&str>

Source§

fn constructor_names(&self) -> Vec<&str>

Source§

fn iterator_method_identifiers(&self) -> Vec<&str>

Source§

fn call_identifiers( &self, source_file: &File, node: &Node<'_>, ) -> (Option<String>, String)

Source§

fn field_identifiers( &self, source_file: &File, node: &Node<'_>, ) -> (String, String)

Source§

fn tree_sitter_language(&self) -> Language

Source§

fn block_nodes(&self) -> Vec<&str>

Source§

fn destructor_names(&self) -> Vec<&str>

Source§

fn is_decorator_function(&self, _node: &Node<'_>) -> bool

Source§

fn is_instance_method(&self, _file: &File, _node: &Node<'_>) -> bool

Source§

fn is_jump_label(&self, _node: &Node<'_>) -> bool

Source§

fn all_operators(&self) -> Vec<&str>

Source§

fn all_operands(&self) -> Vec<&str>

Source§

fn implementation_query(&self) -> Option<&Query>

Source§

fn has_labeled_jumps(&self) -> bool

Source§

fn query(&self, query_source: &str) -> Query

Source§

fn parser(&self) -> Parser

Source§

fn has_field_names(&self) -> bool

Source§

fn sanitize_parameter_name(&self, parameter_name: String) -> Option<String>

Source§

fn get_parameter_names( &self, parameters_node: Node<'_>, source_file: &Arc<File>, ) -> Vec<String>

Source§

fn function_name_node<'a>(&'a self, node: &'a Node<'_>) -> Node<'a>

Auto Trait Implementations§

§

impl Freeze for Ruby

§

impl RefUnwindSafe for Ruby

§

impl Send for Ruby

§

impl Sync for Ruby

§

impl Unpin for Ruby

§

impl UnwindSafe for Ruby

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
Source§

impl<T> Pointable for T

Source§

const ALIGN: usize

The alignment of pointer.
Source§

type Init = T

The type for initializers.
Source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
Source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
Source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
Source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

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

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

Source§

fn vzip(self) -> V

Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

impl<T> ErasedDestructor for T
where T: 'static,