A selector is made up of a series of one or more 'roots'. This is a (global) instance of one of those roots. There's three types of root: tag, id, class.
Public Member Functions | |
void | SetLocals (List< LocalMatcher > locals) |
Sets the local matchers. More... | |
bool | Equals (RootMatcher rm) |
True if the given root matchers are equal. More... | |
override string | ToString () |
Gets a string of all the local matchers. More... | |
Public Member Functions inherited from Css.SelectorMatcher | |
virtual bool | TryMatch (Dom.Node context) |
Checks if the given node matches this root/local. More... | |
Public Attributes | |
string | Text |
The ID/Class/Tag. More... | |
bool | IsTarget |
True if this root is the target. More... | |
LocalMatcher[] | LocalMatchers |
Each root can have an optional collection of 'local' matchers. These will typically originate from pseudo-classes as well as the attribute selector. Things like :hover or :checked; they're local matchers. More... | |
StructureMatcher | NextMatcher |
The structure matcher between this and the following root, if any. More... | |
StructureMatcher | PreviousMatcher |
The structure matcher between this and the previous root, if any. More... | |
Public Attributes inherited from Css.SelectorMatcher | |
Selector | Selector |
The host selector. More... | |
Properties | |
virtual string | StyleText [get] |
The text as it's seen in a stylesheet. E.g. ID. More... | |
int | Specifity [get] |
The specifity. Add it to other roots to get the selectors specifity. More... | |
virtual int | RootSpecifity [get] |
This matchers specifity. More... | |
|
inline |
True if the given root matchers are equal.
|
inline |
Sets the local matchers.
|
inline |
Gets a string of all the local matchers.
bool Css.RootMatcher.IsTarget |
True if this root is the target.
LocalMatcher [] Css.RootMatcher.LocalMatchers |
Each root can have an optional collection of 'local' matchers. These will typically originate from pseudo-classes as well as the attribute selector. Things like :hover or :checked; they're local matchers.
StructureMatcher Css.RootMatcher.NextMatcher |
The structure matcher between this and the following root, if any.
StructureMatcher Css.RootMatcher.PreviousMatcher |
The structure matcher between this and the previous root, if any.
string Css.RootMatcher.Text |
The ID/Class/Tag.
|
getprotected |
This matchers specifity.
|
get |
The specifity. Add it to other roots to get the selectors specifity.
|
get |
The text as it's seen in a stylesheet. E.g. ID.