Class: MachO::MachOStructure
- Inherits:
-
Object
- Object
- MachO::MachOStructure
- Defined in:
- lib/macho/structure.rb
Overview
A general purpose pseudo-structure.
Direct Known Subclasses
Class Method Summary collapse
-
.bytesize ⇒ Fixnum
The size, in bytes, of the represented structure.
-
.new_from_bin(bin) ⇒ MachO::MachOStructure
A new MachOStructure initialized with ‘bin`.
Class Method Details
.bytesize ⇒ Fixnum
Returns the size, in bytes, of the represented structure.
9 10 11 |
# File 'lib/macho/structure.rb', line 9 def self.bytesize @sizeof end |
.new_from_bin(bin) ⇒ MachO::MachOStructure
Returns a new MachOStructure initialized with ‘bin`.
14 15 16 |
# File 'lib/macho/structure.rb', line 14 def self.new_from_bin(bin) self.new(*bin.unpack(@format)) end |