usingnamespace css::uno; usingnamespace css::xml::dom; usingnamespace css::xml::dom::events; namespace DOM { class CElementListImpl; }
namespace DOM
{ class WeakEventListener : public ::cppu::WeakImplHelper<css::xml::dom::events::XEventListener>
{ private:
unotools::WeakReference<DOM::CElementListImpl> mxOwner;
void CElementListImpl::buildlist(xmlNodePtr pNode, bool start)
{ // bail out if no rebuild is needed if (start) { if (!m_bRebuild)
{ return;
} else {
m_nodevector.clear();
m_bRebuild = false; // don't rebuild until tree is mutated
}
}
while (pNode != nullptr )
{ if (pNode->type == XML_ELEMENT_NODE &&
(strcmp(reinterpret_cast<charconst *>(pNode->name), reinterpret_cast<char*>(m_pName.get())) == 0))
{ if (!m_pURI) {
m_nodevector.push_back(pNode);
} else { if (pNode->ns != nullptr && (0 ==
strcmp(reinterpret_cast<charconst *>(pNode->ns->href), reinterpret_cast<char*>(m_pURI.get()))))
{
m_nodevector.push_back(pNode);
}
}
} if (pNode->children != nullptr) buildlist(pNode->children, false);
if (!start) pNode = pNode->next; elsebreak; // fold back
}
}
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.