Home COM GDI+ WebBrowser Data Access

IPropertyStorage Interface

 

IID_IPropertyStorage

{00000138-0000-0000-C000-000000000046}

 

 

The IPropertyStorage interface manages the persistent properties of a single property set. Persistent properties consist of information that can be stored persistently in a property set, such as the summary information associated with a file. This contrasts with run-time properties associated with Controls and Automation, which can be used to affect system behavior. Use the methods of the IPropertySetStorage interface to create or open a persistent property set. An instance of the IPropertySetStorage interface can manage zero or more IPropertyStorage instances.

 

Each property within a property set is identified by a property identifier (ID), a four-byte ULONG value unique to that set. You can also assign a string name to a property through the IPropertyStorage interface.

 

Property IDs differ from the dispatch IDs used in Automation dispid property name tags. One difference is that the general-purpose use of property ID values zero and one is prohibited in IPropertyStorage, while no such restriction exists in IDispatch. In addition, while there is significant overlap among the data types for property values that may be used in IPropertyStorage and IDispatch, the property sets are not identical. Persistent property data types used in IPropertyStorage methods are defined in the PROPVARIANT structure.

 

The IPropertyStorage interface can be used to access both simple and nonsimple property sets. Nonsimple property sets can hold several complex property types that cannot be held in a simple property set. For more information see Storage vs. Stream for a Property Set.

 

Use IPropertyStorage to create and manage properties that are stored in a given property set.

 

 

Methods in VTable order

IUnknown Methods

Description

QueryInterface

Returns pointers to supported interfaces.

AddRef

Increments reference count.

Release

Decrements reference count.

IPropertyStorage Methods

Description

ReadMultiple

Reads property values in a property set.

WriteMultiple

Writes property values in a property set.

DeleteMultiple

Deletes properties in a property set.

ReadPropertyNames

Gets corresponding string names for given property identifiers.

WritePropertyNames

Creates or changes string names corresponding to given property identifiers.

DeletePropertyNames

Deletes string names for given property identifiers.

Commit

As in IStorage::Commit, flushes or commits changes to the property storage object.

Revert

When the property storage is opened in transacted mode, discards all changes since the last commit.

Enum

Creates and gets a pointer to an enumerator for properties within this set.

SetTimes

Sets modification, creation, and access times for the property set.

SetClass

Assigns a CLSID to the property set.

Stat

Receives statistics about this property set.

 

QueryInterface

 

FUNCTION IPropertyStorage_QueryInterface ( _

  BYVAL pthis AS DWORD PTR _

, BYREF riid AS GUID _

, BYREF ppvObj AS DWORD _

  ) AS LONG


  LOCAL HRESULT AS LONG
  CALL DWORD @@pthis[0] USING IPropertyStorage_QueryInterface (pthis, riid, ppvObj) TO HRESULT
  FUNCTION = HRESULT
 

END FUNCTION

 

 

AddRef

 

FUNCTION IPropertyStorage_AddRef ( _

  BYVAL pthis AS DWORD PTR _

  ) AS DWORD
 

  LOCAL DWRESULT AS LONG
  CALL DWORD @@pthis[1] USING IPropertyStorage_AddRef (pthis) TO DWRESULT
  FUNCTION = DWRESULT
 

END FUNCTION

 

 

Release

 

FUNCTION IPropertyStorage_Release ( _

  BYVAL pthis AS DWORD PTR _

  ) AS DWORD
 

  LOCAL DWRESULT AS DWORD
  CALL DWORD @@pthis[2] USING IPropertyStorage_Release (pthis) TO DWRESULT
  FUNCTION = DWRESULT
 

END FUNCTION

 

 

ReadMultiple

 

FUNCTION IPropertyStorage_ReadMultiple ( _

  BYVAL pthis AS DWORD PTR _

, BYVAL cpspec AS DWORD _

, BYVAL rgpspec AS DWORD _

, BYVAL rgpropvar AS DWORD _

  ) AS LONG
 

  LOCAL HRESULT AS LONG
  CALL DWORD @@pthis[3] USING IPropertyStorage_ReadMultiple (pthis, cpspec, rgpspec, rgpropvar) TO HRESULT
  FUNCTION = HRESULT

 

END FUNCTION

 

 

WriteMultiple

 

FUNCTION IPropertyStorage_WriteMultiple ( _

  BYVAL pthis AS DWORD PTR _

, BYVAL cpspec AS DWORD _

, BYVAL rgpspec AS DWORD _

, BYVAL rgpropvar AS DWORD _

, BYVAL propidNameFirst AS DWORD _

  ) AS LONG
 

  LOCAL HRESULT AS LONG
  CALL DWORD @@pthis[4] USING IPropertyStorage_WriteMultiple (pthis, cpspec, rgpspec, rgpropvar, propidNameFirst) TO HRESULT
  FUNCTION = HRESULT

 

END FUNCTION

 

 

DeleteMultiple

 

FUNCTION IPropertyStorage_DeleteMultiple ( _

  BYVAL pthis AS DWORD PTR _

, BYVAL cpspec AS DWORD _

, BYVAL rgpspec AS DWORD _

  ) AS LONG
 

  LOCAL HRESULT AS LONG
  CALL DWORD @@pthis[5] USING IPropertyStorage_DeleteMultiple (pthis, cpspec, rgpspec) TO HRESULT
  FUNCTION = HRESULT

 

END FUNCTION

 

 

ReadPropertyNames

 

FUNCTION IPropertyStorage_ReadPropertyNames ( _

  BYVAL pthis AS DWORD PTR _

, BYVAL cpropid AS DWORD _

, BYVAL rgpropid AS DWORD _

, BYREF rglpwstrName AS DWORD _

  ) AS LONG
 

  LOCAL HRESULT AS LONG
  CALL DWORD @@pthis[6] USING IPropertyStorage_ReadPropertyNames (pthis, cpropid, rgpropid, rglpwstrName) TO HRESULT
  FUNCTION = HRESULT

 

END FUNCTION

 

 

WritePropertyNames

 

FUNCTION IPropertyStorage_WritePropertyNames ( _

  BYVAL pthis AS DWORD PTR _

, BYVAL cpropid AS DWORD _

, BYVAL rgpropid AS DWORD _

, BYVAL rglpwstrName AS DWORD _

  ) AS LONG
 

  LOCAL HRESULT AS LONG
  CALL DWORD
@@pthis[7] USING IPropertyStorage_WritePropertyNames (pthis, cpropid, rgpropid, rglpwstrName) TO HRESULT
  FUNCTION = HRESULT


END FUNCTION

 

 

DeletePropertyNames

 

FUNCTION IPropertyStorage_DeletePropertyNames ( _

  BYVAL pthis AS DWORD PTR _

, BYVAL cpropid AS DWORD _

, BYVAL rgpropid AS DWORD _

  ) AS LONG
 

  LOCAL HRESULT AS LONG
  CALL DWORD @@pthis[8] USING IPropertyStorage_DeletePropertyNames (pthis, cpropid, rgpropid) TO HRESULT
  FUNCTION = HRESULT


END FUNCTION

 

 

Commit

 

FUNCTION IPropertyStorage_Commit ( _

  BYVAL pthis AS DWORD PTR _

, BYVAL grfCommitFlags AS DWORD _

  ) AS LONG
 

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

 

END FUNCTION

 

 

Revert

 

FUNCTION IPropertyStorage_Revert ( _

  BYVAL pthis AS DWORD PTR _

  ) AS LONG
 

  LOCAL HRESULT AS LONG
  CALL DWORD @@pthis[10] USING IPropertyStorage_Revert (pthis) TO HRESULT
  FUNCTION = HRESULT

 

END FUNCTION

 

 

Enum

 

FUNCTION IPropertyStorage_Enum ( _

  BYVAL pthis AS DWORD PTR _

, BYREF ppenum AS DWORD _

  ) AS LONG
 

  LOCAL HRESULT AS LONG
  CALL DWORD @@pthis[11] USING IPropertyStorage_Enum (pthis, ppenum) TO HRESULT
  FUNCTION = HRESULT

 

END FUNCTION

 

 

SetTimes

 

FUNCTION IPropertyStorage_SetTimes ( _

  BYVAL pthis AS DWORD PTR _

, BYREF pctime AS FILETIME _

, BYREF patime AS FILETIME _

, BYREF pmtime AS FILETIME _

  ) AS LONG
 

  LOCAL HRESULT AS LONG
  CALL DWORD @@pthis[12] USING IPropertyStorage_SetTimes (pthis, pctime, patime, pmtime) TO HRESULT
  FUNCTION = HRESULT

 

END FUNCTION

 

 

SetClass

 

FUNCTION IPropertyStorage_SetClass ( _

  BYVAL pthis AS DWORD PTR _

, BYREF rclsid AS GUID _

  ) AS LONG
 

  LOCAL HRESULT AS LONG
  CALL DWORD @@pthis[13] USING IPropertyStorage_SetClass (pthis, rclsid) TO HRESULT
  FUNCTION = HRESULT

 

END FUNCTION

 

 

Stat

 

FUNCTION IPropertyStorage_Stat ( _

  BYVAL pthis AS DWORD PTR _

, BYREF pstatpsstg AS STATPROPSETSTG _

  ) AS LONG
 

  LOCAL HRESULT AS LONG
  CALL DWORD @@pthis[14] USING IPropertyStorage_Stat (pthis, pstatpsstg) TO HRESULT
  FUNCTION = HRESULT

 

END FUNCTION

 

 

Page last updated on Monday, 27 March 2006 09:08:37 +0100