Class: FFI::StructLayout::InnerStruct

Inherits:
Field
  • Object
show all
Defined in:
lib/ffi/struct.rb

Instance Method Summary collapse

Methods inherited from Field

#alignment, #initialize, #name, #offset, #put, #size, #type

Constructor Details

This class inherits a constructor from FFI::StructLayout::Field

Instance Method Details

#get(ptr) ⇒ Object



51
52
53
# File 'lib/ffi/struct.rb', line 51

def get(ptr)
  type.struct_class.new(ptr.slice(self.offset, self.size))
end