MCPcopy Create free account
hub / github.com/OpenZWave/open-zwave / getProduct

Method getProduct

cpp/src/ManufacturerSpecificDB.cpp:409–432  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

407}
408
409ProductDescriptor *ManufacturerSpecificDB::getProduct
410(
411 uint16 _manufacturerId,
412 uint16 _productType,
413 uint16 _productId
414)
415{
416
417 if (!s_bXmlLoaded) LoadProductXML();
418
419
420 // Try to get the real manufacturer and product names
421 map<uint16,string>::iterator mit = s_manufacturerMap.find( _manufacturerId );
422 if( mit != s_manufacturerMap.end() )
423 {
424 // Get the product
425 map<int64,ProductDescriptor*>::iterator pit = s_productMap.find( ProductDescriptor::GetKey( _manufacturerId, _productType, _productId ) );
426 if( pit != s_productMap.end() )
427 {
428 return pit->second;
429 }
430 }
431 return NULL;
432}
433
434bool ManufacturerSpecificDB::updateConfigFile
435(

Callers 1

SetProductDetailsMethod · 0.80

Calls 2

findMethod · 0.80
endMethod · 0.45

Tested by

no test coverage detected