Class: Exerb::FileTable::Header

Inherits:
Object
  • Object
show all
Defined in:
lib/exerb/file_table.rb

Overview

#

Constant Summary collapse

SIGNATURE =
0x04005446

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeHeader

Returns a new instance of Header.



115
116
117
118
119
120
# File 'lib/exerb/file_table.rb', line 115

def initialize
  @signature         = 0
  @number_of_headers = 0
  @offset_of_headers = 0
  @offset_of_pool    = 0
end

Instance Attribute Details

#number_of_headersObject

Returns the value of attribute number_of_headers.



122
123
124
# File 'lib/exerb/file_table.rb', line 122

def number_of_headers
  @number_of_headers
end

#offset_of_headersObject

Returns the value of attribute offset_of_headers.



122
123
124
# File 'lib/exerb/file_table.rb', line 122

def offset_of_headers
  @offset_of_headers
end

#offset_of_poolObject

Returns the value of attribute offset_of_pool.



122
123
124
# File 'lib/exerb/file_table.rb', line 122

def offset_of_pool
  @offset_of_pool
end

#signatureObject

Returns the value of attribute signature.



122
123
124
# File 'lib/exerb/file_table.rb', line 122

def signature
  @signature
end

Instance Method Details

#packObject



124
125
126
# File 'lib/exerb/file_table.rb', line 124

def pack
  return [@signature, @number_of_headers, @offset_of_headers, @offset_of_pool].pack('LSLL')
end