pub struct QueryBuilder { /* private fields */ }Expand description
The nouns of the plugin contract that appear in the engine’s answers, so
an interface needs nothing but this crate.
Assemble a Query from optional parts (typically CLI flags).
Implementations§
Source§impl QueryBuilder
impl QueryBuilder
pub fn pattern(self, pattern: Option<impl Into<String>>) -> QueryBuilder
pub fn kind(self, kind: Option<impl Into<String>>) -> QueryBuilder
pub fn symbol(self, symbol: Option<SymbolKind>) -> QueryBuilder
pub fn name(self, name: Option<impl Into<String>>) -> QueryBuilder
pub fn language(self, language: Option<impl Into<LanguageId>>) -> QueryBuilder
pub fn build(self) -> Result<Query, QueryError>
Trait Implementations§
Source§impl Debug for QueryBuilder
impl Debug for QueryBuilder
Source§impl Default for QueryBuilder
impl Default for QueryBuilder
Source§fn default() -> QueryBuilder
fn default() -> QueryBuilder
Returns the “default value” for a type. Read more
Auto Trait Implementations§
impl Freeze for QueryBuilder
impl RefUnwindSafe for QueryBuilder
impl Send for QueryBuilder
impl Sync for QueryBuilder
impl Unpin for QueryBuilder
impl UnsafeUnpin for QueryBuilder
impl UnwindSafe for QueryBuilder
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
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
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 moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
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