Module: CanTango::Config::Engines::Available

Included in:
CanTango::Config::Engines
Defined in:
lib/cantango/config/engines/available.rb

Instance Method Summary collapse

Instance Method Details

#all(state) ⇒ Object



11
12
13
# File 'lib/cantango/config/engines/available.rb', line 11

def all state
  available.each {|engine| send(engine).set state }
end

#any?(state) ⇒ Boolean

Returns:

  • (Boolean)


15
16
17
# File 'lib/cantango/config/engines/available.rb', line 15

def any? state
  available.any? {|engine| send(engine).send(:"#{state}?") if respond_to?(engine) }
end

#availableObject



3
4
5
# File 'lib/cantango/config/engines/available.rb', line 3

def available
  registered_names
end

#available?(name) ⇒ Boolean

Returns:

  • (Boolean)


7
8
9
# File 'lib/cantango/config/engines/available.rb', line 7

def available? name
  available.include? name.to_s
end