Method: Cocoa#instance_for
- Defined in:
- lib/cocoa/helpers.rb
#instance_for(data) ⇒ Object
17 18 19 20 21 22 23 |
# File 'lib/cocoa/helpers.rb', line 17 def instance_for data if data.is_a?(FFI::Pointer) @@instances[data.address] ||= ObjC.ffi_to_ruby_value(nil, data, '@') else data end end |