GlsMenu
|
#include <gls_menu_data_group.h>
Public Member Functions | |
GlsMenuHandlerGroup_T (const std::string &name, GlsMenuDictionary &dataDict, GlsMenuAction::HandlerCont_t &actionHandlers, bool uniqueKeys=true) | |
virtual | ~GlsMenuHandlerGroup_T () |
T * | Item (const std::string &name) const |
virtual std::istream & | ReadValue (std::istream &instr) |
const GlsMenuDictionary & | Attributes () const |
virtual std::ostream & | WriteValue (std::ostream &outstr) |
virtual void | Inc (long amount=1) |
Protected Member Functions | |
virtual GlsMenuData * | CreateDataItem (const std::string &name) const |
Protected Attributes | |
GlsMenuDictionary & | _dataDict |
Data dictionary to pass to items created in the group. This is the dictionary used to evaluate menu data variables. More... | |
GlsMenuAction::HandlerCont_t & | _handlers |
bool | _uniqueKeys |
Specifies whether attribute names should be unique or not. More... | |
GlsMenuDictionary | _attr |
The dictionary of attributes for the group attribute. More... | |
The GlsMenuHandlerGroup_T is the base class for groups of items that can be created dynamically at ReadValue time. If the item does NOT already exist, it will be created and added to the attribute group dictionary, otherwise its value will be updated. The class supports either unique or multiple keys. Items must accept 3 parameters,
Definition at line 262 of file gls_menu_data_group.h.
|
inline |
Class constructor.
name | the name of the group of data items. |
dataDict | the menu data dictionary used to evaluate menu data variables |
actionHandlers | These are handlers for menu actions passed in by the creator. These are considered local to the menu set. |
uniqueKeys | whether or not unique keys are required in the group. |
Definition at line 278 of file gls_menu_data_group.h.
|
inlinevirtual |
Class destructor.
Definition at line 293 of file gls_menu_data_group.h.
|
inlineinherited |
Read attribute dictionary from an input stream.
instr | input stream to read value from. |
Definition at line 80 of file gls_menu_data_group.h.
References GlsMenuDataGroup::_attr.
Referenced by GlsMFDMenu_T< MenuItem_t, Submenu_t, PageId_t >::ReadValue().
|
inlineprotectedvirtual |
Create a new instance of our particular data item type. In this case, it is an menu item that will accept action handlers, since it or one of its components will handle actions.
name | name of the data item. |
Implements GlsMenuDynDataGroup.
Definition at line 331 of file gls_menu_data_group.h.
|
virtualinherited |
Increment the data item. Derived classes must override this as the default is a no-op.
Reimplemented in GlsMenuDiscrete_T< T >.
Referenced by GlsMenuSet_T< MenuType_t, DataFactory_t >::IncData().
|
inline |
Gain access to a particular meta-data item within the group.
name | name of the meta-data item. |
Definition at line 305 of file gls_menu_data_group.h.
Referenced by GlsMenu_T< MenuItem_t, GlsMFD::MenuItemId_t >::Item(), GlsMenu_T< MenuItem_t, GlsMFD::MenuItemId_t >::SelectItem(), and GlsMenuSet_T< MenuType_t, DataFactory_t >::Show().
|
virtualinherited |
Read attribute dictionary from an input stream.
instr | input stream to read value from. |
Reimplemented from GlsMenuDataGroup.
|
virtualinherited |
Read attribute dictionary from an input stream.
instr | input stream to read value from. |
|
protectedinherited |
The dictionary of attributes for the group attribute.
Definition at line 103 of file gls_menu_data_group.h.
Referenced by GlsMenuDataGroup::Attributes(), GlsMenu_T< MenuItem_t, GlsMFD::MenuItemId_t >::GlsMenu_T(), GlsMFDMenu_T< MenuItem_t, Submenu_t, PageId_t >::GlsMFDMenu_T(), GlsMFDSubmenu_T< MenuItemId_t >::GlsMFDSubmenu_T(), GlsMenuDataGroup_T< T >::Item(), GlsMenuHandlerGroup_T< Menu_t >::Item(), GlsMFDMenu_T< MenuItem_t, Submenu_t, PageId_t >::ReadValue(), and GlsMenuItem_T< State_t >::State().
|
protected |
Data dictionary to pass to items created in the group. This is the dictionary used to evaluate menu data variables.
Definition at line 314 of file gls_menu_data_group.h.
|
protected |
Definition at line 318 of file gls_menu_data_group.h.
|
protectedinherited |
Specifies whether attribute names should be unique or not.
Definition at line 157 of file gls_menu_data_group.h.