Module: Purview::Mixins::Connection

Included in:
Databases::Base, Pullers::BaseSQL
Defined in:
lib/purview/mixins/connection.rb

Instance Method Summary collapse

Instance Method Details

#connectObject



4
5
6
# File 'lib/purview/mixins/connection.rb', line 4

def connect
  connection_type.new(connection_opts)
end

#with_new_connectionObject



8
9
10
# File 'lib/purview/mixins/connection.rb', line 8

def with_new_connection
  connection_type.with_new_connection(connection_opts) { |connection| yield connection }
end