Method: ContentData::ContentData#each_content
- Defined in:
- lib/content_data/content_data.rb
#each_content(&block) ⇒ Object
iterator over @contents_info data structure (not including instances) block is provided with: checksum, size and content modification time
88 89 90 91 92 93 94 95 96 |
# File 'lib/content_data/content_data.rb', line 88 def each_content(&block) contents_enum = @contents_info.each_key loop { checksum = contents_enum.next rescue break content_val = @contents_info[checksum] # provide checksum, size and content modification time to the block block.call(checksum,content_val[0], content_val[2]) } end |