Struct syntect::highlighting::ScopeSelector
[−]
[src]
pub struct ScopeSelector { /* fields omitted */ }
A single selector consisting of a stack to match and a possible stack to exclude from being matched.
You probably want ScopeSelectors
which is this but with union support.
Methods
impl ScopeSelector
[src]
fn does_match(&self, stack: &[Scope]) -> Option<MatchPower>
Checks if this selector matches a given scope stack.
See ScopeSelectors#does_match
for more info.
fn extract_single_scope(&self) -> Option<Scope>
If this selector is really just a single scope, return it
Trait Implementations
impl Debug for ScopeSelector
[src]
impl Clone for ScopeSelector
[src]
fn clone(&self) -> ScopeSelector
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more
impl PartialEq for ScopeSelector
[src]
fn eq(&self, __arg_0: &ScopeSelector) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &ScopeSelector) -> bool
This method tests for !=
.
impl Eq for ScopeSelector
[src]
impl Default for ScopeSelector
[src]
fn default() -> ScopeSelector
Returns the "default value" for a type. Read more
impl FromStr for ScopeSelector
[src]
type Err = ParseScopeError
The associated error which can be returned from parsing.
fn from_str(s: &str) -> Result<ScopeSelector, ParseScopeError>
Parses a scope stack followed optionally by (one or more) " -" and then a scope stack to exclude