How to retrieve public timeline statuses
In this example, we use three namespaces. The first, Dimebrain.TweetSharp.Fluent is the root namespace and allows you to build requests for Twitter, and handle their responses which come in the form of a string in JSON, XML, RSS, or Atom format. If that’s all you need, then you’re good to go.
Dimebrain.TweetSharp.Extensions lets you use convenience methods to turn responses you receive from Twitter into data classes, so that you can bind them to UI, persist them in a database, or even convert them back into their original formats. In this example, the public timeline is polled for new statuses, and the result string response is converted into TwitterStatus objects, classes you can use in your client applications.
This example also hints at a Configuration expression that allows you to cache responses you make to Twitter. This is helpful if you want to limit the traffic from your application to Twitter if you are polling the API at low intervals. You can configure a cache to use ASP.NET Web Cache, a simple dictionary, or build your own cache implementation to plug in and use, by implementing the IClientCache or IWebCache interfaces.
In this example, all queries made for the resource describe are cached locally for two minutes before expiring, causing the next request to reach Twitter for its data.




