@Override
public void encodeEnd(FacesContext context, UIComponent component) throws IOException {
if (component.isRendered()) {
ResponseWriter writer = context.getResponseWriter();
YahooWeather yahooWeather = (YahooWeather) component;
String locationCode = yahooWeather.getLocationCode();
String temperatureType = yahooWeather.getTemperatureType();
List<ServiceParameter> parameters = new ArrayList<ServiceParameter>();
YahooWeatherService yahooWeatherService = YahooServicesFactory.getYahooWeatherService();
parameters.add(new ServiceParameter(YahooWeatherServiceParameters.ZIP_CODE, locationCode));
parameters.add(new ServiceParameter(YahooWeatherServiceParameters.TEMPERATURE_TYPE, temperatureType));