Class: MultipleConnectionHandler::DbKey
- Inherits:
-
Object
- Object
- MultipleConnectionHandler::DbKey
- Defined in:
- lib/multiple_connection_handler.rb
Overview
just a little token class to hand to the ActiveRecord ConnectionHandler so we can piggy-back on its connection management infrastructure. it just requires an object that you can call .name on…though it’s sort of expecting a (model) class object…
Instance Attribute Summary collapse
-
#name ⇒ Object
Returns the value of attribute name.
Instance Method Summary collapse
- #==(other) ⇒ Object
-
#initialize(name) ⇒ DbKey
constructor
A new instance of DbKey.
Constructor Details
#initialize(name) ⇒ DbKey
Returns a new instance of DbKey.
33 34 35 |
# File 'lib/multiple_connection_handler.rb', line 33 def initialize(name) self.name = name end |
Instance Attribute Details
#name ⇒ Object
Returns the value of attribute name.
32 33 34 |
# File 'lib/multiple_connection_handler.rb', line 32 def name @name end |
Instance Method Details
#==(other) ⇒ Object
36 37 38 |
# File 'lib/multiple_connection_handler.rb', line 36 def ==(other) self.name == other.name end |