![]() | CCacheEntry<T>::IsValid |
Indicates whether or not a cache entry is valid.
virtual bool CCacheEntry<T>::IsValid() const;
Returns true if the specified value is valid, otherwise false.
The following example demonstrates use of the IsValid function.
// CoAcme4321.cpp STDMETHODIMP Acme4321::Configure(double Frequency, double Gain) { HRESULT hr = S_OK; // Retrieve the cache entry for the Frequency property CCacheEntry<double>* pEntry = GetOrCreateCacheEntry<double>(_T("IAcme4321.Frequency")); if (pEntry->IsValid()) { // ... } return hr; }