AbstractFinder.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 Lesser 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 Lesser General Public License for more details.
14 
15  You should have received a copy of the GNU Lesser 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/AbstractFinder.h
22 
23  \brief The AbstractFinder class allows applications to extend how PluginManager can search for plugins.
24 */
25 
26 #ifndef __TERRALIB_PLUGIN_INTERNAL_ABSTRACTFINDER_H
27 #define __TERRALIB_PLUGIN_INTERNAL_ABSTRACTFINDER_H
28 
29 // TerraLib
30 #include "Config.h"
31 #include "Exception.h"
32 
33 // Boost
34 #include <boost/noncopyable.hpp>
35 #include <boost/ptr_container/ptr_vector.hpp>
36 
37 namespace te
38 {
39  namespace plugin
40  {
41 // Forwar declaration
42  struct PluginInfo;
43 
44  /*!
45  \class AbstractFinder
46 
47  \brief The AbstractFinder class allows applications to extend how PluginManager can search for plugins.
48 
49  Subclasses can search for plugins installed in any place.
50  There is a default finder named DefaultFinder that
51  seraches for plugins in some common places.
52 
53  \ingroup plugin
54 
55  \sa PluginManager, PluginInfo, DefaultFinder
56  */
57  class TEPLUGINEXPORT AbstractFinder : public boost::noncopyable
58  {
59  public:
60 
61  /*! \brief Constructor. */
63 
64  /*! \brief Virtual destructor. */
65  virtual ~AbstractFinder();
66 
67  /*!
68  \brief This method searches for installed plugins and output the plugins information in the PluginInfo vector.
69 
70  \param plugins A vector to output all information about found plugins.
71 
72  \exception Exception This method may throw an exception with something goes wrong during the search.
73  */
74  virtual void getPlugins(boost::ptr_vector<PluginInfo>& plugins) = 0;
75  };
76 
77  } // end namespace plugin
78 } // end namespace te
79 
80 #endif // __TERRALIB_PLUGIN_INTERNAL_ABSTRACTFINDER_H
81 
The AbstractFinder class allows applications to extend how PluginManager can search for plugins...
Configuration flags for the TerraLib Plugin module.
An exception class for the Plugin module.
URI C++ Library.
#define TEPLUGINEXPORT
You can use this macro in order to export/import classes and functions from this module.
Definition: Config.h:120
The basic information about a plugin.
Definition: PluginInfo.h:61