Sha256: f1a69ac21937a5585995397351904c5cf1d48d6d8a749090a3226ca4bb83eff6
Contents?: true
Size: 631 Bytes
Versions: 5
Compression:
Stored size: 631 Bytes
Contents
module Smirk class Album < Client def initialize(session_id, info) info.each do |key, value| instance_variable_set("@#{key}", value) Album.instance_eval do attr_reader key.to_sym end end @session_id = session_id end def images(heavy = false) params = default_params.merge!({:method => "smugmug.images.get", :AlbumID => id, :AlbumKey => key, :Heavy => heavy}) json = get(params)["Album"]["Images"] json.inject([]) do |images, i| images << Smirk::Image.new(@session_id, upper_hash_to_lower_hash(i)) end end end end
Version data entries
5 entries across 5 versions & 1 rubygems
Version | Path |
---|---|
smirk-0.2.1 | lib/smirk/album.rb |
smirk-0.1.0 | lib/smirk/album.rb |
smirk-0.0.9 | lib/smirk/album.rb |
smirk-0.0.8 | lib/smirk/album.rb |
smirk-0.0.7 | lib/smirk/album.rb |