Packagecom.adobe.webapis.flickr.methodgroups
Classpublic class Favorites

Contains the methods for the Favorites method group in the Flickr API. Even though the events are listed here, they're really broadcast from the FlickrService instance itself to make using the service easier.



Public Methods
 MethodDefined by
  
Construct a new Contacts "method group" class
Favorites
  
add(photo_id:String):void
Adds a photo to a user's favorites list.
Favorites
  
getList(user_id:String = "", extras:String = "", per_page:Number = 100, page:Number = 1):void
Returns a list of the user's favorite photos.
Favorites
  
getPublicList(user_id:String, extras:String = "", per_page:Number = 100, page:Number = 1):void
Returns a list of favorite public photos for the given user.
Favorites
  
remove(photo_id:String):void
Removes a photo from a user's favorites list.
Favorites
Events
 EventSummaryDefined by
   Broadcast as a result of the add method being called The event contains the following properties success - Boolean indicating if the call was successful or not data - When success is true, an empty object When success is false, contains an "error" FlickrError instance Favorites
   Broadcast as a result of the getList method being called The event contains the following properties success - Boolean indicating if the call was successful or not data - When success is true, contains a "photos" PagedPhotoList instance When success is false, contains an "error" FlickrError instance Favorites
   Broadcast as a result of the getPublicList method being called The event contains the following properties success - Boolean indicating if the call was successful or not data - When success is true, contains a "photos" PagedPhotoList instance When success is false, contains an "error" FlickrError instance Favorites
   Broadcast as a result of the remove method being called The event contains the following properties success - Boolean indicating if the call was successful or not data - When success is true, an empty object When success is false, contains an "error" FlickrError instance Favorites
Constructor detail
Favorites()constructor
public function Favorites(service:FlickrService)

Construct a new Contacts "method group" class

Parameters
service:FlickrService — The FlickrService this method group is associated with.
Method detail
add()method
public function add(photo_id:String):void

Adds a photo to a user's favorites list. This method requires authentication with WRITE permission.

Parameters
photo_id:String — The id of the photo to add to the user's favorites

See also

getList()method 
public function getList(user_id:String = "", extras:String = "", per_page:Number = 100, page:Number = 1):void

Returns a list of the user's favorite photos. Only photos which the calling user has permission to see are returned. This method requires authentication with READ permission.

Parameters
user_id:String (default = "") — (Optional) The NSID of the user to fetch the favorites list for. If this argument is omitted, the favorites list for the calling user is returned.
 
extras:String (default = "") — (Optional) A comma-delimited list of extra information to fetch for each returned record. Currently supported fields are: license, date_upload, date_taken, owner_name, icon_server, original_format.
 
per_page:Number (default = 100) — (Optional) Number of photos to return per page. If this argument is omitted, it defaults to 100. The maximum allowed value is 500.
 
page:Number (default = 1) — (Optional) The page of results to return. If this argument is omitted it defaults to 1.

See also

getPublicList()method 
public function getPublicList(user_id:String, extras:String = "", per_page:Number = 100, page:Number = 1):void

Returns a list of favorite public photos for the given user.

Parameters
user_id:String — The user to fetch the favorites list for.
 
extras:String (default = "") — (Optional) A comma-delimited list of extra information to fetch for each returned record. Currently supported fields are: license, date_upload, date_taken, owner_name, icon_server, original_format.
 
per_page:Number (default = 100) — (Optional) Number of photos to return per page. If this argument is omitted, it defaults to 100. The maximum allowed value is 500.
 
page:Number (default = 1) — (Optional) The page of results to return. If this argument is omitted it defaults to 1.

See also

remove()method 
public function remove(photo_id:String):void

Removes a photo from a user's favorites list. This method requires authentication with WRITE permission.

Parameters
photo_id:String — The id of the photo to remove from the user's favorites.

See also

Event detail
favoritesAddevent 
Event object type: com.adobe.webapis.flickr.events.FlickrResultEvent

Broadcast as a result of the add method being called The event contains the following properties success - Boolean indicating if the call was successful or not data - When success is true, an empty object When success is false, contains an "error" FlickrError instance

See also

add
com.adobe.service.flickr.FlickrError
favoritesGetListevent  
Event object type: com.adobe.webapis.flickr.events.FlickrResultEvent

Broadcast as a result of the getList method being called The event contains the following properties success - Boolean indicating if the call was successful or not data - When success is true, contains a "photos" PagedPhotoList instance When success is false, contains an "error" FlickrError instance

See also

getList
com.adobe.service.flickr.FlickrError
favoritesGetPublicListevent  
Event object type: com.adobe.webapis.flickr.events.FlickrResultEvent

Broadcast as a result of the getPublicList method being called The event contains the following properties success - Boolean indicating if the call was successful or not data - When success is true, contains a "photos" PagedPhotoList instance When success is false, contains an "error" FlickrError instance

See also

getPublicList
com.adobe.service.flickr.FlickrError
favoritesRemoveevent  
Event object type: com.adobe.webapis.flickr.events.FlickrResultEvent

Broadcast as a result of the remove method being called The event contains the following properties success - Boolean indicating if the call was successful or not data - When success is true, an empty object When success is false, contains an "error" FlickrError instance

See also

remove
com.adobe.service.flickr.FlickrError