QueryPath\DOMQuery::odd PHP Метод

odd() публичный Метод

Get the odd elements, so counter-intuitively 0, 2, 4, etc.
См. также: removeChildren()
См. также: parent()
См. также: parents()
См. также: next()
См. также: prev()
С версии: 2.1
Автор: eabrand
public odd ( )
    public function odd()
    {
        $found = new \SplObjectStorage();
        $odd = true;
        foreach ($this->matches as $m) {
            if ($odd && $m->nodeType == XML_ELEMENT_NODE) {
                $found->attach($m);
            }
            $odd = $odd ? false : true;
        }
        return $this->inst($found, null, $this->options);
    }