Class: GObjectIntrospection::IFunctionInfo

Inherits:
ICallableInfo show all
Defined in:
lib/ffi-gobject_introspection/i_function_info.rb

Overview

Wraps a GIFunctionInfo struct. Represents a function or method.

Instance Method Summary collapse

Methods inherited from ICallableInfo

#arg, #caller_owns, #may_return_null?, #n_args, #return_type, #skip_return?

Methods inherited from IBaseInfo

#==, build_array_method, build_finder_method, #container, #deprecated?, #info_type, #initialize, make_finalizer, #name, #namespace, #safe_namespace, #to_ptr, wrap

Constructor Details

This class inherits a constructor from GObjectIntrospection::IBaseInfo

Instance Method Details

#constructor?Boolean

Returns:

  • (Boolean)


18
19
20
# File 'lib/ffi-gobject_introspection/i_function_info.rb', line 18

def constructor?
  flags & 2 != 0
end

#flagsObject



9
10
11
# File 'lib/ffi-gobject_introspection/i_function_info.rb', line 9

def flags
  Lib.g_function_info_get_flags @gobj
end

#getter?Boolean

Returns:

  • (Boolean)


22
23
24
# File 'lib/ffi-gobject_introspection/i_function_info.rb', line 22

def getter?
  flags & 4 != 0
end

#method?Boolean

TODO: Use some sort of bitfield

Returns:

  • (Boolean)


14
15
16
# File 'lib/ffi-gobject_introspection/i_function_info.rb', line 14

def method?
  flags & 1 != 0
end

#setter?Boolean

Returns:

  • (Boolean)


26
27
28
# File 'lib/ffi-gobject_introspection/i_function_info.rb', line 26

def setter?
  flags & 8 != 0
end

#symbolObject



5
6
7
# File 'lib/ffi-gobject_introspection/i_function_info.rb', line 5

def symbol
  Lib.g_function_info_get_symbol @gobj
end

#throws?Boolean

Returns:

  • (Boolean)


34
35
36
# File 'lib/ffi-gobject_introspection/i_function_info.rb', line 34

def throws?
  flags & 32 != 0
end

#wraps_vfunc?Boolean

Returns:

  • (Boolean)


30
31
32
# File 'lib/ffi-gobject_introspection/i_function_info.rb', line 30

def wraps_vfunc?
  flags & 16 != 0
end