Sha256: 66afb7d251cca0663fb846be661b99422ead640f0089eab4cbc0ccc2d79aea0c

Contents?: true

Size: 579 Bytes

Versions: 3

Compression:

Stored size: 579 Bytes

Contents

# frozen_string_literal: true
require 'gir_ffi/builders/boxed_builder'

module GirFFI
  module Builders
    # Implements the creation of a class representing a boxed type for
    # which no data is found in the GIR.
    class UnintrospectableBoxedBuilder < BoxedBuilder
      def klass
        @klass ||= TypeBuilder::CACHE[target_gtype] ||= Class.new(superclass)
      end

      def setup_class
        setup_layout
        setup_constants
      end

      def superclass
        BoxedBase
      end

      def layout_superclass
        FFI::Struct
      end
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
gir_ffi-0.9.5 lib/gir_ffi/builders/unintrospectable_boxed_builder.rb
gir_ffi-0.9.4 lib/gir_ffi/builders/unintrospectable_boxed_builder.rb
gir_ffi-0.9.3 lib/gir_ffi/builders/unintrospectable_boxed_builder.rb