module SandthornDriverSequel

Constants

VERSION

Public Class Methods

configuration() click to toggle source
# File lib/sandthorn_driver_sequel.rb, line 53
def configuration
  @configuration ||= Configuration.new
end
configure() { |configuration| ... } click to toggle source
# File lib/sandthorn_driver_sequel.rb, line 49
def configure
  yield(configuration) if block_given?
end
driver_from_connection(connection: nil, context: nil) { |configuration| ... } click to toggle source
# File lib/sandthorn_driver_sequel.rb, line 39
def driver_from_connection connection: nil, context: nil
  if block_given?
    configuration = Configuration.new
    yield(configuration)
  else
    configuration = self.configuration
  end
  EventStore.new(SequelDriver.new(connection: connection), configuration, context)
end
driver_from_url(url: nil, context: nil) { |configuration| ... } click to toggle source
# File lib/sandthorn_driver_sequel.rb, line 27
def driver_from_url url: nil, context: nil

  if block_given?
    configuration = Configuration.new
    yield(configuration)
  else
    configuration = self.configuration
  end

  EventStore.from_url(url, configuration, context)
end
migrate_connection(connection: nil, context: nil) click to toggle source
# File lib/sandthorn_driver_sequel.rb, line 23
def migrate_connection connection: nil, context: nil
  Migration.new(connection: connection, context: context).migrate!
end
migrate_db(url: nil, context: nil) click to toggle source
# File lib/sandthorn_driver_sequel.rb, line 14
def migrate_db url: nil, context: nil
  migrator = Migration.new url: url, context: context
  migrator.migrate!
end
migrate_url(url: nil, context: nil) click to toggle source
# File lib/sandthorn_driver_sequel.rb, line 19
def migrate_url url: nil, context: nil
  Migration.new(url: url, context: context).migrate!
end