Sha256: f08a03ce5f529e351a471d84332597e41559bec544020d31978cc3b7d0675295

Contents?: true

Size: 679 Bytes

Versions: 2

Compression:

Stored size: 679 Bytes

Contents

require 'flight/carbon_model'
require 'flight/characterization'
require 'flight/data'
require 'flight/summarization'

module BrighterPlanet
  module Flight
    extend self

    def included(base)
      base.send :include, BrighterPlanet::Flight::CarbonModel
      base.send :include, BrighterPlanet::Flight::Characterization
#      base.send :include, BrighterPlanet::Flight::Data
      base.send :include, BrighterPlanet::Flight::Summarization
    end
    def flight_model
      if Object.const_defined? 'Flight'
        Flight
      elsif Object.const_defined? 'FlightRecord'
        FlightRecord
      else
        raise 'There is no flight model'
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
flight-0.0.5 lib/flight.rb
flight-0.0.4 lib/flight.rb