----------------------------------------------------------------------------- Remove a command class from the node -----------------------------------------------------------------------------
| 2173 | // Remove a command class from the node |
| 2174 | //----------------------------------------------------------------------------- |
| 2175 | void Node::RemoveCommandClass |
| 2176 | ( |
| 2177 | uint8 const _commandClassId |
| 2178 | ) |
| 2179 | { |
| 2180 | map<uint8,CommandClass*>::iterator it = m_commandClassMap.find( _commandClassId ); |
| 2181 | if( it == m_commandClassMap.end() ) |
| 2182 | { |
| 2183 | // Class is not found |
| 2184 | return; |
| 2185 | } |
| 2186 | |
| 2187 | // Remove all the values associated with this class |
| 2188 | if( ValueStore* store = GetValueStore() ) |
| 2189 | { |
| 2190 | store->RemoveCommandClassValues( _commandClassId ); |
| 2191 | } |
| 2192 | |
| 2193 | // Destroy the command class object and remove it from our map |
| 2194 | Log::Write( LogLevel_Info, m_nodeId, "RemoveCommandClass - Removed support for %s", it->second->GetCommandClassName().c_str() ); |
| 2195 | |
| 2196 | delete it->second; |
| 2197 | m_commandClassMap.erase( it ); |
| 2198 | } |
| 2199 | |
| 2200 | //----------------------------------------------------------------------------- |
| 2201 | // <Node::SetConfigParam> |
nothing calls this directly
no test coverage detected