| | |
| | | |
| | | CStep::CStep() |
| | | { |
| | | m_listener = {nullptr}; |
| | | m_nID = 0; |
| | | m_pCclink = nullptr; |
| | | InitializeCriticalSection(&m_criticalSection); |
| | | } |
| | |
| | | CStep::~CStep() |
| | | { |
| | | DeleteCriticalSection(&m_criticalSection); |
| | | } |
| | | |
| | | void CStep::setListener(StepListener listener) |
| | | { |
| | | m_listener.onEvent = listener.onEvent; |
| | | } |
| | | |
| | | void CStep::setCcLink(CCCLinkIEControl* pCcLink) |
| | |
| | | CEquipment* CStep::getEquipment() |
| | | { |
| | | return m_pEquipment; |
| | | } |
| | | |
| | | void CStep::setID(int id) |
| | | { |
| | | m_nID = id; |
| | | } |
| | | |
| | | int CStep::getID() |
| | | { |
| | | return m_nID; |
| | | } |
| | | |
| | | void CStep::setName(const char* pszName) |
| | |
| | | |
| | | } |
| | | |
| | | void CStep::setProp(const char* pszKey, void* pValue) |
| | | { |
| | | m_mapProp[pszKey] = pValue; |
| | | } |
| | | |
| | | void* CStep::getProp(const char* pszKey) |
| | | { |
| | | auto iter = m_mapProp.find(pszKey); |
| | | if (iter == m_mapProp.end()) return nullptr; |
| | | return iter->second; |
| | | } |
| | | |
| | | void CStep::convertString(const char* pszBuffer, int size, std::string& strOut) |
| | | { |
| | | strOut.clear(); |