mirror of
https://foundry.openuru.org/gitblit/r/CWE-ou-minkata.git
synced 2025-07-21 12:49:10 +00:00
Remove some code that was never used anywhere.
This commit is contained in:
@ -648,51 +648,3 @@ bool CCmdParser::Parse (const wchar_t cmdLine[]) {
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
|
||||
/****************************************************************************
|
||||
*
|
||||
* CCmdParserSimple
|
||||
*
|
||||
***/
|
||||
|
||||
|
||||
//===========================================================================
|
||||
CCmdParserSimple::CCmdParserSimple (
|
||||
unsigned requiredStringCount,
|
||||
unsigned optionalStringCount,
|
||||
const wchar_t flaggedBoolNames[] // double null terminated if used
|
||||
) {
|
||||
|
||||
// Count the number of flagged arguments
|
||||
unsigned flaggedBoolCount = 0;
|
||||
const wchar_t * curr;
|
||||
if (flaggedBoolNames)
|
||||
for (curr = flaggedBoolNames; *curr; curr += StrLen(curr) + 1)
|
||||
++flaggedBoolCount;
|
||||
|
||||
// Build the argument definition array
|
||||
unsigned totalCount = requiredStringCount + optionalStringCount + flaggedBoolCount;
|
||||
FARRAY(CmdArgDef) argDef(totalCount);
|
||||
unsigned index = 0;
|
||||
for (; index < requiredStringCount; ++index) {
|
||||
argDef[index].flags = kCmdArgRequired | kCmdTypeString;
|
||||
argDef[index].name = nil;
|
||||
argDef[index].id = index + 1;
|
||||
}
|
||||
for (; index < requiredStringCount + optionalStringCount; ++index) {
|
||||
argDef[index].flags = kCmdArgOptional | kCmdTypeString;
|
||||
argDef[index].name = nil;
|
||||
argDef[index].id = index + 1;
|
||||
}
|
||||
for (curr = flaggedBoolNames; index < totalCount; ++index) {
|
||||
argDef[index].flags = kCmdArgFlagged | kCmdTypeBool;
|
||||
argDef[index].name = curr;
|
||||
argDef[index].id = 0;
|
||||
curr += StrLen(curr) + 1;
|
||||
}
|
||||
|
||||
// Initialize the parser
|
||||
Initialize(argDef.Ptr(), argDef.Count());
|
||||
|
||||
}
|
||||
|
Reference in New Issue
Block a user