Mercurial > archived > louis > epitech > zia-api
view include/IModule.hpp @ 41:7c8cd74023ce
Rework file layout, fix build, add README and SUPPORT
author | Louis Opter <kalessin@kalessin.fr> |
---|---|
date | Mon, 22 Mar 2010 02:08:24 +0100 |
parents | src/include/IModule.hpp@c0213ec8ab71 |
children | 1254fa6755a3 |
line wrap: on
line source
#ifndef __ZIA_API_IMODULE_HPP__ # define __ZIA_API_IMODULE_HPP__ # include <string> # include <vector> # include "http/ITransaction.hpp" # include "network/IEndPoint.hpp" # include "IConfig.hpp" namespace zia { namespace api { /** * @brief It provides basic method to identify the module and load a * module. */ class IModule { public: virtual ~IModule(void) { } /** * @brief Get the module name. * * @return The module name. */ virtual const std::string & getName(void) const = 0; /** * @brief Get module version. * * @return The module version. */ virtual const std::string & getVersion(void) const = 0; /** * @brief Get the list of module's hook. * * @return A vector of IHandler. * * @see IHandler */ virtual const std::vector<handler::IHandler *> & getHandlers(void) const = 0; /** * @brief Update module configuration. * * @param [in] conf The pointer on IConfig which hold the * configuration. * * @return True if the configuration was successfully loaded. False * otherwise and the module will be unloaded. * * @see IConfig */ virtual bool configure(IConfig* conf = NULL) = 0; }; extern "C" { /** * @brief Entry point of module. * * @return The module instance. * * @see IModule */ IModule * ziaGetModuleInstance(void); } }; }; #endif /* ! __ZIA_API_IMODULE_HPP__ */