NepomukDaemons
Nepomuk::OntologyManagerModel Class Reference
Filter model to manage NRL ontologies. More...
#include <ontologymanagermodel.h>

Public Member Functions | |
QUrl | findOntologyContext (const QUrl &uri) |
OntologyManagerModel (Soprano::Model *parentModel=0, QObject *parent=0) | |
QDateTime | ontoModificationDate (const QUrl &uri) |
bool | removeOntology (const QUrl &ns) |
void | setParentModel (Soprano::Model *parentModel) |
bool | updateOntology (Soprano::StatementIterator data, const QUrl &ns=QUrl()) |
~OntologyManagerModel () |
Detailed Description
Filter model to manage NRL ontologies.Can be used to manage ontologies stored in a model. The ontologies are stored in NRL graphs.
Definition at line 35 of file ontologymanagermodel.h.
Constructor & Destructor Documentation
Nepomuk::OntologyManagerModel::OntologyManagerModel | ( | Soprano::Model * | parentModel = 0 , |
|
QObject * | parent = 0 | |||
) |
Nepomuk::OntologyManagerModel::~OntologyManagerModel | ( | ) |
Member Function Documentation
Tries to find the ontology uri
in the local Nepomuk store.
- Returns:
- The context (named graph) storing the ontology's statements or an invalid URI if the ontology could not be found.
Definition at line 428 of file ontologymanagermodel.cpp.
Determine the modification time of a stored ontology.
The modification time of an ontology is the time it was stored into the model.
- Parameters:
-
uri The namespace of the ontology.
- Returns:
- The modification time of the ontology identified by
uri
or an invalid QDateTime if the ontology was not found.
Definition at line 406 of file ontologymanagermodel.cpp.
bool Nepomuk::OntologyManagerModel::removeOntology | ( | const QUrl & | ns | ) |
Remove an ontology from the model.
- Parameters:
-
ns The namespace of the ontology.
- Returns:
true
if the ontology was found and successfully removed.false
in case the ontology was not found or an error occurred.
Definition at line 387 of file ontologymanagermodel.cpp.
void Nepomuk::OntologyManagerModel::setParentModel | ( | Soprano::Model * | parentModel | ) |
Reimplemented from FilterModel.
The API is not affected.
Definition at line 271 of file ontologymanagermodel.cpp.
bool Nepomuk::OntologyManagerModel::updateOntology | ( | Soprano::StatementIterator | data, | |
const QUrl & | ns = QUrl() | |||
) |
Update an ontology.
- Parameters:
-
data The actual statements defining the ontology. These statements have to either already define the proper NRL graphs or not define graphs at all. In the latter case the graphs will be created. ns The namespace of the ontology. If this is left invalid it will be determined from the data.
- Returns:
true
if the data was valid and the ontology was successfully updated. otherwise.
Definition at line 277 of file ontologymanagermodel.cpp.
The documentation for this class was generated from the following files: