lib/pedump/ne/version_info.rb in pedump-0.4.16 vs lib/pedump/ne/version_info.rb in pedump-0.5.0

- old
+ new

@@ -1,9 +1,9 @@ class PEdump; end class PEdump::NE - class VS_VERSIONINFO < PEdump.create_struct( 'v2a16', + class VS_VERSIONINFO < IOStruct.new( 'v2a16', :wLength, :wValueLength, :szKey, # ASCII string "VS_VERSION_INFO". :Padding1, # manual: @@ -39,11 +39,11 @@ end end end end - class VS_FIXEDFILEINFO < PEdump.create_struct( 'V13', + class VS_FIXEDFILEINFO < IOStruct.new( 'V13', :dwSignature, :dwStrucVersion, :dwFileVersionMS, :dwFileVersionLS, :dwProductVersionMS, @@ -63,11 +63,11 @@ ffi.valid = (ffi.dwSignature == 0xFEEF04BD) end end end - class StringFileInfo < PEdump.create_struct( 'v2a15', + class StringFileInfo < IOStruct.new( 'v2a15', :wLength, :wValueLength, # always 0 :szKey, # The ASCII string "StringFileInfo" :Padding, # As many zero words as necessary to align the Children member on a 32-bit boundary :Children # An array of one or more StringTable structures @@ -83,11 +83,11 @@ end end end end - class StringTable < PEdump.create_struct( 'v2a9', + class StringTable < IOStruct.new( 'v2a9', :wLength, # The length, in bytes, of this StringTable structure, # including all structures indicated by the Children member. :wValueLength, # always 0 :szKey, # An 8-digit hexadecimal number stored as a ASCII string :Padding, # As many zero words as necessary to align the Children member on a 32-bit boundary @@ -104,11 +104,11 @@ end end end end - class VersionString < PEdump.create_struct( 'v2', + class VersionString < IOStruct.new( 'v2', :wLength, # The length, in bytes, of this String structure. :wValueLength, # The size, in words, of the Value member :szKey, # An arbitrary ASCII string :Padding, # As many zero words as necessary to align the Value member on a 32-bit boundary :Value # A zero-terminated string. See the szKey member description for more information @@ -135,11 +135,11 @@ end end end end - class VarFileInfo < PEdump.create_struct( 'v2a12', + class VarFileInfo < IOStruct.new( 'v2a12', :wLength, :wValueLength, # always 0 :szKey, # The ASCII string "VarFileInfo" :Padding, # As many zero words as necessary to align the Children member on a 32-bit boundary :Children # Typically contains a list of languages that the application or DLL supports @@ -151,10 +151,10 @@ x.Children = Var.read(f) end end end - class Var < PEdump.create_struct( 'v2a12', + class Var < IOStruct.new( 'v2a12', :wLength, :wValueLength, # The length, in bytes, of the Value member :szKey, # The ASCII string "Translation" :Padding, # As many zero words as necessary to align the Children member on a 32-bit boundary :Value # An array of one or more values that are language and code page identifier pairs