Sha256: 65fffc722ce3594a48d9522ef39ad46b7d4879c4a27185bb861b4f9d550494a7

Contents?: true

Size: 369 Bytes

Versions: 2

Compression:

Stored size: 369 Bytes

Contents

require 'thanos/resources/character'
require 'thanos/mappers/character_data_mapper'

module Thanos
  module Factory
    class Character
      def initialize(results)
        @results = results
      end

      def build
        attributes = Thanos::CharacterDataMapper.new(@results).map
        Thanos::Character.new(attributes: attributes)
      end
    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
thanos-0.6.0 lib/thanos/factories/character.rb
thanos-0.5.0 lib/thanos/factories/character.rb