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

Method RemoveValues

cpp/src/Scene.cpp:346–366  ·  view source on GitHub ↗

----------------------------------------------------------------------------- Remove all ValueIDs from given Home ID -----------------------------------------------------------------------------

Source from the content-addressed store, hash-verified

344// Remove all ValueIDs from given Home ID
345//-----------------------------------------------------------------------------
346void Scene::RemoveValues
347(
348 uint32 const _homeId
349)
350{
351 again:
352 for( vector<SceneStorage*>::iterator it = m_values.begin(); it != m_values.end(); ++it )
353 {
354 if( (*it)->m_id.GetHomeId() == _homeId )
355 {
356 delete *it;
357 m_values.erase( it );
358 goto again;
359 }
360 }
361 // If the scene is now empty, delete it.
362 if( m_values.empty() )
363 {
364 delete this;
365 }
366}
367
368//-----------------------------------------------------------------------------
369// <Scene::RemoveValues>

Callers 1

RemoveAllScenesMethod · 0.80

Calls 5

GetNodeIdMethod · 0.80
GetFunction · 0.70
beginMethod · 0.45
endMethod · 0.45
emptyMethod · 0.45

Tested by

no test coverage detected