Sha256: eadb741ef13ed963830d66505da3840f5c6760b78805ab5bbfa01735dcb8eba1

Contents?: true

Size: 307 Bytes

Versions: 3

Compression:

Stored size: 307 Bytes

Contents

module GdatastoreMapper
  module Persistence
    module ClassMethods

      def create params
        record = self.new params
        record.save
        record
      end

      def delete_all
        self.each do |resource|
          resource.destroy
        end
        true
      end

    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
gdatastore_mapper-0.1.8 lib/gdatastore_mapper/persistence/class_methods.rb
gdatastore_mapper-0.1.7 lib/gdatastore_mapper/persistence/class_methods.rb
gdatastore_mapper-0.1.6 lib/gdatastore_mapper/persistence/class_methods.rb