1 // Object Viewer Qt - MMORPG Framework <http://dev.ryzom.com/projects/nel/>
2 // Copyright (C) 2010-2011 Dzmitry KAMIAHIN (dnk-88) <dnk-88@tut.by>
4 // This source file has been modified by the following contributors:
5 // Copyright (C) 2010 Winch Gate Property Limited
7 // This program is free software: you can redistribute it and/or modify
8 // it under the terms of the GNU Affero General Public License as
9 // published by the Free Software Foundation, either version 3 of the
10 // License, or (at your option) any later version.
12 // This program is distributed in the hope that it will be useful,
13 // but WITHOUT ANY WARRANTY; without even the implied warranty of
14 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 // GNU Affero General Public License for more details.
17 // You should have received a copy of the GNU Affero General Public License
18 // along with this program. If not, see <http://www.gnu.org/licenses/>.
23 #include <QtCore/QString>
25 namespace ExtensionSystem
32 @details The plugin goes through several steps while being loaded.
33 The state gives a hint on what went wrong in case of an error.
51 @interface IPluginSpec
52 @brief Interface for plugin spec contains the information of the plugins and
53 information about the plugin's current state.
54 @details The plugin spec is also filled with more information as the plugin
55 goes through its loading process (see State).
56 If an error occurs, the plugin spec is the place to look for the error details.
61 virtual ~IPluginSpec() {}
63 virtual QString
name() const = 0;
64 virtual QString
version() const = 0;
65 virtual QString
vendor() const = 0;
66 virtual QString
description() const = 0;
68 virtual QString
location() const = 0;
69 virtual QString
filePath() const = 0;
70 virtual QString
fileName() const = 0;
72 virtual IPlugin
*plugin() const = 0;
75 virtual int state() const = 0;
76 virtual bool hasError() const = 0;
77 virtual QString
errorString() const = 0;
79 /// Enables/disables load this plugin after restart the program
80 virtual void setEnabled(bool enabled
) = 0;
81 virtual bool isEnabled() const = 0;
84 } // namespace ExtensionSystem
86 #endif // IPLUGINSPEC_H