]> Creatis software - creaMaracasVisu.git/blob - lib/maracasVisuLib/src/interface/wxWindows/widgets/creaButtonContainer/model/containerSettings.h
creaButtonContainer: doxygen 90%
[creaMaracasVisu.git] / lib / maracasVisuLib / src / interface / wxWindows / widgets / creaButtonContainer / model / containerSettings.h
1 /*!
2  * @file containerSettings.h
3  * @brief Contains the ContainerSettings class
4  * @author Diego CACERES (diego.caceres[AT]creatis.insa-lyon.fr)
5  * @date  2011-05-19
6  */
7
8 #ifndef BUTTONGROUPSETTINGS_H_
9 #define BUTTONGROUPSETTINGS_H_
10
11 #include <list>
12 #include <map>
13 #include <iostream>
14 #include "system.h"
15 #include "functor.h"
16
17 /*!     @namespace <creaButtonContainer>
18  *      @brief Contains the creaButtonContainer library included in creaMaracasVisu.
19  */
20 namespace creaButtonContainer
21 {
22         /*! @namespace <creaButtonContainer::model>
23          *      @brief Contains the implementation of the model in creaButtonContainer library.
24          *      @see <a href="http://en.wikipedia.org/wiki/Model-view-controller">MVC Software Architecture</a>
25          */
26         namespace model
27         {
28                 /*! @class ContainerSettings containerSettings.h "containerSettings.h"
29                  *      @brief This class contains the settings of the button container.
30                  */
31                 class ContainerSettings
32                 {
33                         public:
34                                 // ----------------------------------------------------------------------------------
35                                 /*! @fn ContainerSettings::ContainerSettings( )
36                                  *      @brief This is the constructor.
37                                  */
38                                 ContainerSettings( );
39                                 // ----------------------------------------------------------------------------------
40                                 /*! @fn virtual ContainerSettings::~ContainerSettings( )
41                                  *      @brief This is the destructor.
42                                  */
43                                 virtual
44                                 ~ContainerSettings( );
45                                 // ----------------------------------------------------------------------------------
46                                 /*! @fn ButtonGroupMap ContainerSettings::GetButtonGroupContainer( )
47                                  *      @brief This function returns a container of buttons ordered by group.
48                                  *      @return ButtonGroupMap A container with buttons
49                                  */
50                                 ButtonGroupMap
51                                 GetButtonGroupContainer( );
52                                 // ----------------------------------------------------------------------------------
53                                 /*! @fn KeyMapList ContainerSettings::GetGroupNameList( )
54                                  *      @brief This function returns a container with the name of the groups.
55                                  *      @return KeyMapList A list with the name of the button groups.
56                                  */
57                                 KeyMapList
58                                 GetGroupNameList( );
59                                 // ----------------------------------------------------------------------------------
60                                 /*! void ContainerSettings::SetButtonGroupContainer( ButtonGroupMap m_ButtonGroupContainer )
61                                  *      @brief This function allows to create the ButtonGroupContainer.
62                                  *      @param bgContainer The ButtonGroupMap with all buttons.
63                                  */
64                                 void
65                                 SetButtonGroupContainer( ButtonGroupMap bgContainer );
66                                 // ----------------------------------------------------------------------------------
67                                 /*! void ContainerSettings::SetGroupNameList( KeyMapList gNameList )
68                                  * @brief This function sets a container with the name of the groups.
69                                  * @param gNameList the KeyMapList with all groupNames.
70                                  */
71                                 void
72                                 SetGroupNameList( KeyMapList gNameList );
73                                 // ----------------------------------------------------------------------------------
74                                 /*!
75                                  * @fn ContainerSettings::AddButton( const std::string & groupName, const std::string buttonName,
76                                  const std::string iconpath, const std::string buttonDescription,
77                                  FunctionEventType event )
78                                  * @brief This function adds a new button to the container.
79                                  * @param groupName The name of the group of buttons.
80                                  * @param buttonName The ID of the button.
81                                  * @param iconpath The path of the button icon.
82                                  * @param buttonDescription The description of the button.
83                                  * @param event The event associated to the button.
84                                  * @see class Functor, ConcreteFunctor for add an event for a button.
85                                  * @exception std::bad_alloc
86                                  */
87                                 void
88                                 AddButton( const std::string & groupName, const std::string buttonName,
89                                     const std::string iconpath, const std::string buttonDescription,
90                                     FunctionEventType event );
91                                 // ----------------------------------------------------------------------------------
92
93                         private:
94                                 ButtonGroupMap m_ButtonGroupContainer; //! <std::map< std::string, ButtonList > View pointer.
95                                 KeyMapList m_GroupNameList; //! <ButtonContainerPanel View pointer.
96                 };
97         }
98 }
99
100 #endif /* BUTTONGROUPSETTINGS_H_ */