2
0
Эх сурвалжийг харах

Merge branch 'master' of github.com:bkaradzic/bx

Branimir Karadžić 8 жил өмнө
parent
commit
db18c3b854

+ 6 - 0
include/bx/commandline.h

@@ -60,6 +60,12 @@ namespace bx
 		///
 		///
 		bool hasArg(bool& _value, const char _short, const char* _long = NULL) const;
 		bool hasArg(bool& _value, const char _short, const char* _long = NULL) const;
 
 
+		///
+		int32_t getNum() const;
+
+		///
+		char const* get(int32_t _idx) const;
+
 	private:
 	private:
 		///
 		///
 		const char* find(int32_t _skip, const char _short, const char* _long, int32_t _numParams) const;
 		const char* find(int32_t _skip, const char _short, const char* _long, int32_t _numParams) const;

+ 10 - 0
src/commandline.cpp

@@ -319,4 +319,14 @@ namespace bx
 		return NULL;
 		return NULL;
 	}
 	}
 
 
+	int32_t CommandLine::getNum() const
+	{
+		return m_argc;
+	}
+
+	char const* CommandLine::get(int32_t _idx) const
+	{
+		return m_argv[_idx];
+	}
+
 } // namespace bx
 } // namespace bx