Class: FlickRaw::ResponseList

Inherits:
Response
  • Object
show all
Includes:
Enumerable
Defined in:
lib/flickraw/response.rb

Instance Attribute Summary

Attributes inherited from Response

#flickr_type

Instance Method Summary collapse

Methods inherited from Response

build, #marshal_load, #to_hash, #to_s

Constructor Details

#initialize(h, t, a) ⇒ ResponseList

Returns a new instance of ResponseList.



39
# File 'lib/flickraw/response.rb', line 39

def initialize(h, t, a); super(h, t); @a = a end

Instance Method Details

#[](k) ⇒ Object



40
# File 'lib/flickraw/response.rb', line 40

def [](k); k.is_a?(Fixnum) ? @a[k] : super(k) end

#eachObject



41
# File 'lib/flickraw/response.rb', line 41

def each; @a.each{|e| yield e} end

#inspectObject



43
# File 'lib/flickraw/response.rb', line 43

def inspect; @a.inspect end

#marshal_dumpObject



45
# File 'lib/flickraw/response.rb', line 45

def marshal_dump; [@h, @flickr_type, @a] end

#sizeObject Also known as: length



44
# File 'lib/flickraw/response.rb', line 44

def size; @a.size end

#to_aObject



42
# File 'lib/flickraw/response.rb', line 42

def to_a; @a end