----------------------------------------------------------------------------- Create a command class object using the registered method -----------------------------------------------------------------------------
| 172 | // Create a command class object using the registered method |
| 173 | //----------------------------------------------------------------------------- |
| 174 | CommandClass* CommandClasses::CreateCommandClass |
| 175 | ( |
| 176 | uint8 const _commandClassId, |
| 177 | uint32 const _homeId, |
| 178 | uint8 const _nodeId |
| 179 | ) |
| 180 | { |
| 181 | // Get a pointer to the required CommandClass's Create method |
| 182 | pfnCreateCommandClass_t creator = Get().m_commandClassCreators[_commandClassId]; |
| 183 | if( NULL == creator ) |
| 184 | { |
| 185 | return NULL; |
| 186 | } |
| 187 | |
| 188 | // Create an instance of the command class |
| 189 | CommandClass *cc = creator( _homeId, _nodeId); |
| 190 | Localization::Get()->SetupCommandClass(cc); |
| 191 | return cc; |
| 192 | } |
| 193 | |
| 194 | //----------------------------------------------------------------------------- |
| 195 | // <CommandClasses::RegisterCommandClasses> |
nothing calls this directly
no test coverage detected