Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Nov 4, 2009, 12:28:59 PM (14 years ago)
Author:
rgrieder
Message:

Renamed CommandLine to CommandLineParse to avoid confusions with the class name.

File:
1 copied

Legend:

Unmodified
Added
Removed
  • code/trunk/src/libraries/core/CommandLineParser.h

    r6014 r6021  
    3838#define SetCommandLineArgument(name, defaultValue) \
    3939    orxonox::CommandLineArgument& CmdArgumentDummyBoolVar##name \
    40     = orxonox::CommandLine::addArgument(#name, defaultValue, false)
     40    = orxonox::CommandLineParser::addArgument(#name, defaultValue, false)
    4141#define SetCommandLineOnlyArgument(name, defaultValue) \
    4242    orxonox::CommandLineArgument& CmdArgumentDummyBoolVar##name \
    43     = orxonox::CommandLine::addArgument(#name, defaultValue, true)
     43    = orxonox::CommandLineParser::addArgument(#name, defaultValue, true)
    4444#define SetCommandLineSwitch(name) \
    4545    orxonox::CommandLineArgument& CmdArgumentDummyBoolVar##name \
    46     = orxonox::CommandLine::addArgument(#name, false, false)
     46    = orxonox::CommandLineParser::addArgument(#name, false, false)
    4747#define SetCommandLineOnlySwitch(name) \
    4848    orxonox::CommandLineArgument& CmdArgumentDummyBoolVar##name \
    49     = orxonox::CommandLine::addArgument(#name, false, true)
     49    = orxonox::CommandLineParser::addArgument(#name, false, true)
    5050
    5151
     
    6767
    6868        Retrieving an argument is possible with the getCommandLineArgument function of the
    69         CommandLine class. It is a Singleton, but the public interface is static.
     69        CommandLineParser class. It is a Singleton, but the public interface is static.
    7070    */
    7171    class _CoreExport CommandLineArgument
    7272    {
    73         friend class CommandLine;
     73        friend class CommandLineParser;
    7474
    7575    public:
     
    137137        CommandLineArgument
    138138    */
    139     class _CoreExport CommandLine
     139    class _CoreExport CommandLineParser
    140140    {
    141141    public:
     
    167167    private:
    168168        //! Constructor initialises bFirstTimeParse_ with true.
    169         CommandLine() : bFirstTimeParse_(true) { }
     169        CommandLineParser() : bFirstTimeParse_(true) { }
    170170        //! Undefined copy constructor
    171         CommandLine(const CommandLine& instance);
    172         ~CommandLine();
    173 
    174         static CommandLine& _getInstance();
     171        CommandLineParser(const CommandLineParser& instance);
     172        ~CommandLineParser();
     173
     174        static CommandLineParser& _getInstance();
    175175
    176176        void _parseCommandLine(const std::string& cmdLine);
     
    194194
    195195    template <>
    196     inline void CommandLine::getValue<std::string>(const std::string& name, std::string* value)
     196    inline void CommandLineParser::getValue<std::string>(const std::string& name, std::string* value)
    197197    {
    198198        *value = getArgument(name)->getValue().getString();
     
    209209    */
    210210    template <class T>
    211     CommandLineArgument& CommandLine::addArgument(const std::string& name, T defaultValue, bool bCommandLineOnly)
     211    CommandLineArgument& CommandLineParser::addArgument(const std::string& name, T defaultValue, bool bCommandLineOnly)
    212212    {
    213213        OrxAssert(!_getInstance().existsArgument(name),
Note: See TracChangeset for help on using the changeset viewer.