Beispiel #1
0
void XsdSchema::addAnonymousType(const SchemaType::Ptr &type)
{
    const QWriteLocker locker(&m_lock);

    // search for not used anonymous type name
    QXmlName typeName = type->name(m_namePool);
    while (m_anonymousTypes.contains(typeName)) {
        typeName = m_namePool->allocateQName(QString(), QLatin1String("merged_") + m_namePool->stringForLocalName(typeName.localName()), QString());
    }

    m_anonymousTypes.insert(typeName, type);
}
Beispiel #2
0
void XsdSchema::addType(const SchemaType::Ptr &type)
{
    const QWriteLocker locker(&m_lock);

    m_types.insert(type->name(m_namePool), type);
}