mirror of
https://github.com/alliedmodders/hl2sdk.git
synced 2024-12-23 01:59:43 +08:00
Update CSplitString (#267)
This commit is contained in:
parent
d2709c880c
commit
ffbc15d41e
@ -1196,12 +1196,12 @@ class CSplitString: public CUtlVector<char*, CUtlMemory<char*, int> >
|
||||
public:
|
||||
CSplitString(const char *pString, const char *pSeparator, bool bIncludeSeparators = false)
|
||||
{
|
||||
Construct( pString, &pSeparator, 1, bIncludeSeparators);
|
||||
Split( pString, 0, &pSeparator, 1, bIncludeSeparators);
|
||||
}
|
||||
|
||||
CSplitString(const char *pString, const char **pSeparators, int nSeparators, bool bIncludeSeparators = false)
|
||||
{
|
||||
Construct(pString, pSeparators, nSeparators, bIncludeSeparators);
|
||||
Split(pString, 0, pSeparators, nSeparators, bIncludeSeparators);
|
||||
}
|
||||
|
||||
~CSplitString()
|
||||
@ -1214,7 +1214,7 @@ public:
|
||||
// NOTE: If you want to make Construct() public and implement Purge() here, you'll have to free m_szBuffer there
|
||||
//
|
||||
private:
|
||||
DLL_CLASS_IMPORT void Construct(const char *pString, const char **pSeparators, int nSeparators, bool bIncludeSeparators);
|
||||
DLL_CLASS_IMPORT void Split(const char *pString, int stringSize, const char **pSeparators, int nSeparators, bool bIncludeSeparators);
|
||||
|
||||
void PurgeAndDeleteElements()
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user