Projekt

Obecné

Profil

« Předchozí | Další » 

Revize 98b568bc

Přidáno uživatelem Alex Konig před téměř 4 roky(ů)

re #8612 Weather parser in hourly intervals

Zobrazit rozdíly:

Server/ServerApp/Parser/OutputInfo/WeatherConditions.cs
3 3
    /// <summary>
4 4
    /// Weather conditions in regards to sun level
5 5
    /// </summary>
6
    /// <author>Alex Konig</author>
6 7
    public enum WeatherConditions
7 8
    {
8 9
        Sunny, Cloudy, Overcast, Dark
......
11 12
    /// <summary>
12 13
    /// Transfers lux values to weather conditions and vice versa
13 14
    /// </summary>
15
    /// <author>Alex Konig</author>
14 16
    public static class LuxToConditions
15 17
    {
16 18
        /// <summary>
......
24 26
                return WeatherConditions.Sunny;
25 27

  
26 28
            if (lux > 20_000)
27
                return WeatherConditions.Cloudy;
28

  
29
            if (lux > 10_000)
30 29
                return WeatherConditions.Overcast;
31 30

  
31
            // TODO tohle bylo 10_000, jak mi to má vycházet, zkusit na hourly data
32
            if (lux != 0)
33
                return WeatherConditions.Cloudy;
34

  
32 35
            return WeatherConditions.Dark;
33 36
        }
34 37

  

Také k dispozici: Unified diff