Esempio n. 1
0
        private static void AnswerAnalysis()
        {
            var example = new UserAnalysisExample();

            var task = example.RunAnswerAnalysis("msft");

            task.Wait();

            var result = task.Result
                .Select(m => m.Value).ToList()
                .Where(m => m.Total > 0)
                .OrderByDescending(m => m.Total).ToList();

            var text = Newtonsoft.Json.JsonConvert.SerializeObject(result, Formatting.Indented);

            Console.WriteLine(text);
        }
Esempio n. 2
0
        private static void RunAskerAnslysis()
        {
            var example = new UserAnalysisExample();

            var task = example.RunAskerAnalysis();

            task.Wait();

            var result = task.Result.Select(m => m.Value)
                .OrderByDescending(m => m.total)
                .ToList();

            var text = Newtonsoft.Json.JsonConvert.SerializeObject(result, Formatting.Indented);

            File.WriteAllText("top_20_askers.json", text);

            Console.WriteLine(text);
        }