openMSX
SaveStateCLI.hh
Go to the documentation of this file.
1 #ifndef SAVESTATECLI_HH
2 #define SAVESTATECLI_HH
3 
4 #include "CLIOption.hh"
5 
6 namespace openmsx {
7 
8 class CommandLineParser;
9 
10 class SaveStateCLI final : public CLIOption, public CLIFileType
11 {
12 public:
13  explicit SaveStateCLI(CommandLineParser& parser);
14  void parseOption(const std::string& option,
15  span<std::string>& cmdLine) override;
16  std::string_view optionHelp() const override;
17  void parseFileType(const std::string& filename,
18  span<std::string>& cmdLine) override;
19  std::string_view fileTypeHelp() const override;
20  std::string_view fileTypeCategoryName() const override;
21 
22 private:
23  CommandLineParser& parser;
24 };
25 
26 } // namespace openmsx
27 
28 #endif
openmsx::CLIOption
Definition: CLIOption.hh:9
openmsx::SaveStateCLI::parseOption
void parseOption(const std::string &option, span< std::string > &cmdLine) override
Definition: SaveStateCLI.cc:16
openmsx::CLIFileType
Definition: CLIOption.hh:24
span
Definition: span.hh:34
openmsx::SaveStateCLI::SaveStateCLI
SaveStateCLI(CommandLineParser &parser)
Definition: SaveStateCLI.cc:9
openmsx::SaveStateCLI
Definition: SaveStateCLI.hh:10
openmsx::SaveStateCLI::fileTypeHelp
std::string_view fileTypeHelp() const override
Definition: SaveStateCLI.cc:48
openmsx::SaveStateCLI::optionHelp
std::string_view optionHelp() const override
Definition: SaveStateCLI.cc:21
openmsx::filename
constexpr const char *const filename
Definition: FirmwareSwitch.cc:10
openmsx::SaveStateCLI::parseFileType
void parseFileType(const std::string &filename, span< std::string > &cmdLine) override
Definition: SaveStateCLI.cc:26
openmsx::CommandLineParser
Definition: CommandLineParser.hh:34
openmsx::SaveStateCLI::fileTypeCategoryName
std::string_view fileTypeCategoryName() const override
Definition: SaveStateCLI.cc:53
CLIOption.hh
openmsx
Thanks to enen for testing this on a real cartridge:
Definition: Autofire.cc:5