Class: BunnyMock::Exchanges::Header
- Inherits:
-
BunnyMock::Exchange
- Object
- BunnyMock::Exchange
- BunnyMock::Exchanges::Header
- Defined in:
- lib/bunny_mock/exchanges/headers.rb
Instance Attribute Summary
Attributes inherited from BunnyMock::Exchange
#arguments, #auto_delete, #channel, #durable, #internal, #name, #opts, #type
Instance Method Summary collapse
-
#deliver(payload, opts, key) ⇒ Object
Deliver a message to routes with header matches.
Methods inherited from BunnyMock::Exchange
#bind, #bound_to?, declare, #delete, #has_binding?, #publish, #routes_to?, #unbind
Instance Method Details
#deliver(payload, opts, key) ⇒ Object
Deliver a message to routes with header matches
26 27 28 29 |
# File 'lib/bunny_mock/exchanges/headers.rb', line 26 def deliver(payload, opts, key) # ~: proper headers exchange implementation @routes[key].each { |route| route.publish payload, opts } if @routes[key] end |