JavaFX – WebServices
April 14, 2009 13 Comments
The InputStream obtained from HttpRequest can be parsed using PullParser API. It can parse both XML and JSON data type.
Now we can utilize these APIs to enhance the existing Image Viewer sample so as to retrieve the photos dynamically from Flickr. Source code for PhotoPullParser.fx and Photo.fx are copied directly from InterestingPhotos sample.
For Applet mode, click on above image
There are many samples at JavaFX Samples website which uses HttpRequest and PullParser APIs. You can refer to those source code for more information.
- InterestingPhotos – Load photos from Flickr
- LocalSearch – Yahoo LocalSearch APIs
- ShoppingService – Yahoo Shopping-Service APIs
- PhotoFlockr – Search and load photos from Flickr
- RSSViewer – Loads well formatted RSS feedb
- WeatherWidget – Yahoo Weather RSS feed