plugin.h
Go to the documentation of this file.
1 /* Copyright (C) 2008 National Institute For Space Research (INPE) - Brazil.
2 
3  This file is part of the TerraLib - a Framework for building GIS enabled applications.
4 
5  TerraLib is free software: you can redistribute it and/or modify
6  it under the terms of the GNU General Public License as published by
7  the Free Software Foundation, either version 3 of the License,
8  or (at your option) any later version.
9 
10  TerraLib 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 General Public License
16  along with TerraLib. See COPYING. If not, write to
17  TerraLib Team at <terralib-team@terralib.org>.
18  */
19 
20 /*!
21  \file terralib/plugin.h
22 
23  \brief This file contains include headers for the Plugin module of TerraLib.
24 */
25 
26 #ifndef __TERRALIB_INTERNAL_PLUGIN_H
27 #define __TERRALIB_INTERNAL_PLUGIN_H
28 
29 // TerraLib
30 #include "plugin/Config.h"
31 #include "plugin/CppPlugin.h"
32 #include "plugin/Plugin.h"
33 #include "plugin/PluginInfo.h"
34 #include "plugin/PluginManager.h"
35 #include "plugin/Utils.h"
36 
37 /*!
38  \defgroup plugin Plugin
39 
40  \brief The plugin module provides support for the startup and shutdown of modules loaded at run time.
41 
42  A plugin (also called plug-in, addin, add-in, addon, add-on, snap-in, extension or suplement) is a computer program
43  that interacts with a host application adding new capabilities/functionalities to it.
44  Plugins can also be used to plug new functionalities in an extensible library/platform.
45 
46  The TerraLib Plugin module comes with a basic framework for those who want to create plugins in the TerraLib Platform.
47  Instead of having a framework target to a specific application like TerraView or SISMADEN, TerraLib Plugin framework just handle
48  the extensions (plugins) and is capable of loading then dynamically.
49 
50  It provides the basic foundation to simplify the burden of dealing with plugins: dependencies, configuration and startup/shutdown actions.
51  Besides that in TerraLib 5 a plugin can be built using any language that has a support in the language binding modules.
52  For instance you can create plugins in Haskell, Lua, PHP, Java, Python, C and C++.
53 
54  Note that in TerraLib any plugin may have access to all other system parts. You can put no restrictions on it,
55  so you can easily use all TerraLib API without worry about doing trickies.
56  Also you have to define the API of your application. Each application plugin will be dependent on its application API.
57  If you have parts of your plugin that can be shared between applications, you should isolate that part and make a plugin with a dependency for it.
58 
59  <ul>
60  <li>a plugin must provide a root object derived from an abstract plugin class that implements a couple of methods (startup and shutdown);</li>
61  <li>a plugin can have initialization parameters;</li>
62  <li>the plugin framework provides a basic model for the information needed by a plugin;</li>
63  <li>Although a given plugin doesn't have a link dependency of another plugin it can expouse this dependency in its configuration;</li>
64  <li>It provides a nice way to control the existence of debug/release versions of the plugins.</li>
65  </ul>
66 
67  The main classes/concepts in this module are listed here. The namespace associated to the Plugin module is te::plugin.
68  To know more about it, see the te::plugin namespace documentation.
69 */
70 
71 namespace te
72 {
73  /*! \brief Namespace for the Plugin module of TerraLib. */
74  namespace plugin
75  {
76  } // end namespace plugin
77 } // end namespace te
78 
79 #endif // __TERRALIB_INTERNAL_PLUGIN_H
80 
A base class for plugin types.
Utility functions for dealing with plugins.
Configuration flags for the TerraLib Plugin module.
An abstract interface for Plugins written in C++.
URI C++ Library.
A singleton for managing plugins.
The basic information about a plugin.