module Teamster module Adapters module BaseAdapter def self.included(base) base.extend ClassMethods end module ClassMethods def register(klass, name) Teamster::Core::App.use_adapter klass, name end def has_helpers(*adapters) if adapters.size > 0 instance_eval "def has_helper?; true end" instance_eval "def helper_adapter; #{adapters} end" adapters.flatten.each {|adapter| helpers adapter } end end def has_helper? false end def under_development instance_eval "def under_development?; true end" end def under_development? false end def views_at(folder) instance_eval "def views; \"#{folder}\" end" end end end end end