Beispiel #1
0
        /// <summary>
        /// Creates a new instance of <see cref="WindDirectionClosingSituation"/>.
        /// </summary>
        /// <param name="windDirection">The wind direction.</param>
        /// <param name="closingSituation">The closing situation.</param>
        /// <exception cref="ArgumentNullException">Thrown when any parameter is <c>null</c>.
        /// </exception>
        public WindDirectionClosingSituation(WindDirection windDirection, string closingSituation)
        {
            if (windDirection == null)
            {
                throw new ArgumentNullException(nameof(windDirection));
            }

            if (closingSituation == null)
            {
                throw new ArgumentNullException(nameof(closingSituation));
            }

            WindDirection    = windDirection;
            ClosingSituation = closingSituation;
        }
Beispiel #2
0
        /// <summary>
        /// Creates a new instance of <see cref="GeneralResult"/>.
        /// </summary>
        /// <param name="beta">The general beta value.</param>
        /// <param name="governingWindDirection">The governing wind direction.</param>
        /// <param name="stochasts">The general alpha stochast values.</param>
        /// <param name="illustrationPoints">The trees of illustration points for each wind direction.</param>
        /// <exception cref="ArgumentNullException">Thrown when <paramref name="governingWindDirection"/>,
        /// <paramref name="stochasts"/>, or <paramref name="illustrationPoints"/> is <c>null</c>.</exception>
        public GeneralResult(double beta, WindDirection governingWindDirection,
                             IEnumerable <Stochast> stochasts,
                             Dictionary <WindDirectionClosingSituation, IllustrationPointTreeNode> illustrationPoints)
        {
            if (governingWindDirection == null)
            {
                throw new ArgumentNullException(nameof(governingWindDirection));
            }

            if (stochasts == null)
            {
                throw new ArgumentNullException(nameof(stochasts));
            }

            if (illustrationPoints == null)
            {
                throw new ArgumentNullException(nameof(illustrationPoints));
            }

            Beta = beta;
            GoverningWindDirection = governingWindDirection;
            Stochasts          = stochasts;
            IllustrationPoints = illustrationPoints;
        }
Beispiel #3
0
 private bool Equals(WindDirection other)
 {
     return(string.Equals(Name, other.Name) && Angle.Equals(other.Angle));
 }