openMSX
Classes | Public Types | Public Member Functions | Friends | List of all members
openmsx::CommandLineParser Class Reference

#include <CommandLineParser.hh>

Inheritance diagram for openmsx::CommandLineParser:
Inheritance graph
[legend]
Collaboration diagram for openmsx::CommandLineParser:
Collaboration graph
[legend]

Classes

struct  OptionData

Public Types

enum  ParseStatus {
  UNPARSED, RUN, CONTROL, TEST,
  EXIT
}
enum  ParsePhase {
  PHASE_BEFORE_INIT, PHASE_INIT, PHASE_BEFORE_SETTINGS, PHASE_LOAD_SETTINGS,
  PHASE_BEFORE_MACHINE, PHASE_LOAD_MACHINE, PHASE_EXT, PHASE_LAST
}
typedef std::vector< std::string > Scripts

Public Member Functions

 CommandLineParser (Reactor &reactor)
 ~CommandLineParser ()
void registerOption (const char *str, CLIOption &cliOption, ParsePhase phase=PHASE_LAST, unsigned length=2)
void registerFileClass (const char *str, CLIFileType &cliFileType)
void parse (int argc, char **argv)
ParseStatus getParseStatus () const
const ScriptsgetStartupScripts () const
MSXMotherBoardgetMotherBoard () const
GlobalCommandControllergetGlobalCommandController () const
bool isHiddenStartup () const
 Need to suppress renderer window on startup?

Friends

class ControlOption
class HelpOption
class VersionOption
class MachineOption
class SettingOption
class TestConfigOption
class BashOption

Additional Inherited Members

Detailed Description

Definition at line 39 of file CommandLineParser.hh.

Member Typedef Documentation

typedef std::vector<std::string> openmsx::CommandLineParser::Scripts

Definition at line 62 of file CommandLineParser.hh.

Member Enumeration Documentation

Enumerator:
PHASE_BEFORE_INIT 
PHASE_INIT 
PHASE_BEFORE_SETTINGS 
PHASE_LOAD_SETTINGS 
PHASE_BEFORE_MACHINE 
PHASE_LOAD_MACHINE 
PHASE_EXT 
PHASE_LAST 

Definition at line 43 of file CommandLineParser.hh.

Enumerator:
UNPARSED 
RUN 
CONTROL 
TEST 
EXIT 

Definition at line 42 of file CommandLineParser.hh.

Constructor & Destructor Documentation

openmsx::CommandLineParser::CommandLineParser ( Reactor reactor)
explicit
openmsx::CommandLineParser::~CommandLineParser ( )

Definition at line 200 of file CommandLineParser.cc.

Member Function Documentation

GlobalCommandController & openmsx::CommandLineParser::getGlobalCommandController ( ) const
MSXMotherBoard * openmsx::CommandLineParser::getMotherBoard ( ) const
CommandLineParser::ParseStatus openmsx::CommandLineParser::getParseStatus ( ) const

Definition at line 422 of file CommandLineParser.cc.

References UNPARSED.

Referenced by openmsx::Reactor::run().

const CommandLineParser::Scripts & openmsx::CommandLineParser::getStartupScripts ( ) const

Definition at line 428 of file CommandLineParser.cc.

Referenced by openmsx::Reactor::run().

bool openmsx::CommandLineParser::isHiddenStartup ( ) const

Need to suppress renderer window on startup?

Definition at line 417 of file CommandLineParser.cc.

void openmsx::CommandLineParser::parse ( int  argc,
char **  argv 
)
void openmsx::CommandLineParser::registerFileClass ( const char *  str,
CLIFileType cliFileType 
)
void openmsx::CommandLineParser::registerOption ( const char *  str,
CLIOption cliOption,
ParsePhase  phase = PHASE_LAST,
unsigned  length = 2 
)

Friends And Related Function Documentation

friend class BashOption
friend

Definition at line 126 of file CommandLineParser.hh.

friend class ControlOption
friend

Definition at line 120 of file CommandLineParser.hh.

friend class HelpOption
friend

Definition at line 121 of file CommandLineParser.hh.

friend class MachineOption
friend

Definition at line 123 of file CommandLineParser.hh.

friend class SettingOption
friend

Definition at line 124 of file CommandLineParser.hh.

friend class TestConfigOption
friend

Definition at line 125 of file CommandLineParser.hh.

friend class VersionOption
friend

Definition at line 122 of file CommandLineParser.hh.


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