Athena (1.4)

Rating: No reviews yet
Downloads: 2058
Released: Jul 29, 2008
Updated: Jan 6, 2009 by mehfuzh
Dev status: Beta Help Icon

Recommended Download

Source Code LINQ.Flickr.Src
source code, 1260K, uploaded Jan 6, 2009 - 1593 downloads

Other Available Downloads

Application LINQ.Flickr.Lib
application, 43K, uploaded Jan 4, 2009 - 465 downloads

Release Notes

This release contains new features, updates, fixes and development enhancements. Also, this is the first release over project naming to Athena.

Newly covered
1. flickr.photos.setMeta, through photo update.
2. flickr.photos.comments.edit for comment update.

For example , lets update the photo title.
Photo photo= (from p in context.Photots
where p.id == 123
select p).Single();

photo.Title = This is new Title.

// to make the update just do the following
coment.SubmitChanges();

//This will fire the Update in LinqExtender where logic for flickr.photos.setMeta is written.
//Flickr api support only alteration of Title and Description, more info can be found at flickr.photos.setMeta



Similarly, you can update comment like

Comment comment = (from c in context.Photots.Comments
where c.Id == "1234"
select c).Single();

comment.Text = "This is a updated comment.";
coment.SubmitChanges();



New Query Option that can be used with Search in the where clause

Photo.ExtrasOption
/// A comma-delimited list of extra information to fetch for each returned record.
/// Currently supported fields are: license, dateupload, datetaken, ownername, iconserver,
/// originalformat, lastupdate, geo, tags, machine_tags, views, media.
/// Use ExtrasOption enum with | to set your options. Ex
/// p.Extras == (ExtrasOption.Views | ExtrasOption.DateTaken | ExtrasOption.DateUpload)

Photo.SafeSearch

/// Options are Safe, Moderate and Restricted.

Photo.WebUrl
/// Contains the URL for the photo page at flickr.

Different ways for authenticating users. For gettting the photos from my stream i would do

  var query = from photo in context.Photos
              where photo.ViewMode = ViewMode.Owner && photos.Extras == (ExtrasOption.Date_Posted | ExtrasOptions.Views)
              select photo;



This will automatically fire a the authentication process

Or before doing it i can manually call.

context.Authenticate(); 


After authentication process successive call will return AuthToken { ID, Perm, UserId}

Similarly, i can clear token by

context.ClearToken();



Few fixes
Fixed UploadedOn, TakenOn and PostedOn invalid date for photos and comments,
Fixed Token creation problem for IE7


Development
Added Single click build script though build.bat (cook your own build with a single click) which is
provided in the src. It fires up NAant build files that builds the API and does a unit test.
NAant and Nunit stripped down version is bundled with the src in the ThridParty folder.

Note : Added New version of Typemock which is 5. To cook a assembly using the build script you dont need to install anything, but you can get a open source version to run it in VS.

Refactor
Replaced SortedDictionary with LINQ orderby for orderby used for photos.
LINQ orderby looks nicer over SortedDictionary , take a look at my blog at http://weblogs.asp.net/mefhuzh
Refactored Respository . Ex. removed unecessary ToList for LINQ queries and added RestTocolleciton Builder for buidling object from REST response.

Distribution updated on 1st August, 2008
Check out the readme in the distribution for more

Updated on Oct 3, 2008
  • If no oderby is specificed in search query, the default sort will be by relevance.
  • Updated the readme in Linq.Flickr.Lib for uploading photos.

Updated on Oct 16, 2008
  • Fix : Authentication token save error for desktop based app due to recent changes.

Updated on 4th Jan 2009
Get photos directly by NSID

var query = from photo in _context.Photos
where photo.NsId == 'user's nsId'
select photo;


Reviews for this release

No reviews yet for this release.