module Reactor

Runtime Rails version detection

require 'infopark_rails_connector'

-*- encoding : utf-8 -*-

Constants

VERSION

Public Class Methods

rails3_0?() click to toggle source
# File lib/infopark_reactor.rb, line 3
def self.rails3_0?
  ::Rails::VERSION::MAJOR == 3 && ::Rails::VERSION::MINOR == 0
end
rails3_1?() click to toggle source
# File lib/infopark_reactor.rb, line 7
def self.rails3_1?
  ::Rails::VERSION::MAJOR == 3 && ::Rails::VERSION::MINOR == 1
end
rails3_2?() click to toggle source
# File lib/infopark_reactor.rb, line 11
def self.rails3_2?
  ::Rails::VERSION::MAJOR == 3 && ::Rails::VERSION::MINOR == 2
end
rails4_0?() click to toggle source
# File lib/infopark_reactor.rb, line 15
def self.rails4_0?
  ::Rails::VERSION::MAJOR == 4 && ::Rails::VERSION::MINOR == 0
end
rails4_0_ge6?() click to toggle source
# File lib/infopark_reactor.rb, line 31
def self.rails4_0_ge6?
  ::Rails::VERSION::MAJOR == 4 && ::Rails::VERSION::MINOR == 0 && ::Rails::VERSION::TINY >= 6
end
rails4_1?() click to toggle source
# File lib/infopark_reactor.rb, line 19
def self.rails4_1?
  ::Rails::VERSION::MAJOR == 4 && ::Rails::VERSION::MINOR == 1
end
rails4_2?() click to toggle source
# File lib/infopark_reactor.rb, line 23
def self.rails4_2?
  ::Rails::VERSION::MAJOR == 4 && ::Rails::VERSION::MINOR == 2
end
rails4_x?() click to toggle source
# File lib/infopark_reactor.rb, line 27
def self.rails4_x?
  ::Rails::VERSION::MAJOR == 4 && [0,1,2].include?(::Rails::VERSION::MINOR)
end