Go to the documentation of this file.00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00017 #ifndef _STRMAP_H_
00018 #define _STRMAP_H_
00019
00020 #include "MathParserDll.h"
00021
00027 class MATHPARSERDLL_API CStrMap
00028 {
00029 int FCount, FCapacity;
00030 int FExtraLen, FRecordLen;
00031 int FDoDuplicate;
00032 char* FList;
00033 public:
00034 CStrMap( int extrabytes = sizeof( double ), int dup = 0 );
00035 ~CStrMap( void );
00036 void AddString( const char* str, void* data );
00037 void AddStrLen( const char* str, size_t len, const void* data );
00038 void TrimClear( int NewCount );
00039 void SetCapacity( int NewCapacity );
00040 int LenIndexOf( const char* str, size_t len, const void** data );
00041 const void* DataAt( int index );
00042 bool IsEmpty()
00043 {
00044 return FCount == 0;
00045 }
00046 };
00047
00048
00049 #define FUNC_ROUND 13
00050 #define FUNC_E 18
00051 #define FUNC_PI 19
00052
00053 class MATHPARSERDLL_API CStaticFuncMapDouble
00054 {
00055 public:
00056 static int LenIndexOf( const char* str, size_t len, const void** data );
00057 };
00058
00059 class MATHPARSERDLL_API CStaticFuncMapInt64
00060 {
00061 public:
00062 static int LenIndexOf( const char* str, size_t len, const void** data );
00063 };
00064
00065 #endif //_STRMAP_H_