class Superbolt::Connection::Base

Attributes

config[R]
name[R]

Public Class Methods

default_options() click to toggle source
# File lib/superbolt/connection/base.rb, line 30
def self.default_options
  {
    :auto_delete => false,
    :durable => true,
    :exclusive => false
  }
end
new(name, config=nil) click to toggle source
# File lib/superbolt/connection/base.rb, line 6
def initialize(name, config=nil)
  @name = name
  @config = config || Superbolt.config
end

Public Instance Methods

channel() click to toggle source
# File lib/superbolt/connection/base.rb, line 26
def channel
  connection.channel
end
close() click to toggle source
# File lib/superbolt/connection/base.rb, line 15
def close
  raise NotImplementedError
end
connection() click to toggle source
# File lib/superbolt/connection/base.rb, line 11
def connection
  raise NotImplementedError
end
q() click to toggle source
# File lib/superbolt/connection/base.rb, line 19
def q
  @q ||= connection.queue(name, self.class.default_options)
end