module CF::Memory
Provides a more declarative way to define all required abstract methods. This gets included in the CF::Base
class whose subclasses then need to define those methods.
Public Instance Methods
inspect()
click to toggle source
Returns a ruby string containing the output of CFCopyDescription for the wrapped object
@return [String]
# File lib/corefoundation/memory.rb, line 20 def inspect CF::String.new(CF.CFCopyDescription(self)).to_s end
release()
click to toggle source
Calls CFRelease on the wrapped pointer
@return Returns self
# File lib/corefoundation/memory.rb, line 27 def release CF.release(self) self end
retain()
click to toggle source
Calls CFRetain on the wrapped pointer
@return Returns self
# File lib/corefoundation/memory.rb, line 35 def retain CF.retain(self) self end
to_ptr()
click to toggle source
Returns the wrapped pointer
@return [FFI::Pointer]
# File lib/corefoundation/memory.rb, line 43 def to_ptr ptr end