Class: GirFFI::Builder::ErrorArgument

Inherits:
Argument::Base show all
Defined in:
lib/gir_ffi/builder/argument.rb

Overview

Implements argument processing for error handling arguments. These arguments are not part of the introspected signature, but their presence is indicated by the ‘throws’ attribute of the function.

Constant Summary

Constants inherited from Argument::Base

Argument::Base::KEYWORDS, Argument::Base::TAG_TO_WRAPPER_CLASS_MAP

Instance Attribute Summary

Attributes inherited from Argument::Base

#array_arg, #length_arg, #name, #retname

Instance Method Summary collapse

Methods inherited from Argument::Base

#argument_class_name, #array_size, #callarg, #cleanup, #elm_t, #inarg, #initialize, #postpost, #retval, #safe, #subtype_tag_or_class_name, #type_info, #type_tag

Constructor Details

This class inherits a constructor from GirFFI::Builder::Argument::Base

Instance Method Details

#postObject



522
523
524
# File 'lib/gir_ffi/builder/argument.rb', line 522

def post
  [ "GirFFI::ArgHelper.check_error(#{callarg})" ]
end

#preObject



518
519
520
# File 'lib/gir_ffi/builder/argument.rb', line 518

def pre
  [ "#{callarg} = FFI::MemoryPointer.new(:pointer).write_pointer nil" ]
end