Class: EPIC::StaticCollection

Inherits:
Collection show all
Defined in:
src/epic_collection.rb

Constant Summary

Constant Summary

Constants inherited from Resource

Resource::GLOBAL_LOCK_HASH, Resource::GLOBAL_LOCK_MUTEX

Instance Attribute Summary

Attributes included from Rackful::Resource

#get_etag, #get_last_modified, #path

Instance Method Summary (collapse)

Methods inherited from Collection

#recurse?, #to_rackful, #xhtml

Methods inherited from Resource

#lock, lock, #unlock, #xhtml

Methods included from Rackful::Resource

#default_headers, #destroy, #do_METHOD, #empty?, #http_DELETE, #http_GET, #http_HEAD, #http_OPTIONS, #http_PUT, #http_method, #http_methods, included, #requested?, #serializer, #title, #to_rackful, #to_struct

Constructor Details

- (StaticCollection) initialize(path, uris)

A new instance of StaticCollection

Parameters:

  • path (Path)
  • uris (Enumerable<#to_s>)

    an array of URIs



98
99
100
101
# File 'src/epic_collection.rb', line 98

def initialize path, uris
  super path
  @uris = uris.collect { |uri| (path + uri.to_s).to_path }
end

Instance Method Details

- (void) each(&block)



103
# File 'src/epic_collection.rb', line 103

def each &block; @uris.each &block; end