You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
28 lines
698 B
C++
28 lines
698 B
C++
#pragma once
|
|
#include "DllDefines.h"
|
|
|
|
constexpr auto MAX_PARSE_PARM = 64;
|
|
constexpr auto MAX_TOK_LENGTH = 15;
|
|
constexpr auto MAX_PARSE_STRING_LEN = 256;
|
|
|
|
class UTILITYDLL CTrivialCsvParser
|
|
{
|
|
public:
|
|
CTrivialCsvParser();
|
|
CTrivialCsvParser(TCHAR* tok, int nparm);
|
|
|
|
~CTrivialCsvParser();
|
|
|
|
bool SetToken(TCHAR* tok);
|
|
bool SetMaxParm(int maxParm);
|
|
|
|
int Parse(TCHAR* inStr, TCHAR** parmList, TCHAR* tok, int maxParmExp, bool keepInputStrUnchanged = false);
|
|
int Parse(TCHAR* inStr, TCHAR** parmList, int numParm);
|
|
int Parse(TCHAR* inStr, TCHAR** parmList);
|
|
|
|
private:
|
|
TCHAR buf[MAX_PARSE_STRING_LEN];
|
|
TCHAR mTok[MAX_TOK_LENGTH + 1];
|
|
int m_iParam;
|
|
};
|