pub struct LanguageConfiguration {
pub extensions: HashSet<String>,
pub indent: Option<String>,
pub grammar: Grammar,
}Fields§
§extensions: HashSet<String>A set of the filetype extensions associated with this language. This enables Topiary to switch to the right language based on the input filename.
indent: Option<String>The indentation string used for this language; defaults to “ “ (i.e., two spaces). Any string can be provided, but in most instances it will be some whitespace (e.g., “ “, “\t”, etc.)
grammar: GrammarThe tree-sitter source of the language, contains all that is needed to pull and compile the tree-sitter grammar
Trait Implementations§
Source§impl Clone for LanguageConfiguration
impl Clone for LanguageConfiguration
Source§fn clone(&self) -> LanguageConfiguration
fn clone(&self) -> LanguageConfiguration
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for LanguageConfiguration
impl Debug for LanguageConfiguration
Source§impl<'de> Deserialize<'de> for LanguageConfiguration
impl<'de> Deserialize<'de> for LanguageConfiguration
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for LanguageConfiguration
impl PartialEq for LanguageConfiguration
Source§impl Serialize for LanguageConfiguration
impl Serialize for LanguageConfiguration
impl StructuralPartialEq for LanguageConfiguration
Auto Trait Implementations§
impl Freeze for LanguageConfiguration
impl RefUnwindSafe for LanguageConfiguration
impl Send for LanguageConfiguration
impl Sync for LanguageConfiguration
impl Unpin for LanguageConfiguration
impl UnwindSafe for LanguageConfiguration
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
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