Sha256: f3939b968dfb7059b99d77ea0fc5d327cb195b8aba16d7508b252df02799d14f

Contents?: true

Size: 327 Bytes

Versions: 6

Compression:

Stored size: 327 Bytes

Contents

module GObjectIntrospection
  # Wraps GLib's GError struct.
  class GError
    class Struct < FFI::Struct
      layout :domain, :uint32,
        :code, :int,
        :message, :string
    end

    def initialize ptr
      @struct = self.class::Struct.new(ptr)
    end

    def message
      @struct[:message]
    end
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
gir_ffi-0.5.2 lib/ffi-gobject_introspection/g_error.rb
gir_ffi-0.5.1 lib/ffi-gobject_introspection/g_error.rb
gir_ffi-0.5.0 lib/ffi-gobject_introspection/g_error.rb
gir_ffi-0.4.3 lib/ffi-gobject_introspection/g_error.rb
gir_ffi-0.4.2 lib/ffi-gobject_introspection/g_error.rb
gir_ffi-0.4.1 lib/ffi-gobject_introspection/g_error.rb