Class: MultipleMan::RoutingKey
- Inherits:
-
Object
- Object
- MultipleMan::RoutingKey
- Defined in:
- lib/multiple_man/routing_key.rb
Constant Summary collapse
- ALLOWED_OPERATIONS =
[:create, :update, :destroy, :"#"]
Instance Attribute Summary collapse
-
#klass ⇒ Object
Returns the value of attribute klass.
-
#operation ⇒ Object
Returns the value of attribute operation.
Instance Method Summary collapse
-
#initialize(klass, operation = :"#") ⇒ RoutingKey
constructor
A new instance of RoutingKey.
- #to_s ⇒ Object
Constructor Details
#initialize(klass, operation = :"#") ⇒ RoutingKey
Returns a new instance of RoutingKey.
5 6 7 8 |
# File 'lib/multiple_man/routing_key.rb', line 5 def initialize(klass, operation = :"#") self.klass = klass self.operation = operation end |
Instance Attribute Details
#klass ⇒ Object
Returns the value of attribute klass.
15 16 17 |
# File 'lib/multiple_man/routing_key.rb', line 15 def klass @klass end |
#operation ⇒ Object
Returns the value of attribute operation.
14 15 16 |
# File 'lib/multiple_man/routing_key.rb', line 14 def operation @operation end |
Instance Method Details
#to_s ⇒ Object
10 11 12 |
# File 'lib/multiple_man/routing_key.rb', line 10 def to_s "#{topic_name}.#{klass}.#{operation}" end |