Fix no newlines warnings. Patch by Peter Oberndorfer
[kdevelopdvcssupport.git] / shell / core.h
blob4c260bd64ca636db8a367012a1bd18c6f3b0124e
1 /***************************************************************************
2 * Copyright 2007 Alexander Dymo <adymo@kdevelop.org> *
3 * Copyright 2007 Kris Wong <kris.p.wong@gmail.com> *
4 * *
5 * This program is free software; you can redistribute it and/or modify *
6 * it under the terms of the GNU Library General Public License as *
7 * published by the Free Software Foundation; either version 2 of the *
8 * License, or (at your option) any later version. *
9 * *
10 * This program is distributed in the hope that it will be useful, *
11 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
13 * GNU General Public License for more details. *
14 * *
15 * You should have received a copy of the GNU Library General Public *
16 * License along with this program; if not, write to the *
17 * Free Software Foundation, Inc., *
18 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. *
19 ***************************************************************************/
20 #ifndef CORE_H
21 #define CORE_H
23 #include "shellexport.h"
24 #include <interfaces/icore.h>
26 namespace KDevelop {
28 class UiController;
29 class PluginController;
30 class ProjectController;
31 class LanguageController;
32 class PartController;
33 class DocumentController;
34 class RunController;
35 class SessionController;
37 class KDEVPLATFORMSHELL_EXPORT Core: public ICore {
38 public:
39 enum Setup { Default=0, NoUi=1 };
41 static void initialize(Setup mode=Default);
42 static Core *self();
44 virtual ~Core();
46 /** @copydoc ICore::uiController() */
47 virtual IUiController *uiController();
49 /** @copydoc ICore::pluginController() */
50 virtual IPluginController *pluginController();
52 /** @copydoc ICore::projectController() */
53 virtual IProjectController *projectController();
55 /** @copydoc ICore::languageController() */
56 virtual ILanguageController *languageController();
58 /** @copydoc ICore::partManager() */
59 virtual KParts::PartManager *partManager();
61 /** @copydoc ICore::documentController() */
62 virtual IDocumentController *documentController();
64 /** @copydoc ICore::runController() */
65 virtual IRunController *runController();
67 /** @copydoc ICore::activeSession() */
68 virtual ISession *activeSession();
70 virtual KComponentData componentData() const;
72 /// The following methods may only be used within the shell.
74 /** @return ui controller */
75 UiController *uiControllerInternal();
77 /** @return plugin controller */
78 PluginController *pluginControllerInternal();
80 /** @return project controller */
81 ProjectController *projectControllerInternal();
83 /** @return language controller */
84 LanguageController *languageControllerInternal();
86 /** @return part manager */
87 PartController *partManagerInternal();
89 /** @return document controller */
90 DocumentController *documentControllerInternal();
92 /** @return run controller */
93 RunController *runControllerInternal();
95 /**
96 * @return session controller
97 * @internal
99 SessionController *sessionController();
101 void cleanup();
103 Core::Setup setupFlags() const;
105 private:
106 Core(QObject *parent = 0);
107 static Core *m_self;
108 struct CorePrivate *d;
113 #endif