Class: Flickr::Api::Photo
Instance Method Summary
collapse
-
#add_tags(photo_id, tags, params = {}) ⇒ response
-
#delete(photo_id, params = {}) ⇒ response
-
#get_exif(photo_id, params = {}) ⇒ Flickr::Object::Photo
-
#get_favorites(photo_id, params = {}) ⇒ Flickr::Object::List<Flickr::Object::Person>
-
#get_from_contacts(params = {}) ⇒ Flickr::Object::List<Flickr::Object::Photo>
-
#get_info(photo_id, params = {}) ⇒ Flickr::Object::Photo
-
#get_interesting(params = {}) ⇒ Flickr::Object::List<Flickr::Object::Photo>
-
#get_not_in_set(params = {}) ⇒ Flickr::Object::List<Flickr::Object::Photo>
-
#get_recent(params = {}) ⇒ Flickr::Object::List<Flickr::Object::Photo>
-
#get_recently_updated(params = {}) ⇒ Flickr::Object::List<Flickr::Object::Photo>
-
#get_sizes(photo_id, params = {}) ⇒ Flickr::Object::Photo
-
#get_untagged(params = {}) ⇒ Flickr::Object::List<Flickr::Object::Photo>
-
#get_with_geo_data(params = {}) ⇒ Flickr::Object::List<Flickr::Object::Photo>
-
#get_without_geo_data(params = {}) ⇒ Flickr::Object::List<Flickr::Object::Photo>
-
#remove_tag(photo_id, tag_id, params = {}) ⇒ response
-
#search(params = {}) ⇒ Flickr::Object::List<Flickr::Object::Photo>
-
#set_content_type(photo_id, content_type, params = {}) ⇒ response
-
#set_dates(photo_id, params = {}) ⇒ response
-
#set_license(photo_id, license_id, params = {}) ⇒ response
-
#set_meta(photo_id, params = {}) ⇒ response
-
#set_permissions(photo_id, params = {}) ⇒ response
-
#set_safety_level(photo_id, params = {}) ⇒ response
-
#set_tags(photo_id, tags, params = {}) ⇒ response
Methods inherited from Abstract
#find, #initialize, object_class
#autoload_dir, #autoload_names
Instance Method Details
189
190
191
|
# File 'lib/flickr/api/photo.rb', line 189
def add_tags(photo_id, tags, params = {})
post "photos.addTags", params.merge(photo_id: photo_id, tags: tags)
end
|
#delete(photo_id, params = {}) ⇒ response
159
160
161
|
# File 'lib/flickr/api/photo.rb', line 159
def delete(photo_id, params = {})
post "photos.delete", params.merge(photo_id: photo_id)
end
|
139
140
141
142
|
# File 'lib/flickr/api/photo.rb', line 139
def get_exif(photo_id, params = {})
response = get "photos.getExif", params.merge(photo_id: photo_id)
new_object(:Photo, response["photo"])
end
|
149
150
151
152
|
# File 'lib/flickr/api/photo.rb', line 149
def get_favorites(photo_id, params = {})
response = get "photos.getFavorites", params.merge(photo_id: photo_id)
new_list(:Person, response["photo"]["person"], response["photo"])
end
|
25
26
27
28
|
# File 'lib/flickr/api/photo.rb', line 25
def get_from_contacts(params = {})
response = get "photos.getContactsPhotos", params
new_list(:Photo, response["photos"]["photo"], response["photos"])
end
|
119
120
121
122
|
# File 'lib/flickr/api/photo.rb', line 119
def get_info(photo_id, params = {})
response = get "photos.getInfo", params.merge(photo_id: photo_id)
new_object(:Photo, response["photo"])
end
|
61
62
63
64
|
# File 'lib/flickr/api/photo.rb', line 61
def get_interesting(params = {})
response = get "interestingness.getList", params
new_list(:Photo, response["photos"]["photo"], response["photos"])
end
|
37
38
39
40
|
# File 'lib/flickr/api/photo.rb', line 37
def get_not_in_set(params = {})
response = get "photos.getNotInSet", params
new_list(:Photo, response["photos"]["photo"], response["photos"])
end
|
49
50
51
52
|
# File 'lib/flickr/api/photo.rb', line 49
def get_recent(params = {})
response = get "photos.getRecent", params
new_list(:Photo, response["photos"]["photo"], response["photos"])
end
|
109
110
111
112
|
# File 'lib/flickr/api/photo.rb', line 109
def get_recently_updated(params = {})
response = get "photos.recentlyUpdated", params
new_list(:Photo, response["photos"]["photo"], response["photos"])
end
|
129
130
131
132
|
# File 'lib/flickr/api/photo.rb', line 129
def get_sizes(photo_id, params = {})
response = get "photos.getSizes", params.merge(photo_id: photo_id)
new_object(:Photo, response)
end
|
73
74
75
76
|
# File 'lib/flickr/api/photo.rb', line 73
def get_untagged(params = {})
response = get "photos.getUntagged", params
new_list(:Photo, response["photos"]["photo"], response["photos"])
end
|
85
86
87
88
|
# File 'lib/flickr/api/photo.rb', line 85
def get_with_geo_data(params = {})
response = get "photos.getWithGeoData", params
new_list(:Photo, response["photos"]["photo"], response["photos"])
end
|
97
98
99
100
|
# File 'lib/flickr/api/photo.rb', line 97
def get_without_geo_data(params = {})
response = get "photos.getWithoutGeoData", params
new_list(:Photo, response["photos"]["photo"], response["photos"])
end
|
#remove_tag(photo_id, tag_id, params = {}) ⇒ response
199
200
201
|
# File 'lib/flickr/api/photo.rb', line 199
def remove_tag(photo_id, tag_id, params = {})
post "photos.removeTag", params.merge(photo_id: photo_id, tag_id: tag_id)
end
|
13
14
15
16
|
# File 'lib/flickr/api/photo.rb', line 13
def search(params = {})
response = get "photos.search", params
new_list(:Photo, response["photos"]["photo"], response["photos"])
end
|
#set_content_type(photo_id, content_type, params = {}) ⇒ response
169
170
171
|
# File 'lib/flickr/api/photo.rb', line 169
def set_content_type(photo_id, content_type, params = {})
post "photos.setContentType", params.merge(photo_id: photo_id, content_type: content_type)
end
|
#set_dates(photo_id, params = {}) ⇒ response
209
210
211
|
# File 'lib/flickr/api/photo.rb', line 209
def set_dates(photo_id, params = {})
post "photos.setDates", params.merge(photo_id: photo_id)
end
|
#set_license(photo_id, license_id, params = {}) ⇒ response
248
249
250
|
# File 'lib/flickr/api/photo.rb', line 248
def set_license(photo_id, license_id, params = {})
post "photos.licenses.setLicense", params.merge(photo_id: photo_id, license_id: license_id)
end
|
219
220
221
|
# File 'lib/flickr/api/photo.rb', line 219
def set_meta(photo_id, params = {})
post "photos.setMeta", params.merge(photo_id: photo_id)
end
|
#set_permissions(photo_id, params = {}) ⇒ response
229
230
231
|
# File 'lib/flickr/api/photo.rb', line 229
def set_permissions(photo_id, params = {})
post "photos.setPerms", params.merge(photo_id: photo_id)
end
|
#set_safety_level(photo_id, params = {}) ⇒ response
239
240
241
|
# File 'lib/flickr/api/photo.rb', line 239
def set_safety_level(photo_id, params = {})
post "photos.setSafetyLevel", params.merge(photo_id: photo_id)
end
|
179
180
181
|
# File 'lib/flickr/api/photo.rb', line 179
def set_tags(photo_id, tags, params = {})
post "photos.setTags", params.merge(photo_id: photo_id, tags: tags)
end
|