Q:

Find weather using Java

I was wondering if there is a way to find the weather of specific town/city using Java. I have heard of Google Weather API but that has not yielded any results. I also have heard about using an .xml feed for finding the weather but where can I find that? Therefore, I have two questions, Is there a way to find the weather to find using Java and am I correct about the .xml?

A:

The Google Weather API appears to be no more:
http://thenextweb.com/google/2012/08/28/did-google-just-quietly-kill-private-weather-api/
But you can use others such as
http://www.wunderground.com/weather/api/
Once you have your XML (or JSON) you can parse it as described here:
Using Java to extract data from google Weather API

A:

you can use openweathermap api for this.
Go to this link and download api and you can also see some examples to use it
http://openweathermap.org/api

