Gromacs  2024.4
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
List of all members | Public Member Functions | Protected Member Functions
gmx::CompositeHelpTopic< HelpText > Class Template Reference

#include <gromacs/onlinehelp/helptopic.h>

+ Inheritance diagram for gmx::CompositeHelpTopic< HelpText >:
+ Collaboration diagram for gmx::CompositeHelpTopic< HelpText >:

Description

template<class HelpText>
class gmx::CompositeHelpTopic< HelpText >

Template for simple implementation of AbstractCompositeHelpTopic.

Template Parameters
HelpTextStruct that defines the data for the topic.

Used similarly to SimpleHelpTopic. HelpText should satisfy the same criteria as for SimpleHelpTopic.

See Also
SimpleHelpTopic

Public Member Functions

const char * name () const override
 Returns the name of the topic. More...
 
const char * title () const override
 Returns a title for the topic. More...
 
- Public Member Functions inherited from gmx::AbstractCompositeHelpTopic
bool hasSubTopics () const override
 Returns whether the topic has any subtopics.
 
const IHelpTopicfindSubTopic (const char *name) const override
 Finds a subtopic by name. More...
 
void writeHelp (const HelpWriterContext &context) const override
 Prints the help text for this topic. More...
 
void addSubTopic (HelpTopicPointer topic)
 Adds a given topic as a subtopic of this topic. More...
 
template<class Topic >
void registerSubTopic ()
 Registers a subtopic of a certain type to this topic. More...
 

Protected Member Functions

std::string helpText () const override
 Returns the help text for this topic. More...
 
- Protected Member Functions inherited from gmx::AbstractCompositeHelpTopic
bool writeSubTopicList (const HelpWriterContext &context, const std::string &title) const
 Writes the list of subtopics. More...
 

Member Function Documentation

template<class HelpText>
std::string gmx::CompositeHelpTopic< HelpText >::helpText ( ) const
inlineoverrideprotectedvirtual

Returns the help text for this topic.

writeHelp() calls this method to obtain the actual text to format for the topic. Markup substitution etc. is done automatically by writeHelp().

Implements gmx::AbstractCompositeHelpTopic.

template<class HelpText>
const char* gmx::CompositeHelpTopic< HelpText >::name ( ) const
inlineoverridevirtual

Returns the name of the topic.

This should be a single lowercase word, used to identify the topic. It is not used for the root of the help topic tree.

Implements gmx::AbstractCompositeHelpTopic.

template<class HelpText>
const char* gmx::CompositeHelpTopic< HelpText >::title ( ) const
inlineoverridevirtual

Returns a title for the topic.

May return NULL, in which case the topic is omitted from normal subtopic lists and no title is printed by the methods provided in helptopic.h.

Implements gmx::AbstractCompositeHelpTopic.


The documentation for this class was generated from the following file: