Ejemplo n.º 1
0
/*! Returns the definition identified by the given \a definitionName that is valid for the organizer items whose type is the given \a organizeritemType in this store, or a default-constructed QOrganizerItemDetailDefinition if no such definition exists
  \since 1.1
*/
QOrganizerItemDetailDefinition QOrganizerManager::detailDefinition(const QString& definitionName, const QString& organizeritemType) const
{
    QOrganizerManagerSyncOpErrorHolder h(this);
    if (!supportedItemTypes().contains(organizeritemType)) {
        h.error = QOrganizerManager::InvalidItemTypeError;
        return QOrganizerItemDetailDefinition();
    }

    return d->m_engine->detailDefinition(definitionName, organizeritemType, &h.error);
}
Ejemplo n.º 2
0
/*! Returns the definition identified by the given \a definitionName that is valid for the organizer items whose type is the given \a organizeritemType in this store, or a default-constructed QOrganizerItemDetailDefinition if no such definition exists */
QOrganizerItemDetailDefinition QOrganizerManager::detailDefinition(const QString& definitionName, const QString& organizeritemType) const
{
    d->m_errorMap.clear();
    if (!supportedItemTypes().contains(organizeritemType)) {
        d->m_error = QOrganizerManager::InvalidItemTypeError;
        return QOrganizerItemDetailDefinition();
    }

    d->m_error = QOrganizerManager::NoError;
    return d->m_engine->detailDefinition(definitionName, organizeritemType, &d->m_error);
}