pQuery\DomNode::filter_nlastype PHP Method

filter_nlastype() protected method

Checks if node matches css query filter ":nth-last-of-type(n)"
See also: match()
protected filter_nlastype ( string $n ) : boolean
$n string 1-based index
return boolean
    protected function filter_nlastype($n)
    {
        if ($this->parent === null) {
            return false;
        } else {
            return count($this->parent->getChildrenByTag($this->tag, 'total', false)) - $this->typeIndex() === (int) $n;
        }
    }
DomNode