IBinaryPropertyBag Interface

Applies to: SharePoint Foundation 2010

Provides an interface with methods for reading and writing values in a property bag object as binary data.

{
   uuid(B61EAD39-3123-4f68-8F04-25F70AD652B3)
}
interface IBinaryPropertyBag : IUnknown

Remarks

Includes methods that enable the document parser to access values in a property bag as binary data. Use the QueryInterface method of an object that implements the IParserPropertyBag Interface to get an interface pointer, as shown in the following example.

STDMETHODIMP TDP::Parse(
    ILockBytes *pilb,
    IParserPropertyBag *pipbag,
    VARIANT_BOOL *pfChanged)
{ 
   HRESULT hr = E_FAIL; 
   IBinaryPropertyBag* pibbag = NULL;
   BYTE* pbVal = NULL;
   unsigned int cbVal = 0;
   //
   // Code omitted.
   //
   hr = pipbag->QueryInterface(IID_IBinaryPropertyBag, (void**)&pibbag));
   hr = pibbag->GetBytes("vti_fileformatmetainfo", &cbVal, &pbVal);
   //
   // Code omitted.
   //
}

See Also

Concepts

Custom Document Parsers

Document Parser Interface Overview