WeatherSet.java :  » Widget » weatherforestwidget » com » anydata » android » weatherforecast » weather » Android Open Source

Android Open Source » Widget » weatherforestwidget 
weatherforestwidget » com » anydata » android » weatherforecast » weather » WeatherSet.java
package com.anydata.android.weatherforecast.weather;

import java.util.ArrayList;

/**
 * Combines one WeatherCurrentCondition with a List of
 * WeatherForecastConditions.
 */
public class WeatherSet {
  
  // ===========================================================
  // Fields
  // ===========================================================

  private WeatherCurrentCondition myCurrentCondition = null;
  private ArrayList<WeatherForecastCondition> myForecastConditions = 
    new ArrayList<WeatherForecastCondition>(4);

  // ===========================================================
  // Getter & Setter
  // ===========================================================

  public WeatherCurrentCondition getWeatherCurrentCondition() {
    return myCurrentCondition;
  }

  public void setWeatherCurrentCondition(
      WeatherCurrentCondition myCurrentWeather) {
    this.myCurrentCondition = myCurrentWeather;
  }

  public ArrayList<WeatherForecastCondition> getWeatherForecastConditions() {
    return this.myForecastConditions;
  }

  public WeatherForecastCondition getLastWeatherForecastCondition() {
    return this.myForecastConditions
        .get(this.myForecastConditions.size() - 1);
  }
}
java2s.com  | Contact Us | Privacy Policy
Copyright 2009 - 12 Demo Source and Support. All rights reserved.
All other trademarks are property of their respective owners.