Home COM GDI+ WebBrowser Data Access

IOleCache2 Interface

 

IID_IOleCache2

{00000128-0000-0000-C000-000000000046}

 

 

The IOleCache2 interface allows object clients to selectively update each cache that was created with IOleCache::Cache.

 

The IOleCache2 interface can be implemented by an object handler and an in-process server. Rather than implementing, however, it is typical to use or aggregate the OLE implementation in the default handler, a pointer to which is available through a call to CreateDataCache.

 

The OLE-provided implementation includes implementations of the IOleCache interface methods, from which IOleCache2 inherits its contract definition. The IOleCache2 interface is called by container applications, object handlers, or in process servers to update one or more of the caches that were created with the IOleCache::Cache method. This extended interface was added so client applications can exercise precise control over updates to the caches being maintained.

 

 

Methods in VTable order

IUnknown Methods

Description

QueryInterface

Returns pointers to supported interfaces.

AddRef

Increments reference count.

Release

Decrements reference count.

IOleCache Methods

Description

Cache

Adds a presentation to the data or view cache.

Uncache

Removes a presentation previously added with IOleCache::Cache.

EnumCache

Returns an object to enumerate the current cache connections.

InitCache

Fills the cache with all the presentation data from the data object.

SetData

Fills the cache with specified format of presentation data.

IOleCache2 Methods

Description

UpdateCache

Updates the specified cache(s).

DiscardCache

Discards cache(s) found in memory.

 

Cache

 

FUNCTION IOleCache2_Cache ( _

  BYVAL pthis AS DWORD PTR _

, BYREF pformatetc AS FORMATETC _

, BYVAL advf AS DWORD _

, BYREF pdwConnection AS DWORD _

  ) AS LONG
 

  LOCAL HRESULT AS LONG
  CALL DWORD @@pthis[3] USING IOleCache2_Cache (pthis, pformatetc, advf, pdwConnection) TO HRESULT
  FUNCTION = HRESULT


END FUNCTION

 

 

Uncache

 

FUNCTION IOleCache2_Uncache ( _

  BYVAL pthis AS DWORD PTR _

, BYVAL dwConnection AS DWORD _

  ) AS LONG
 

  LOCAL HRESULT AS LONG
  CALL DWORD @@pthis[4] USING IOleCache2_Uncache (pthis, dwConnection) TO HRESULT
  FUNCTION = HRESULT


END FUNCTION

 

 

EnumCache

 

FUNCTION IOleCache2_EnumCache ( _

  BYVAL pthis AS DWORD PTR _

, BYREF ppenumSTATDATA AS DWORD _

  ) AS LONG
 

  LOCAL HRESULT AS LONG
  CALL DWORD @@pthis[5] USING IOleCache2_EnumCache (pthis, ppenumSTATDATA) TO HRESULT
  FUNCTION = HRESULT


END FUNCTION

 

 

InitCache

 

FUNCTION IOleCache2_InitCache ( _

  BYVAL pthis AS DWORD PTR _

, BYVAL pDataObject AS DWORD _

  ) AS LONG
 

  LOCAL HRESULT AS LONG
  CALL DWORD @@pthis[6] USING IOleCache2_InitCache (pthis, pDataObject) TO HRESULT
  FUNCTION = HRESULT


END FUNCTION

 

 

SetData

 

FUNCTION IOleCache2_SetData ( _

  BYVAL pthis AS DWORD PTR _

, BYREF pformatetc AS FORMATETC _

, BYREF pmedium AS STGMEDIUM _

, BYVAL fRelease AS LONG _

  ) AS LONG
 

  LOCAL HRESULT AS LONG
  CALL DWORD @@pthis[7] USING IOleCache2_SetData (pthis, pformatetc, pmedium, fRelease) TO HRESULT
  FUNCTION = HRESULT


END FUNCTION

 

 

UpdateCache

 

FUNCTION IOleCache2_UpdateCache ( _

  BYVAL pthis AS DWORD PTR _

, BYVAL pDataObject AS DWORD _

, BYVAL grfUpdf AS DWORD _

, BYVAL pReserved AS DWORD _

  ) AS LONG
 

  LOCAL HRESULT AS LONG
  CALL DWORD @@pthis[8] USING IOleCache2_UpdateCache (pthis, pDataObject, grfUpdf, pReserved) TO HRESULT
  FUNCTION = HRESULT

 

END FUNCTION

 

 

DiscardCache

 

FUNCTION IOleCache2_DiscardCache ( _

  BYVAL pthis AS DWORD PTR _

, BYVAL dwDiscardOptions AS DWORD _

  ) AS LONG
 

  LOCAL HRESULT AS LONG
  CALL DWORD @@pthis[9] USING IOleCache2_DiscardCache (pthis, dwDiscardOptions) TO HRESULT
  FUNCTION = HRESULT


END FUNCTION

 

 

Page last updated on Monday, 03 April 2006 20:30:35 +0200