public interface Selector
way[highway=residential] { width: 10; color: blue; }The selector decides, if the declaration block gets applied or not. All implementing classes of Selector are immutable.
Modifier and Type | Interface and Description |
---|---|
static class |
Selector.AbstractSelector
Super class of
Selector.GeneralSelector and
Selector.LinkSelector . |
static class |
Selector.ChildOrParentSelector
Represents a child selector or a parent selector.
|
static class |
Selector.ChildOrParentSelectorType
The type of child of parent selector.
|
static class |
Selector.GeneralSelector
General selector.
|
static class |
Selector.LinkSelector
In a child selector, conditions on the link between a parent and a child object.
|
static class |
Selector.OptimizedGeneralSelector
Superclass of
Selector.GeneralSelector . |
Modifier and Type | Method and Description |
---|---|
Range |
getRange()
Returns the scale range, an interval of the form "lower < x <= upper" where 0 <= lower < upper.
|
Subpart |
getSubpart()
Returns the subpart, if supported.
|
boolean |
matches(Environment env)
Apply the selector to the primitive and check if it matches.
|
Selector |
optimizedBaseCheck()
Create an "optimized" copy of this selector that omits the base check.
|
boolean matches(Environment env)
env
- the Environment. env.mc and env.layer are read-only when matching a selector.
env.source is not needed. This method will set the matchingReferrers field of env as
a side effect! Make sure to clear it before invoking this method.Subpart getSubpart()
::subpart
syntax).java.lang.UnsupportedOperationException
- if not supportedRange getRange()
java.lang.UnsupportedOperationException
- if not supportedSelector optimizedBaseCheck()