public static double GetStandardDeviation(this itemsItem items)
        {
            var value = items.GetRating()?.stddev?.FirstOrDefault()?.value;

            if (value == null)
            {
                return(default(double));
            }

            return(SafeDoubleSeparator(Double.Parse(value)));
        }
        public static double GetMedian(this itemsItem items)
        {
            var value = items.GetRating()?.median?.FirstOrDefault()?.value;

            if (value == null)
            {
                return(default(double));
            }

            return(SafeDoubleSeparator(Double.Parse(value)));
        }
        public static double GetBayesAverage(this itemsItem items)
        {
            var value = items.GetRating()?.bayesaverage?.FirstOrDefault()?.value;

            if (value == null)
            {
                return(default(double));
            }

            return(SafeDoubleSeparator(Double.Parse(value)));
        }
        public static double GetUsersRated(this itemsItem items)
        {
            var value = items.GetRating()?.usersrated?.FirstOrDefault()?.value;

            if (value == null)
            {
                return(default(double));
            }

            return(Double.Parse(value));
        }
        public static double GetGameRating(this itemsItem item)
        {
            var value = item.GetRating()?.value;

            if (value == null)
            {
                return(default(double));
            }

            return(SafeDoubleSeparator(double.Parse(value)));
        }
 public static itemsItemStatsRating GetRating(this itemsItem items)
 {
     return(items.stats?.FirstOrDefault()?.rating?.FirstOrDefault());
 }
예제 #7
0
 public static string GetName(this itemsItem itemsItem)
 {
     return(itemsItem.name.FirstOrDefault()?.Value);
 }