Class: Yaks::CollectionResource

Inherits:
Resource
  • Object
show all
Extended by:
Forwardable
Defined in:
lib/yaks/collection_resource.rb

Overview

A collection of Resource objects, it has members, and its own set of link relations like self and profile describing the collection.

A collection can be the top-level result of an API call, like all posts to a blog, or a subresource collection, like the comments on a post result.

Instance Method Summary collapse

Methods inherited from Resource

#[], #add_form, #add_link, #add_rel, #add_subresource, #find_form, #initialize, #members, #merge_attributes, #null_resource?, #self_link, #with_collection

Methods included from Util::Deprecated

#deprecated_alias

Constructor Details

This class inherits a constructor from Yaks::Resource

Instance Method Details

#collection?Boolean

Returns:

  • (Boolean)


15
16
17
# File 'lib/yaks/collection_resource.rb', line 15

def collection?
  true
end

#seqObject



19
20
21
# File 'lib/yaks/collection_resource.rb', line 19

def seq
  self
end