Sha256: d33efa15498070c608c0c68f96909fdf727ee0d49ad52732cbafc69244afa387

Contents?: true

Size: 473 Bytes

Versions: 7

Compression:

Stored size: 473 Bytes

Contents

# frozen_string_literal: true

module Excon
  module HyperMedia
    class ResourceObject
      # Links
      #
      # Represents a collection of links part of a resource.
      #
      class Embedded
        include Collection

        private

        def property(value)
          if value.respond_to?(:to_ary)
            value.map { |v| ResourceObject.new(v) }
          else
            ResourceObject.new(value)
          end
        end
      end
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
excon-hypermedia-0.7.0 lib/excon/hypermedia/resource_object/embedded.rb
excon-hypermedia-0.6.0 lib/excon/hypermedia/resource_object/embedded.rb
excon-hypermedia-0.5.3 lib/excon/hypermedia/resource_object/embedded.rb
excon-hypermedia-0.5.2 lib/excon/hypermedia/resource_object/embedded.rb
excon-hypermedia-0.5.1 lib/excon/hypermedia/resource_object/embedded.rb
excon-hypermedia-0.5.0 lib/excon/hypermedia/resource_object/embedded.rb
excon-hypermedia-0.4.3 lib/excon/hypermedia/resource_object/embedded.rb