#include <tokenmap.h>
Public Methods | |
void | AddMapping (XTOKEN xtFrom, XTOKEN xtTo) |
XTOKEN | GetMapping (XTOKEN xtFrom) |
|
Definition at line 13 of file tokenmap.cpp. 00014 { 00015 myassert(m_bExternalStream); 00016 00017 int iFrom = _XTOKENToIndex(xtFrom); 00018 if (iFrom >= m_vxtMap.size()) 00019 { 00020 m_vxtMap.resize((iFrom+1)*2); 00021 } 00022 m_vxtMap[iFrom] = xtTo; 00023 } |
|
Definition at line 25 of file tokenmap.cpp. 00026 { 00027 int iIndex = _XTOKENToIndex(xtFrom); 00028 if (iIndex < m_vxtMap.size()) 00029 { 00030 return m_vxtMap[iIndex](); 00031 } 00032 return XT_UNKNOWN; 00033 } |