| Modifier and Type | Field and Description |
|---|---|
| private Selector | |
| private int | |
| private String | |
| private String | |
| private Ruleset | |
| private int | |
| private String | |
| private int | |
| private int | |
| private int | |
| private int | |
| public static final int | |
| private Selector | |
| public static final int | |
| private List | |
| public static final int | |
| public static final int | |
| public static final int | |
| public static final int | |
| private static int | |
| private int | selectorID
Give each a unique ID to be able to create a key to internalize Matcher.Mappers |
| private Selector | |
| public static final int |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public void | addAttributeEqualsCondition(String namespaceURI, String name, String value)
the CSS condition [attribute=value] |
| public void | |
| public void | addAttributeMatchesFirstPartCondition(String namespaceURI, String name, String value)
the CSS condition [attribute|=value] |
| public void | addAttributeMatchesListCondition(String namespaceURI, String name, String value)
the CSS condition [attribute~=value] |
| public void | addAttributePrefixCondition(String namespaceURI, String name, String value)
the CSS condition [attribute^=value] |
| public void | addAttributeSubstringCondition(String namespaceURI, String name, String value)
the CSS condition [attribute*=value] |
| public void | addAttributeSuffixCondition(String namespaceURI, String name, String value)
the CSS condition [attribute$=value] |
| public void | |
| private void | addCondition(Condition
The feature to be added to the Condition attribute c)Adds a feature to the Condition attribute of the Selector object |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | |
| public Selector | |
| pack-priv Object | Returns: The appropriateSibling valuePARAM e, TreeResolver treeRes)Gets the appropriateSibling attribute of the Selector object |
| public int | |
| public Selector | Returns: The chainedSelector valueget the next selector in the chain, for matching against elements along the appropriate axis |
| pack-priv static String | Returns: The elementStylingOrder valueGets the elementStylingOrder attribute of the Selector class |
| pack-priv String | Returns: The order valuereturns "a number in a large base" with specificity and specification order of selector |
| public String | Returns: The pseudoElement valueGets the pseudoElement attribute of the Selector object |
| public Ruleset | |
| public int | |
| public int | |
| public int | |
| public int | |
| public boolean | Returns: The pseudoClass valuethe values from AttributeResolver should be used. pc)query if a pseudoclass must apply for this selector |
| public boolean | matches(Object e, AttributeResolver attRes, TreeResolver treeRes)
Check if the given Element matches this selector. |
| public boolean | matchesDynamic(Object e, AttributeResolver attRes, TreeResolver treeRes)
Check if the given Element matches this selector's dynamic properties. |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | setPseudoClass(int
the values from AttributeResolver should be used. Once set
they cannot be unset. Note that the pseudo-classes should be set one
at a time, otherwise specificity of declaration becomes wrong. pc)set which pseudoclasses must apply for this selector |
| public void | setPseudoElement(String
The new pseudoElement value pseudoElement)check if selector queries for dynamic properties |
| public void | |
| public void | |
| public void | |
| public void | |
| public void | toCSS(StringBuilder sb, Set<Selector> stopAt)
Prints the selector chain to a StringBuilder, stopping when it hits a selector in the stopAt set. |
| public String |
| _ancestorSelector | back to summary |
|---|---|
| private Selector _ancestorSelector | |
| _axis | back to summary |
|---|---|
| private int _axis | |
| _name | back to summary |
|---|---|
| private String _name | |
| _namespaceURI | back to summary |
|---|---|
| private String _namespaceURI | |
| _parent | back to summary |
|---|---|
| private Ruleset _parent | |
| _pc | back to summary |
|---|---|
| private int _pc | |
| _pe | back to summary |
|---|---|
| private String _pe | |
| _pos | back to summary |
|---|---|
| private int _pos | |
| _specificityB | back to summary |
|---|---|
| private int _specificityB | |
| _specificityC | back to summary |
|---|---|
| private int _specificityC | |
| _specificityD | back to summary |
|---|---|
| private int _specificityD | |
| ACTIVE_PSEUDOCLASS | back to summary |
|---|---|
| public static final int ACTIVE_PSEUDOCLASS | |
| chainedSelector | back to summary |
|---|---|
| private Selector chainedSelector | |
| CHILD_AXIS | back to summary |
|---|---|
| public static final int CHILD_AXIS | |
| conditions | back to summary |
|---|---|
| private List<Condition> conditions | |
| DESCENDANT_AXIS | back to summary |
|---|---|
| public static final int DESCENDANT_AXIS | |
| FOCUS_PSEUDOCLASS | back to summary |
|---|---|
| public static final int FOCUS_PSEUDOCLASS | |
| HOVER_PSEUDOCLASS | back to summary |
|---|---|
| public static final int HOVER_PSEUDOCLASS | |
| IMMEDIATE_SIBLING_AXIS | back to summary |
|---|---|
| public static final int IMMEDIATE_SIBLING_AXIS | |
| selectorCount | back to summary |
|---|---|
| private static int selectorCount | |
| selectorID | back to summary |
|---|---|
| private int selectorID Give each a unique ID to be able to create a key to internalize Matcher.Mappers | |
| siblingSelector | back to summary |
|---|---|
| private Selector siblingSelector | |
| VISITED_PSEUDOCLASS | back to summary |
|---|---|
| public static final int VISITED_PSEUDOCLASS | |
| Selector | back to summary |
|---|---|
| public Selector() | |
| addAttributeEqualsCondition | back to summary |
|---|---|
| public void addAttributeEqualsCondition(String namespaceURI, String name, String value) the CSS condition [attribute=value] | |
| addAttributeExistsCondition | back to summary |
|---|---|
| public void addAttributeExistsCondition(String namespaceURI, String name) the CSS condition [attribute] | |
| addAttributeMatchesFirstPartCondition | back to summary |
|---|---|
| public void addAttributeMatchesFirstPartCondition(String namespaceURI, String name, String value) the CSS condition [attribute|=value] | |
| addAttributeMatchesListCondition | back to summary |
|---|---|
| public void addAttributeMatchesListCondition(String namespaceURI, String name, String value) the CSS condition [attribute~=value] | |
| addAttributePrefixCondition | back to summary |
|---|---|
| public void addAttributePrefixCondition(String namespaceURI, String name, String value) the CSS condition [attribute^=value] | |
| addAttributeSubstringCondition | back to summary |
|---|---|
| public void addAttributeSubstringCondition(String namespaceURI, String name, String value) the CSS condition [attribute*=value] | |
| addAttributeSuffixCondition | back to summary |
|---|---|
| public void addAttributeSuffixCondition(String namespaceURI, String name, String value) the CSS condition [attribute$=value] | |
| addClassCondition | back to summary |
|---|---|
| public void addClassCondition(String className) the CSS condition .class | |
| addCondition | back to summary |
|---|---|
| private void addCondition(Condition c) Adds a feature to the Condition attribute of the Selector object
| |
| addEvenChildCondition | back to summary |
|---|---|
| public void addEvenChildCondition() the CSS condition that element has pseudo-class :even | |
| addFirstChildCondition | back to summary |
|---|---|
| public void addFirstChildCondition() the CSS condition that element has pseudo-class :first-child | |
| addIDCondition | back to summary |
|---|---|
| public void addIDCondition(String id) the CSS condition #ID | |
| addLangCondition | back to summary |
|---|---|
| public void addLangCondition(String lang) the CSS condition :lang(Xx) | |
| addLastChildCondition | back to summary |
|---|---|
| public void addLastChildCondition() the CSS condition that element has pseudo-class :last-child | |
| addLinkCondition | back to summary |
|---|---|
| public void addLinkCondition() the CSS condition that element has pseudo-class :link | |
| addNthChildCondition | back to summary |
|---|---|
| public void addNthChildCondition(String number) the CSS condition that element has pseudo-class :nth-child(an+b) | |
| addOddChildCondition | back to summary |
|---|---|
| public void addOddChildCondition() the CSS condition that element has pseudo-class :odd | |
| addUnsupportedCondition | back to summary |
|---|---|
| public void addUnsupportedCondition() for unsupported or invalid CSS | |
| getAncestorSelector | back to summary |
|---|---|
| public Selector getAncestorSelector() | |
| getAppropriateSibling | back to summary |
|---|---|
| pack-priv Object getAppropriateSibling(Object e, TreeResolver treeRes) Gets the appropriateSibling attribute of the Selector object | |
| getAxis | back to summary |
|---|---|
| public int getAxis() get the axis that this selector should be evaluated on
| |
| getChainedSelector | back to summary |
|---|---|
| public Selector getChainedSelector() get the next selector in the chain, for matching against elements along the appropriate axis
| |
| getElementStylingOrder | back to summary |
|---|---|
| pack-priv static String getElementStylingOrder() Gets the elementStylingOrder attribute of the Selector class
| |
| getOrder | back to summary |
|---|---|
| pack-priv String getOrder() returns "a number in a large base" with specificity and specification order of selector
| |
| getPseudoElement | back to summary |
|---|---|
| public String getPseudoElement() Gets the pseudoElement attribute of the Selector object
| |
| getRuleset | back to summary |
|---|---|
| public Ruleset getRuleset() get the Ruleset that this Selector is part of
| |
| getSelectorID | back to summary |
|---|---|
| public int getSelectorID() | |
| getSpecificityB | back to summary |
|---|---|
| public int getSpecificityB() The correct specificity value for this selector and its sibling-axis selectors | |
| getSpecificityC | back to summary |
|---|---|
| public int getSpecificityC() The correct specificity value for this selector and its sibling-axis selectors | |
| getSpecificityD | back to summary |
|---|---|
| public int getSpecificityD() The correct specificity value for this selector and its sibling-axis selectors | |
| isPseudoClass | back to summary |
|---|---|
| public boolean isPseudoClass(int pc) query if a pseudoclass must apply for this selector
| |
| matches | back to summary |
|---|---|
| public boolean matches(Object e, AttributeResolver attRes, TreeResolver treeRes) Check if the given Element matches this selector. Note the parser should give all class | |
| matchesDynamic | back to summary |
|---|---|
| public boolean matchesDynamic(Object e, AttributeResolver attRes, TreeResolver treeRes) Check if the given Element matches this selector's dynamic properties. Note the parser should give all class | |
| setAncestorSelector | back to summary |
|---|---|
| public void setAncestorSelector(Selector ancestor) | |
| setAxis | back to summary |
|---|---|
| public void setAxis(int axis) | |
| setChainedSelector | back to summary |
|---|---|
| public void setChainedSelector(Selector selector) | |
| setName | back to summary |
|---|---|
| public void setName(String name) | |
| setNamespaceURI | back to summary |
|---|---|
| public void setNamespaceURI(String namespaceURI) | |
| setParent | back to summary |
|---|---|
| public void setParent(Ruleset ruleset) | |
| setPos | back to summary |
|---|---|
| public void setPos(int pos) | |
| setPseudoClass | back to summary |
|---|---|
| public void setPseudoClass(int pc) set which pseudoclasses must apply for this selector
| |
| setPseudoElement | back to summary |
|---|---|
| public void setPseudoElement(String pseudoElement) check if selector queries for dynamic properties
| |
| setSiblingSelector | back to summary |
|---|---|
| public void setSiblingSelector(Selector selector) | |
| setSpecificityB | back to summary |
|---|---|
| public void setSpecificityB(int b) | |
| setSpecificityC | back to summary |
|---|---|
| public void setSpecificityC(int c) | |
| setSpecificityD | back to summary |
|---|---|
| public void setSpecificityD(int d) | |
| toCSS | back to summary |
|---|---|
| public void toCSS(StringBuilder sb, Set<Selector> stopAt) Prints the selector chain to a StringBuilder, stopping when it hits a selector in the stopAt set. For example, given the selector 'body svg rect' and the stop set contains 'svg' then this will print 'rect' to the builder. This method is used to recreate CSS selectors to pass to SVG or other plugins. FIXME: Does not handle sibling selector. | |
| toString | back to summary |
|---|---|
| public String toString() Overrides java. For debugging, prints the entire selector chain. FIXME: Does not handle sibling selectors.
| |