Class: Twitter::ProfileBanner

Inherits:
Base
  • Object
show all
Defined in:
lib/twitter/profile_banner.rb

Instance Method Summary collapse

Methods inherited from Base

#[], #attr_equal, attr_reader, #attrs, #attrs_equal, fetch, fetch_or_new, from_response, identity_map, #initialize, store, #update

Constructor Details

This class inherits a constructor from Twitter::Base

Instance Method Details

#sizesArray<Twitter::Size>

Returns an array of photo sizes

Returns:



9
10
11
12
13
14
# File 'lib/twitter/profile_banner.rb', line 9

def sizes
  @sizes ||= Array(@attrs[:sizes]).inject({}) do |object, (key, value)|
    object[key] = Twitter::Size.fetch_or_new(value)
    object
  end
end