how about JSON source

Jun 15, 2012 at 6:59 AM

thank you guys for the great work you have done. I downloaded the template and is going to use it in my next app. The only problem is I'd like to aggregate some JSON format data source. 

Do you think you will add JSON support in the near future?

Jun 15, 2012 at 4:53 PM

Kuber,

The Social Viewer Template uses sourceUrls and Parsers to obtain data.  Depending on the source, it is retrieved from the sourceUrl and parsed by the Parser to create socialActivity objects which are consumed by the UI.  You then define the SocialType in the Configuration.xaml.

<Content:SocialType SocialTypeName="CustomJson"

ParserTypeName="$safeprojectname$.Parsers.ACustomJsonParser"

SourceUrlTypeName="$safeprojectname$.SourceUrls.CustomJsonSourceUrl"

Icon="/Images/customJson_logo.png" />

JSON formatted data is not always standardized unlike media-rss which is standardized and implemented in the template, so you will need to be mindful of this.  Check out the FacebookParser included in the template as it creates socialActivity objects from deserialized JSON.

That said, you should be able to write your own custom parser which can support a custom JSON formatted data source. 

 

Cheers,

Paul