コード例 #1
0
        public void Delete(WeatherData weatherData)
        {
            if (!this.IsAttatched(weatherData))
            {
                this._enteties.WeatherDataSet.Attach(weatherData);
            }

            this._enteties.WeatherDataSet.DeleteObject(weatherData);
        }
コード例 #2
0
 /// <summary>
 /// Create a new WeatherData object.
 /// </summary>
 /// <param name="locationId">Initial value of the locationId property.</param>
 /// <param name="weatherDataId">Initial value of the weatherDataId property.</param>
 /// <param name="nextUpdate">Initial value of the nextUpdate property.</param>
 /// <param name="lastUpdate">Initial value of the lastUpdate property.</param>
 /// <param name="timeFrom">Initial value of the timeFrom property.</param>
 /// <param name="timeTo">Initial value of the timeTo property.</param>
 /// <param name="period">Initial value of the period property.</param>
 /// <param name="symbolNumber">Initial value of the symbolNumber property.</param>
 /// <param name="windDirection">Initial value of the windDirection property.</param>
 /// <param name="windDegrees">Initial value of the windDegrees property.</param>
 /// <param name="windSpeed">Initial value of the windSpeed property.</param>
 /// <param name="temperature">Initial value of the temperature property.</param>
 /// <param name="pressure">Initial value of the pressure property.</param>
 /// <param name="precipitation">Initial value of the precipitation property.</param>
 public static WeatherData CreateWeatherData(global::System.Int32 locationId, global::System.Int32 weatherDataId, global::System.DateTime nextUpdate, global::System.DateTime lastUpdate, global::System.DateTime timeFrom, global::System.DateTime timeTo, global::System.Int32 period, global::System.Int32 symbolNumber, global::System.String windDirection, global::System.Double windDegrees, global::System.Double windSpeed, global::System.Double temperature, global::System.Double pressure, global::System.Double precipitation)
 {
     WeatherData weatherData = new WeatherData();
     weatherData.locationId = locationId;
     weatherData.weatherDataId = weatherDataId;
     weatherData.nextUpdate = nextUpdate;
     weatherData.lastUpdate = lastUpdate;
     weatherData.timeFrom = timeFrom;
     weatherData.timeTo = timeTo;
     weatherData.period = period;
     weatherData.symbolNumber = symbolNumber;
     weatherData.windDirection = windDirection;
     weatherData.windDegrees = windDegrees;
     weatherData.windSpeed = windSpeed;
     weatherData.temperature = temperature;
     weatherData.pressure = pressure;
     weatherData.precipitation = precipitation;
     return weatherData;
 }
コード例 #3
0
 /// <summary>
 /// Deprecated Method for adding a new object to the WeatherDataSet EntitySet. Consider using the .Add method of the associated ObjectSet&lt;T&gt; property instead.
 /// </summary>
 public void AddToWeatherDataSet(WeatherData weatherData)
 {
     base.AddObject("WeatherDataSet", weatherData);
 }
コード例 #4
0
 public void Add(WeatherData weatherData)
 {
     this._enteties.WeatherDataSet.AddObject(weatherData);
 }