Click or drag to resize

UpdateCacheEntry

Updates the cached value for the specified property.

template <typename T>
void UpdateCacheEntry(const CString& strKey, T value);
Parameters
strKey

[in] Name of property to invalidate. For more information, see property identifiers.

value

[in] New value to store in the cache for the specified property.

Example

The following example demonstrates use of the UpdateCacheEntry function.

C++
// CoAcme4321.cpp
STDMETHODIMP Acme4321::Configure(double Frequency, double Gain)
{
  HRESULT hr = S_OK;

  hr = io.Printf(_T("SENS:CONFIG %0.15g,%f"), Frequency, Gain);

  if (SUCCEEDED(hr))
  {
     UpdateCacheEntry(_T("IAcme4321.Frequency"), Frequency);

     UpdateCacheEntry(_T("IAcme4321.Gain"), Gain);
  }

  return hr;
}
See Also

Download a complete CHM version of this documentation here.