Loading...
Searching...
No Matches
HelpManager.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/qt/widgets/help/HelpManager.h
22
23 \brief A singleton that contains a pointer to a help manager implementation.
24*/
25
26#ifndef __TERRALIB_QT_WIDGETS_HELP_INTERNAL_HELPMANAGER_H
27#define __TERRALIB_QT_WIDGETS_HELP_INTERNAL_HELPMANAGER_H
28
29//TerraLib
30#include "../../../common/Singleton.h"
31#include "../Config.h"
32
33//Qt
34#include <QtCore/QString>
35
36namespace te
37{
38 namespace qt
39 {
40 namespace widgets
41 {
42//Forward declaration
43 class HelpManagerImpl;
44
45 /*!
46 \class HelpManager
47
48 \brief Facade for a te::qt::widgets::HelpManagerImpl object.
49
50 This class holds a pointer to a te::qt::widgets::HelpManagerImpl object. Before use it, the client MUST set the pointer to a valid HelpManagerImpl object.
51 If it was not done, nothing will happen when calling methods neither exceptions will be raised.
52 */
54 {
56
57 public:
58
59 /*!
60 \brief Updates the HelpManagerImpl pointer.
61
62 \note This object does NOT take the ownership of the pointer. The caller must manage the pointers. This means that the previous pointer will NOT be deleted. This method, only reassigns the pointer.
63 \note The client must ensure that the pointer of the HelpManagerImpl will be valid until the application has finished. If, for some reason, the client of this class needs to delete the pointer, it MUST
64 use this method to set NULL or 0 to the HelpManagerImpl to be used (a null pointer means no operation to be executed), otherwise it can take to an unhandled exception of invalid pointer.
65 */
67
68 /*! \brief Returns the pointer to the HelpManagerImpl object being used. */
70
71 /** @name Facade methods
72 * Facade for the te::qt::widgets::HelpManagerImpl API.
73 *
74 * \note See the te::qt::widgets::HelpManagerImpl API for detais on how to call methods with the right argument's syntax.
75 */
76 //@{
77
78 /*!
79 \brief Opens the help on the selected page.
80
81 \param htmRef Reference to some page on the help collection.
82
83 \param nSpace
84 */
85 void showHelp(const QString& htmRef, const QString& nSpace = "");
86
87 /*!
88 \brief Appends a project of help documentation to the existing collection.
89
90 \param docRef Reference to the help project to be appended.
91 */
92 void appendDoc(const QString& docRef);
93
94 //@}
95
96 protected:
97
98 /*! \brief Protected constructor. Can not be called by clients. */
100
101 HelpManagerImpl* m_impl; //!< Pointer to HelpManagerImpl to be used.
102 };
103
104 } // end namespace widgets
105 } // end namespace qt
106} // end namespace te
107
108#endif //__TERRALIB_QT_WIDGETS_HELP_INTERNAL_HELPMANAGER_H
109
Template support for singleton pattern.
Definition: Singleton.h:101
An interface for help managers implementations.
Facade for a te::qt::widgets::HelpManagerImpl object.
Definition: HelpManager.h:54
HelpManagerImpl * getImpl() const
Returns the pointer to the HelpManagerImpl object being used.
HelpManager()
Protected constructor. Can not be called by clients.
HelpManagerImpl * m_impl
Pointer to HelpManagerImpl to be used.
Definition: HelpManager.h:101
void showHelp(const QString &htmRef, const QString &nSpace="")
Opens the help on the selected page.
void appendDoc(const QString &docRef)
Appends a project of help documentation to the existing collection.
void setImpl(HelpManagerImpl *impl)
Updates the HelpManagerImpl pointer.
TerraLib.
#define TEQTWIDGETSEXPORT
You can use this macro in order to export/import classes and functions from this module.
Definition: Config.h:63