protected function isValid($item)
    {
        if ((!$item instanceof stdClass)
            || !isset($item->type)
            || !isset($item->modifiers)
        ) {
            return false;
        }

        if ($this->doctypeValidationEnabled) {
            if (!isset($item->content)
                && (! $this->view->plugin('doctype')->isHtml5()
                || (! $this->view->plugin('doctype')->isHtml5() && $item->type !== 'charset'))
            ) {
                return false;
            }

            // <meta itemprop= ... /> is only supported with doctype html
            if (! $this->view->plugin('doctype')->isHtml5()
                && $item->type === 'itemprop'
            ) {
                return false;
            }

            // <meta property= ... /> is only supported with doctype RDFa
            if (!$this->view->plugin('doctype')->isRdfa()
                && $item->type === 'property'
            ) {
                return false;
            }
        }

        return true;
    }