diff options
| author | Luke <luke.pulverenti@gmail.com> | 2013-02-20 17:10:49 -0800 |
|---|---|---|
| committer | Luke <luke.pulverenti@gmail.com> | 2013-02-20 17:10:49 -0800 |
| commit | 845554722efaed872948a9e0f7202e3ef52f1b6e (patch) | |
| tree | 534ab2d11fe4824ed303bb01e885b330631b657e /MediaBrowser.Model/Weather | |
| parent | 2f142263f080f7b012a0ec2095d350ccf75b49b7 (diff) | |
| parent | 14bbb6804718ef78a8118fe750896ba679e3b6cb (diff) | |
Merge pull request #1 from MediaBrowser/Repo
Repo
Diffstat (limited to 'MediaBrowser.Model/Weather')
| -rw-r--r-- | MediaBrowser.Model/Weather/WeatherForecast.cs | 30 | ||||
| -rw-r--r-- | MediaBrowser.Model/Weather/WeatherInfo.cs | 14 | ||||
| -rw-r--r-- | MediaBrowser.Model/Weather/WeatherStatus.cs | 38 | ||||
| -rw-r--r-- | MediaBrowser.Model/Weather/WeatherUnits.cs | 9 |
4 files changed, 91 insertions, 0 deletions
diff --git a/MediaBrowser.Model/Weather/WeatherForecast.cs b/MediaBrowser.Model/Weather/WeatherForecast.cs new file mode 100644 index 0000000000..f77d92366a --- /dev/null +++ b/MediaBrowser.Model/Weather/WeatherForecast.cs @@ -0,0 +1,30 @@ +using System;
+using ProtoBuf;
+
+namespace MediaBrowser.Model.Weather
+{
+ /// <summary>
+ /// Represents a weather forecase for a specific date
+ /// </summary>
+ [ProtoContract]
+ public class WeatherForecast
+ {
+ [ProtoMember(1)]
+ public DateTime Date { get; set; }
+
+ [ProtoMember(2)]
+ public int HighTemperatureFahrenheit { get; set; }
+
+ [ProtoMember(3)]
+ public int LowTemperatureFahrenheit { get; set; }
+
+ [ProtoMember(4)]
+ public int HighTemperatureCelsius { get; set; }
+
+ [ProtoMember(5)]
+ public int LowTemperatureCelsius { get; set; }
+
+ [ProtoMember(6)]
+ public WeatherConditions Condition { get; set; }
+ }
+}
diff --git a/MediaBrowser.Model/Weather/WeatherInfo.cs b/MediaBrowser.Model/Weather/WeatherInfo.cs new file mode 100644 index 0000000000..7cad4d2484 --- /dev/null +++ b/MediaBrowser.Model/Weather/WeatherInfo.cs @@ -0,0 +1,14 @@ +using ProtoBuf;
+
+namespace MediaBrowser.Model.Weather
+{
+ [ProtoContract]
+ public class WeatherInfo
+ {
+ [ProtoMember(1)]
+ public WeatherStatus CurrentWeather { get; set; }
+
+ [ProtoMember(2)]
+ public WeatherForecast[] Forecasts { get; set; }
+ }
+}
diff --git a/MediaBrowser.Model/Weather/WeatherStatus.cs b/MediaBrowser.Model/Weather/WeatherStatus.cs new file mode 100644 index 0000000000..7019d319b7 --- /dev/null +++ b/MediaBrowser.Model/Weather/WeatherStatus.cs @@ -0,0 +1,38 @@ +using ProtoBuf;
+
+namespace MediaBrowser.Model.Weather
+{
+ /// <summary>
+ /// Represents the current weather status
+ /// </summary>
+ [ProtoContract]
+ public class WeatherStatus
+ {
+ [ProtoMember(1)]
+ public int TemperatureFahrenheit { get; set; }
+
+ [ProtoMember(2)]
+ public int TemperatureCelsius { get; set; }
+
+ [ProtoMember(3)]
+ public int Humidity { get; set; }
+
+ [ProtoMember(4)]
+ public WeatherConditions Condition { get; set; }
+ }
+
+ public enum WeatherConditions
+ {
+ Sunny,
+ PartlyCloudy,
+ Cloudy,
+ Overcast,
+ Mist,
+ Snow,
+ Rain,
+ Sleet,
+ Fog,
+ Blizzard,
+ Thunderstorm
+ }
+}
diff --git a/MediaBrowser.Model/Weather/WeatherUnits.cs b/MediaBrowser.Model/Weather/WeatherUnits.cs new file mode 100644 index 0000000000..3bea67b9a4 --- /dev/null +++ b/MediaBrowser.Model/Weather/WeatherUnits.cs @@ -0,0 +1,9 @@ +
+namespace MediaBrowser.Model.Weather
+{
+ public enum WeatherUnits
+ {
+ Fahrenheit,
+ Celsius
+ }
+}
|
