Element.matches

bool matches(const(char)[] selector)

Does this element match a css selector?

bool matches(Selector selector)

ditto