Method: Efl::Elm::ElmStore#initialize

Defined in:
lib/efl/elm/elm_store.rb

#initialize(o = nil, &block) ⇒ ElmStore

Returns a new instance of ElmStore.



16
17
18
19
20
21
22
23
24
25
26
27
28
# File 'lib/efl/elm/elm_store.rb', line 16

def initialize o=nil, &block
    @ptr = (
        case o
        when NilClass
            FFI::AutoPointer.new Native.elm_store_filesystem_new, ElmStore.method(:release)
        when FFI::Pointer
            o
        else
            raise ArgumentError.new "wrong argument #{o.class.name}"
        end
    )
    instance_eval &block if block
end