Sha256: 757de81bf6df783eb214dbb10b059ca197be04a5849dd082677fb98e9c83dba9

Contents?: true

Size: 415 Bytes

Versions: 2

Compression:

Stored size: 415 Bytes

Contents

require 'rubygems'
require 'active_record'
require 'postgres_upsert/writer'
require 'postgres_upsert/table_writer'
require 'postgres_upsert/result'
require 'rails'

module PostgresUpsert

  class << self
    def write class_or_table, path_or_io, options = {}
      writer = class_or_table.is_a?(String) ?  
         TableWriter : Writer
      writer.new(class_or_table, path_or_io, options).write
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
postgres_upsert-5.0.0 lib/postgres_upsert.rb
postgres_upsert-4.0.0 lib/postgres_upsert.rb