NepomukDaemons
nepomukcore.h
Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019 #ifndef _NEPOMUK_CORE_H_
00020 #define _NEPOMUK_CORE_H_
00021
00022 #include <Soprano/Server/ServerCore>
00023 #include "repository.h"
00024
00025 #include <QtCore/QStringList>
00026
00027 namespace Nepomuk {
00028
00029 class Core : public Soprano::Server::ServerCore
00030 {
00031 Q_OBJECT
00032
00033 public:
00034 Core( QObject* parent = 0 );
00035 ~Core();
00036
00040 Soprano::Model* model( const QString& name );
00041
00045 void init();
00046
00052 bool initialized() const;
00053
00054 public Q_SLOTS:
00055 void optimize( const QString& repoName );
00056
00057 Q_SIGNALS:
00058 void initializationDone( bool success );
00059
00060 private Q_SLOTS:
00061 void slotRepositoryOpened( Repository* repo, bool success );
00062
00063 private:
00067 Soprano::Model* createModel( const QList<Soprano::BackendSetting>& settings );
00068 void createRepository( const QString& name );
00069
00070 RepositoryMap m_repositories;
00071
00072
00073 QStringList m_openingRepositories;
00074 QString m_currentRepoName;
00075
00076
00077 bool m_failedToOpenRepository;
00078 };
00079 }
00080
00081 #endif