public class NotSelector extends java.lang.Object implements Selector
Equivalent to :not()
selector in CSS. Its specificity is the same as its wrapped selector.
SpecificityHelper
Constructor and Description |
---|
NotSelector(Selector selector)
Creates a not selector.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object obj) |
boolean |
fit(Element element)
Checks whether or not the given element fits this selector.
|
int |
getSpecificity()
Gets the selector specificity.
|
int |
hashCode() |
public NotSelector(Selector selector)
selector
- the wrapped selector.public boolean fit(Element element)
Selector
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int getSpecificity()
Selector
See CSS for more information about calculating a selector's specificity.
getSpecificity
in interface Selector
public int hashCode()
hashCode
in class java.lang.Object