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

Method GetValueMin

cpp/src/Manager.cpp:1931–1950  ·  view source on GitHub ↗

----------------------------------------------------------------------------- Gets the minimum for a value -----------------------------------------------------------------------------

Source from the content-addressed store, hash-verified

1929// Gets the minimum for a value
1930//-----------------------------------------------------------------------------
1931int32 Manager::GetValueMin
1932(
1933 ValueID const& _id
1934)
1935{
1936 int32 limit = 0;
1937 if( Driver* driver = GetDriver( _id.GetHomeId() ) )
1938 {
1939 LockGuard LG(driver->m_nodeMutex);
1940 if( Value* value = driver->GetValue( _id ) )
1941 {
1942 limit = value->GetMin();
1943 value->Release();
1944 } else {
1945 OZW_ERROR(OZWException::OZWEXCEPTION_INVALID_VALUEID, "Invalid ValueID passed to GetValueMin");
1946 }
1947 }
1948
1949 return limit;
1950}
1951
1952//-----------------------------------------------------------------------------
1953// <Manager::GetValueMax>

Callers 1

mainFunction · 0.80

Calls 3

GetMinMethod · 0.80
GetValueMethod · 0.45
ReleaseMethod · 0.45

Tested by

no test coverage detected