Sha256: 977d0bcd6d9ab0c42964a7f1947e5689b7d644f56748b5472a17a77774ab6847
Contents?: true
Size: 723 Bytes
Versions: 3
Compression:
Stored size: 723 Bytes
Contents
# frozen_string_literal: true module CottonTail # Value object wrapper for Bunny Message class Request extend Forwardable attr_reader :delivery_info, :properties, :payload def initialize(delivery_info, properties, payload) @delivery_info = delivery_info @properties = properties @payload = payload end def to_a [delivery_info, properties, payload] end def to_h { delivery_info: delivery_info, properties: properties, payload: payload } end def ==(other) to_h == other.to_h end def_delegators :delivery_info, :routing_key, :delivery_tag, :channel def_delegators :properties, :route_params end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
cotton-tail-0.7.0 | lib/cotton_tail/request.rb |
cotton-tail-0.6.1 | lib/cotton_tail/request.rb |
cotton-tail-0.6.0 | lib/cotton_tail/request.rb |