lib/activerecord-tableless.rb
# A model that needs to be tableless will call this method to indicate
# it.
A model that needs to be tableless will call this method to indicate
it.
A model that needs to be tableless will call this method to indicate it .
def has_no_table(options = {:database => :fail_fast})
        raise ArgumentError.new("Invalid database option '#{options[:database]}'") unless [:fail_fast, :pretend_success].member? options[:database]
        class_attribute :tableless_options
        self.tableless_options = {
          :database => options[:database],
          :columns_hash => {}
        }
        extend  ActiveRecord::Tableless::SingletonMethods
        extend  ActiveRecord::Tableless::ClassMethods
        include ActiveRecord::Tableless::InstanceMethods
        include ActiveModel::AttributeAssignment
        include ActiveRecord::ModelSchema
      end
def has_no_table ( options = { :database => :fail_fast } ) raise ArgumentError . new ( "Invalid database option '#{options[:database]}'" ) unless [ :fail_fast , :pretend_success ] . member? options [ :database ] class_attribute :tableless_options self . tableless_options = { :database => options [ :database ] , :columns_hash => { } } extend ActiveRecord :: Tableless :: SingletonMethods extend ActiveRecord :: Tableless :: ClassMethods include ActiveRecord :: Tableless :: InstanceMethods include ActiveModel :: AttributeAssignment include ActiveRecord :: ModelSchema end
A model that needs to be tableless will call this method to indicate
it.
A model that needs to be tableless will call this method to indicate it .
# keep our options handy # extend # include # setup columns
options