public EnrollmentsListReply GetEnrollments() { Channel channel = new Channel("localhost:" + "50051", ChannelCredentials.Insecure); var client = new Statistics.StatisticsClient(channel); var reply = client.GetEnrollments(new EnrollmentsRequest { Name = "EnrollmentsClient" }); return(reply); }
public void Show() { Header.Text = String.Format("{0} ({1})", Strings.HighScore, Strings.Loading); Statistics.StatisticsClient statistics = new Statistics.StatisticsClient(); statistics.GetScoresCompleted += new EventHandler<Statistics.GetScoresCompletedEventArgs>(GetScoresCompleted); statistics.GetScoresAsync(Game.HighScore); Values.Visibility = Visibility.Collapsed; Visibility = Visibility.Visible; }
public void Show(int score) { m_Score = score; Header.Text = Strings.GameWinTitle; Message.Text = Strings.GameWinText + "\n\n" + Strings.GameWinChecking; Statistics.StatisticsClient statistics = new Statistics.StatisticsClient(); statistics.IsHighScoreCompleted += new EventHandler<Statistics.IsHighScoreCompletedEventArgs>(IsHighScoreCompleted); statistics.IsHighScoreAsync(m_Score, Game.HighScore); Player.Visibility = Visibility.Collapsed; Visibility = Visibility.Visible; }
internal static void SaveScore(string name, int score) { Statistics.StatisticsClient statistics = new Statistics.StatisticsClient(); statistics.SaveScoreAsync(name, score); }
private static void IncreaseValue(string name, int value) { Statistics.StatisticsClient statistics = new Statistics.StatisticsClient(); statistics.IncreaseValueAsync(name, value); }