Sha256: 34f6b3a5d5d644d26b9a87ac5b67ece8d407d438423d5aced69b154f29fb907c

Contents?: true

Size: 401 Bytes

Versions: 3

Compression:

Stored size: 401 Bytes

Contents

# frozen_string_literal: true

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

        private def property(value)
          value.respond_to?(:to_ary) ? value.map { |v| LinkObject.new(v) } : LinkObject.new(value)
        end
      end
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
excon-hypermedia-0.4.2 lib/excon/hypermedia/resource_object/links.rb
excon-hypermedia-0.4.1 lib/excon/hypermedia/resource_object/links.rb
excon-hypermedia-0.4.0 lib/excon/hypermedia/resource_object/links.rb