From 69625912b822f5e7630648d76af2408f013f23ba Mon Sep 17 00:00:00 2001 From: Mikaƫl Capelle Date: Mon, 28 Sep 2020 22:56:12 +0200 Subject: Add a method to retrieve the localized names of the implemented plugin interfaces. --- src/plugincontainer.h | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) (limited to 'src/plugincontainer.h') diff --git a/src/plugincontainer.h b/src/plugincontainer.h index d405198a..7eb59a0f 100644 --- a/src/plugincontainer.h +++ b/src/plugincontainer.h @@ -48,6 +48,16 @@ private: public: + /** + * @brief Retrieved the (localized) names of interfaces implemented by the given + * plugin. + * + * @param plugin The plugin to retrieve interface for. + * + * @return the (localized) names of interfaces implemented by this plugin. + */ + QStringList implementedInterfaces(const MOBase::IPlugin *plugin) const; + PluginContainer(OrganizerCore *organizer); virtual ~PluginContainer(); @@ -56,16 +66,38 @@ public: void loadPlugins(); void unloadPlugins(); + /** + * @brief Find the game plugin corresponding to the given name. + * + * @param name The name of the game to find a plugin for (as returned by + * IPluginGame::gameName()). + * + * @return the game plugin for the given name, or a null pointer if no + * plugin exists for this game. + */ MOBase::IPluginGame *managedGame(const QString &name) const; + /** + * @brief Retrieve the list of plugins of the given type. + * + * @return the list of plugins of the specified type. + * + * @tparam T The type of plugin to retrieve. + */ template const std::vector &plugins() const { typename boost::fusion::result_of::at_key::type temp = boost::fusion::at_key(m_Plugins); return temp; } + /** + * @return the preview generator. + */ const PreviewGenerator &previewGenerator() const; + /** + * @return the list of plugin file names, including proxied plugins. + */ QStringList pluginFileNames() const; public: // IPluginDiagnose interface -- cgit v1.3.1