Makes a help message, using the currently configured formatter Will only do one subcommand at a time
| 5970 | /// Makes a help message, using the currently configured formatter |
| 5971 | /// Will only do one subcommand at a time |
| 5972 | std::string help(std::string prev = "", AppFormatMode mode = AppFormatMode::Normal) const { |
| 5973 | if (prev.empty()) |
| 5974 | prev = get_name(); |
| 5975 | else |
| 5976 | prev += " " + get_name(); |
| 5977 | |
| 5978 | // Delegate to subcommand if needed |
| 5979 | auto selected_subcommands = get_subcommands(); |
| 5980 | if (!selected_subcommands.empty()) { |
| 5981 | return selected_subcommands.at(0)->help(prev, mode); |
| 5982 | } |
| 5983 | return formatter_->make_help(this, prev, mode); |
| 5984 | } |
| 5985 | |
| 5986 | ///@} |
| 5987 | /// @name Getters |
no test coverage detected