### Home Classes Methods

### In Files

- lib/ffi/tools/generator_task.rb

### Parent

Rake::TaskLib

### Methods

- ::new

### Files

- History.txt
- README.rdoc

### Class/Module Index

Quicksearch

- FFI
- FFI::AutoPointer
- FFI::AutoPointer::CallableReleaser
- FFI::AutoPointer::DefaultReleaser
- FFI::AutoPointer::Releaser
- FFI::ConstGenerator
- FFI::ConstGenerator::Constant
- FFI::Enum
- FFI::Enums
- FFI::Generator
- FFI::Generator::Task
- FFI::IO
- FFI::Library
- FFI::ManagedStruct
- FFI::NotFoundError
- FFI::Platform
- FFI::PlatformError
- FFI::Pointer
- FFI::StrPtrConverter
- FFI::Struct
- FFI::Struct::ManagedStructConverter
- FFI::StructGenerator
- FFI::StructGenerator::Field
- FFI::StructLayout
- FFI::StructLayout::Enum
- FFI::StructLayout::InnerStruct
- FFI::StructLayout::Mapped
- FFI::StructLayoutBuilder
- FFI::TypesGenerator
- FFI::Union
- FFI::VariadicInvoker

No matching classes.

# FFI::Generator::Task

Rake task that calculates C structs for FFI::Struct.

### Public Class Methods

new(rb_names) click to toggle source

    # File lib/ffi/tools/generator_task.rb, line 21
    def initialize(rb_names)
      task :clean do rm_f rb_names end

      rb_names.each do |rb_name|
        ffi_name = "#{rb_name}.ffi"

        file rb_name => ffi_name do |t|
          puts "Generating #{rb_name}..." if Rake.application.options.trace

          FFI::Generator.new ffi_name, rb_name
        end
      end
    end

[Validate]

Generated with the Darkfish Rdoc Generator 2.