Class Ole::Types::PropertySet
In: lib/ole/types/property_set.rb
Parent: Object
String Data Lpstr Clsid Lpwstr Section Enumerable DateTime FileTime Constants Variant::Constants Storage\n[lib/ole/storage/base.rb\nlib/ole/storage/file_system.rb\nlib/ole/storage/meta_data.rb] PropertySet lib/ole/storage/file_system.rb lib/ole/types/property_set.rb lib/ole/types/base.rb Constants Constants Variant Types Ole dot/m_9_0.png

The PropertySet class currently supports readonly access to the properties serialized in "property set" streams, such as the file "\005SummaryInformation", in OLE files.

Think it has its roots in MFC property set serialization.

See poi.apache.org/hpsf/internals.html for details

Constants

HEADER_SIZE = 28
HEADER_PACK = "vvVa#{Clsid::SIZE}V"
OS_MAP = { 0 => :win16, 1 => :mac, 2 => :win32, 0x20001 => :ooffice, # open office on linux... }
DATA = YAML.load_file('/usr/share/libole-ruby1.8/propids.yaml'). inject({}) { |hash, (key, value)| hash.update Clsid.parse(key) => value }   define a smattering of the property set guids.
PROPERTY_MAP = DATA.inject({}) do |h1, (guid, data)| data[1].inject(h1) { |h2, (id, name)| h2.update name => [guid, id] }   create an inverted map of names to guid/key pairs

[Validate]