Sha256: 75071c2005508a7603fa9e93308599aab003d648b8cde705d1b4343a58df94ba

Contents?: true

Size: 309 Bytes

Versions: 1

Compression:

Stored size: 309 Bytes

Contents

module MiniCamel
  module Processor
    class WrapInDto < Base

      values do
        attribute :field, Symbol
        attribute :as, Symbol
      end

      def call(exchange)
        exchange.update_context(as => MiniCamel::Dto.new(field => exchange.context_fetch(field)))
      end

    end
  end
end



Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
mini_camel-0.5.8 lib/mini_camel/processor/wrap_in_dto.rb